Skip to content

vcpkg upgrade always installs default features #11479

@zrax

Description

@zrax

Describe the bug
If a port was previously installed with only a subset of available features, upgrading it will always pull in the default features, which may not be desired.

Environment

  • OS: Windows
  • Compiler: MSVC 2019

To Reproduce
Example with libarchive:

  1. Check out an older version of vcpkg
  2. ./vcpkg install libarchive[core,bzip2,lzma]
  3. git pull
  4. ./vcpkg upgrade
    • or: ./vcpkg upgrade libarchive
    • or even: ./vcpkg upgrade libarchive[core,bzip2,lzma]

All three forms of step 4 cause vcpkg to pull in the full set of default features (libarchive[bzip2,core,libxml2,lz4,lzma,lzo,openssl,zstd]). The last version especially is pretty clearly not what the user intended.

Expected behavior
Only the features requested should be included in the updated package.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions