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

Fix cmake abspath conversions #4461

Merged
merged 2 commits into from
Nov 21, 2020
Merged

Conversation

rtburns-jpl
Copy link
Contributor

CMAKE_INSTALL_*DIR variables are not necessarily relative
to the install prefix - they may be absolute, in which case
appending them to CMAKE_INSTALL_PREFIX is not valid.

Fixes installation paths when provided GNU_INSTALL_*DIRs are not relative to CMAKE_INSTALL_PREFIX, as used by some tooling - e.g. -DGNU_INSTALL_LIBDIR=/usr/lib/
See https://github.com/jtojnar/cmake-snips#assuming-cmake_install_dir-is-relative-path for more info.

Reminders

  • Make sure that your code follows our style. Use the other functions/files as a basis.
  • Add tests for new features or tests that would have caught the bug that you're fixing.
  • Describe changes to function behavior and arguments in a comment below the function declaration.
  • If adding new functionality, add a detailed description to the documentation and/or an example.

CMAKE_INSTALL_*DIR variables are not necessarily relative
to the install prefix - they may be absolute, in which case
appending them to CMAKE_INSTALL_PREFIX is not valid.
@welcome
Copy link

welcome bot commented Nov 18, 2020

💖 Thanks for opening this pull request! 💖

Please make sure you read our Contributing Guide and abide by our Code of Conduct.

A few things to keep in mind:

  • If you need help writing tests, take a look at the existing ones for inspiration. If you don't know where to start, let us know and we'll walk you through it.
  • All new features should be documented. It helps to write the comments below for your functions describing the it, all arguments, and return types before writing the code. This will help you think about your code design and results in better code.
  • We are grateful that you put in the effort to do this! 🎉

@seisman
Copy link
Member

seisman commented Nov 18, 2020

Will review this PR in the next few days.

Copy link
Member

@seisman seisman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good, except a tiny fix.

cmake/modules/JoinPaths.cmake Outdated Show resolved Hide resolved
@seisman seisman merged commit 38af720 into GenericMappingTools:master Nov 21, 2020
@welcome
Copy link

welcome bot commented Nov 21, 2020

🎉🎉🎉 Congrats on merging your first pull request and welcome to the team! 🎉🎉🎉

We hope that this was a good experience for you. Let us know if there is any way that the contributing process could be improved.

@rtburns-jpl rtburns-jpl deleted the cmake branch November 21, 2020 20:36
seisman added a commit that referenced this pull request Nov 23, 2020
@seisman
Copy link
Member

seisman commented Nov 23, 2020

@rtburns-jpl After merging this PR, we can't build the GMT macOS bundle anymore. Please see the issue report in #4481.

It's unclear to me how CMake builds bundles, so we have to revert the changes in this PR (#4484) now.

If you know more about CMake and know how to fix it, we're glad to re-merge your changes again.

seisman added a commit that referenced this pull request Nov 23, 2020
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.

None yet

3 participants