diff options
author | Brad King <brad.king@kitware.com> | 2021-12-01 14:34:13 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-12-01 14:34:32 (GMT) |
commit | cab4551889f09e433e729835c3e09dc20f102d06 (patch) | |
tree | e343a0d6dde2f32dd32be738388a1ceb33f007f8 /Modules | |
parent | bd7f276c52eed76ae9e163c75bf7293469c4523d (diff) | |
parent | 7896991af029d66c9e1692ce18027fafaa0e9bd8 (diff) | |
download | CMake-cab4551889f09e433e729835c3e09dc20f102d06.zip CMake-cab4551889f09e433e729835c3e09dc20f102d06.tar.gz CMake-cab4551889f09e433e729835c3e09dc20f102d06.tar.bz2 |
Merge topic 'GNUInstallDirs-conda-fix' into release-3.22
7896991af0 GNUInstallDirs: Prefer system lib64 over conda lib when ambiguous
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6773
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/GNUInstallDirs.cmake | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Modules/GNUInstallDirs.cmake b/Modules/GNUInstallDirs.cmake index 6ca424a..01bd637 100644 --- a/Modules/GNUInstallDirs.cmake +++ b/Modules/GNUInstallDirs.cmake @@ -253,7 +253,9 @@ if(NOT DEFINED CMAKE_INSTALL_LIBDIR OR (_libdir_set elseif(DEFINED ENV{CONDA_PREFIX}) set(conda_prefix "$ENV{CONDA_PREFIX}") cmake_path(ABSOLUTE_PATH conda_prefix NORMALIZE) - if("${CMAKE_INSTALL_PREFIX}" STREQUAL conda_prefix) + if("${CMAKE_INSTALL_PREFIX}" STREQUAL conda_prefix AND + NOT ("${CMAKE_INSTALL_PREFIX}" MATCHES "^/usr/?$" OR + "${CMAKE_INSTALL_PREFIX}" MATCHES "^/usr/local/?$")) set(__system_type_for_install "conda") endif() endif() |