-
Notifications
You must be signed in to change notification settings - Fork 335
[spdx] Replace CMake variables in vcpkg_download_distfile()
#1607
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
Conversation
|
@BillyONeal I'm not sure how to handle the path issue: From microsoft/vcpkg#44188 (comment):
The code expects relative paths: Lines 381 to 386 in d034830
but we feed in absolute paths by including the port directory: vcpkg-tool/src/vcpkg/commands.build.cpp Line 1247 in d034830
vcpkg-tool/src/vcpkg/commands.build.cpp Line 1331 in d034830
vcpkg-tool/src/vcpkg/commands.build.cpp Lines 934 to 938 in d034830
However, I think we should be using absolute paths because we might lose the information of where a file comes from in case of overlay ports. On the other hand, absolute paths are invalid after downloading from a binary cache on different machines. |
Right, this is why the paths have to be relative.
That's why the SHAs of the files are also in the SPDX. It isn't there's a hard link between any particular absolute path and anything else, any more than there is between that relative path and anything else. |
BillyONeal
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add a test? Would merge this with one.
Hi @BillyONeal, I added a unit test to check the correct replacement of As you proposed, I didn't fix the absolute path issue mentioned in microsoft/vcpkg#44188. Therefore, plese don't close that issue yet - I will fix the absolute path issue in a different PR. |
…ix-spdx-distfile
Partially fixes microsoft/vcpkg#44188
Fixes microsoft/vcpkg#44040