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

Do not overwrite default linker flags so that LDFLAGS environment variable is considered #51

Merged
merged 2 commits into from
Aug 5, 2021

Conversation

traversaro
Copy link
Member

If a CMake build system of a projects wants to specify additional linked flags, those should be appended to the CMAKE_EXE_LINKER_FLAGS CMake variable. However, the original value of CMAKE_EXE_LINKER_FLAGS should not been overwritten, as this would lead to the LDFLAGS environment variable to be ignored, leading to linking errors in some environments that exploit this environment variable to specify the location of the libraries.

For more details see:

@traversaro traversaro requested review from triccyx and Nicogene August 5, 2021 11:39
@traversaro
Copy link
Member Author

This PR fixes a bug in any case, but the main reason why I opened it is that I hope that it will fix robotology/robotology-superbuild#848 .

@Nicogene Nicogene merged commit 4659c96 into master Aug 5, 2021
@Nicogene Nicogene deleted the fix_ldflags branch August 5, 2021 13:50
@Nicogene
Copy link
Member

Nicogene commented Aug 5, 2021

Merged, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants