-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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] Meson osx sysroot #21772
Merged
Merged
[vcpkg] Meson osx sysroot #21772
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
19d1706
[get_cmake_vars] add -isysroot flag independednt of crosscompiling
daschuer 4c298e5
[meson] add -arch and -isysroot to linker flags in case of osx crossc…
daschuer 267e8e3
[meson] avoid DEPRECATION warning about flags in the [properties] sec…
daschuer d1f915c
[meson] don't set OSXROOT evironment varibale
daschuer 7e4ecfe
[meson] don't set MACOSX_DEPLOYMENT_TARGET environment variable
daschuer c56c9c1
[meson/make] Add CMAKE_OSX_DEPLOYMENT_TARGET to VCPKG_DETECTED_CMAKE_…
daschuer File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Add it to the linker flags in
get_cmake_vars/CMakeLists.txt
?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.
This does not work, because it would also affect autotools ports
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.
Ping @Neumann-A for reply.
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 declare more?
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.
I also don't see why autotools should break with the additional flags. In general vcpkg should avoid adding additional flags in
vcpkg_configure_
scripts.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.
Now we have:
With -arch and -isysroot applied twice.
Conclusion: the current state of this PR is correct.
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.
I don't share that conclusion.
The reason that is happening is because the common makefile has something along the line
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)
. Which of course doubles the flags.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.
Which common make file do you reference?
What do you propose as an alternative solution?
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.
All the flags should be extract from cmake:
vcpkg/scripts/cmake/vcpkg_configure_meson.cmake
Line 383 in 5ef52b5
Therefore, the behavor of cmake, make, qmake and meson etc. should be same.
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.
Sure, this is already the case.
The issue here is that cmake and autotools take these flags from the c flags and pass them to the linker. Meson does not do it and require a special handlung.
I have demonstrated that the requested solution does apply the flags twice. The current state of the PR passes the right number of flags as desired.
qmake is out of scope, because it does not use z_vcpkg_get_cmake_vars
If you have an alternative solution in mind that works as well, please propose.