Skip to content

Cmake install fix#170

Closed
mathstuf wants to merge 2 commits intomadler:masterfrom
mathstuf:cmake-install-fix
Closed

Cmake install fix#170
mathstuf wants to merge 2 commits intomadler:masterfrom
mathstuf:cmake-install-fix

Conversation

@mathstuf
Copy link
Copy Markdown

No description provided.

When these variables are set in the cache, changing the
CMAKE_INSTALL_PREFIX does not change the directories that actually get
used. Instead, use them if the user provided them via -D, otherwise use
the default based on CMAKE_INSTALL_PREFIX.
zlib is a compile library and its .pc file should live in the library
directory. This allows a 64bit zlib and a 32bit zlib to co-exist in the
same install prefix.
set(INSTALL_MAN_DIR "${CMAKE_INSTALL_PREFIX}/share/man" CACHE PATH "Installation directory for manual pages")
set(INSTALL_PKGCONFIG_DIR "${CMAKE_INSTALL_PREFIX}/share/pkgconfig" CACHE PATH "Installation directory for pkgconfig (.pc) files")
if (NOT INSTALL_BIN_DIR)
set(INSTALL_BIN_DIR "${CMAKE_INSTALL_PREFIX}/bin")
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Even better would be to remove ${CMAKE_INSTALL_PREFIX}/ here completely. CMake will add it at install time for any relative path.

@Vollstrecker Vollstrecker mentioned this pull request Dec 11, 2024
@Neustradamus Neustradamus mentioned this pull request Jan 1, 2025
@madler
Copy link
Copy Markdown
Owner

madler commented Feb 2, 2025

See #1027 .

@madler madler closed this Feb 2, 2025
@mathstuf
Copy link
Copy Markdown
Author

mathstuf commented Feb 3, 2025

Thanks; confirmed that develop has the spirit of this in behavior.

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