Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[vcpkg] Fix issue #9781 by exporting from the installed directory #11015

Merged
merged 5 commits into from
Jun 17, 2020

Conversation

ras0219
Copy link
Contributor

@ras0219 ras0219 commented Apr 24, 2020

Currently, vcpkg export reads the files out of the packages\ directory for a given package. This is both

  1. Inconvenient, because it prevents --clean-after-build
  2. Wrong, since the packages folder is not as tightly controlled by our API surface as the installed directory

Instead, it should read the files from the installed directory (using the listfile as a manifest).

toolsrc/include/vcpkg/install.h Outdated Show resolved Hide resolved
toolsrc/src/vcpkg/export.cpp Outdated Show resolved Hide resolved
toolsrc/src/vcpkg/install.cpp Show resolved Hide resolved
toolsrc/src/vcpkg/install.cpp Show resolved Hide resolved
toolsrc/src/vcpkg/install.cpp Outdated Show resolved Hide resolved
@davidebeatrici
Copy link
Contributor

Thank you very much for creating this!

Unfortunately there's an issue. For each triplet two folders are created instead of one, resulting in:

<vcpkg-export>\installed\x64-windows-static-md\x64-windows-static-md

Moving the subdirectory's content one level upper (root x64-windows-static-md) makes the environment work as expected.

@JackBoosY JackBoosY added category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) info:internal This PR or Issue was filed by the vcpkg team. requires:author-response labels Jun 11, 2020
@ras0219-msft ras0219-msft merged commit 4cbbf4e into microsoft:master Jun 17, 2020
JangBoo pushed a commit to JangBoo/vcpkg that referenced this pull request Jun 18, 2020
…ctory (microsoft#11015)

* [vcpkg] Fix issue microsoft#9781 by exporting from the installed directory

* [vcpkg] Address code review comments for microsoft#11015

* [vcpkg] Remove duplicate triplet in installed path from exports

Co-authored-by: Robert Schumacher <[email protected]>
strega-nil pushed a commit to strega-nil/vcpkg that referenced this pull request May 5, 2021
…ctory (microsoft#11015)

* [vcpkg] Fix issue microsoft#9781 by exporting from the installed directory

* [vcpkg] Address code review comments for microsoft#11015

* [vcpkg] Remove duplicate triplet in installed path from exports

Co-authored-by: Robert Schumacher <[email protected]>
kLiHz added a commit to kLiHz/vcpkg-build-opencv that referenced this pull request Apr 17, 2023
As in issue microsoft/vcpkg#9781
and merged pull request microsoft/vcpkg#11015
, vcpkg doesn't use `packages` dir for either installing or exporting.

Since now disabling binary cache, directory `installed` should be used.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) info:internal This PR or Issue was filed by the vcpkg team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

vcpkg export requires packages directory
5 participants