summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt McCormick <matt@mmmccormick.com>2022-01-19 04:28:27 (GMT)
committerGitHub <noreply@github.com>2022-01-19 04:28:27 (GMT)
commit1a9662e04c4e469be8c4f822c2dc83f19a7be4be (patch)
tree78905f4973661c5fb1daef9e047fff00c5c1357a
parentbd37363332c0016262a05e4515b9f0e30e9b3d89 (diff)
downloadhdf5-1a9662e04c4e469be8c4f822c2dc83f19a7be4be.zip
hdf5-1a9662e04c4e469be8c4f822c2dc83f19a7be4be.tar.gz
hdf5-1a9662e04c4e469be8c4f822c2dc83f19a7be4be.tar.bz2
Do not set CMAKE_INSTALL_PREFIX when built externally (#1380)
-rw-r--r--config/cmake_ext_mod/HDFMacros.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/cmake_ext_mod/HDFMacros.cmake b/config/cmake_ext_mod/HDFMacros.cmake
index a774130..09492e7 100644
--- a/config/cmake_ext_mod/HDFMacros.cmake
+++ b/config/cmake_ext_mod/HDFMacros.cmake
@@ -427,7 +427,7 @@ macro (HDF_DIR_PATHS package_prefix)
endif ()
endif ()
- if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+ if (NOT ${package_prefix}_EXTERNALLY_CONFIGURED AND CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
if (CMAKE_HOST_UNIX)
set (CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}/HDF_Group/${HDF5_PACKAGE_NAME}/${HDF5_PACKAGE_VERSION}"
CACHE PATH "Install path prefix, prepended onto install directories." FORCE)