From 089e81e86a2d0558b0b3aa36003383fe8d80d2bd Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Wed, 18 May 2011 12:50:32 -0500 Subject: [svn-r20862] Adjust CPack configuration location by removing version extension in folder name. Add install configuration commands if ext libs are packaged with project. --- CMakeLists.txt | 6 +++--- config/cmake/FindHDF5.cmake | 4 ++-- config/cmake/hdf5-config.cmake.install.in | 7 +++++++ 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index d16a902..c7cbf57 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -727,7 +727,7 @@ ENDIF (NOT HDF5_INSTALL_NO_DEVELOPMENT) IF (NOT HDF5_EXTERNALLY_CONFIGURED) INSTALL ( EXPORT ${HDF5_EXPORTED_TARGETS} - DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5-${HDF5_PACKAGE_VERSION} + DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5 FILE hdf5-targets.cmake ) ENDIF (NOT HDF5_EXTERNALLY_CONFIGURED) @@ -768,7 +768,7 @@ IF (NOT HDF5_EXTERNALLY_CONFIGURED) ) INSTALL ( FILES ${HDF5_BINARY_DIR}/CMakeFiles/hdf5-config.cmake - DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5-${HDF5_PACKAGE_VERSION} + DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5 ) ENDIF (NOT HDF5_EXTERNALLY_CONFIGURED) @@ -782,7 +782,7 @@ IF (NOT HDF5_EXTERNALLY_CONFIGURED) ) INSTALL ( FILES ${HDF5_BINARY_DIR}/CMakeFiles/hdf5-config-version.cmake - DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5-${HDF5_PACKAGE_VERSION} + DESTINATION ${HDF5_INSTALL_DATA_DIR}/cmake/hdf5 ) ENDIF (NOT HDF5_EXTERNALLY_CONFIGURED) diff --git a/config/cmake/FindHDF5.cmake b/config/cmake/FindHDF5.cmake index a705d5b..33532b0 100644 --- a/config/cmake/FindHDF5.cmake +++ b/config/cmake/FindHDF5.cmake @@ -63,8 +63,8 @@ FIND_PATH (HDF5_ROOT_DIR "hdf5-config.cmake" HINTS ${_HDF5_HINTS} PATHS ${_HDF5_PATHS} PATH_SUFFIXES - lib/cmake/hdf5-1.9 - share/cmake/hdf5-1.9 + lib/cmake/hdf5 + share/cmake/hdf5 ) FIND_PATH (HDF5_INCLUDE_DIRS "H5public.h" diff --git a/config/cmake/hdf5-config.cmake.install.in b/config/cmake/hdf5-config.cmake.install.in index eed1a2a..0e653ea 100644 --- a/config/cmake/hdf5-config.cmake.install.in +++ b/config/cmake/hdf5-config.cmake.install.in @@ -18,6 +18,7 @@ SET (HDF5_ENABLE_Z_LIB_SUPPORT @HDF5_ENABLE_Z_LIB_SUPPORT@) SET (HDF5_ENABLE_SZIP_SUPPORT @HDF5_ENABLE_SZIP_SUPPORT@) SET (HDF5_ENABLE_SZIP_ENCODING @HDF5_ENABLE_SZIP_ENCODING@) SET (BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@) +SET (HDF5_PACKAGE_EXTLIBS @HDF5_PACKAGE_EXTLIBS@) #----------------------------------------------------------------------------- # Directories @@ -57,6 +58,12 @@ SET (HDF5_VERSION_MINOR @HDF5_VERSION_MINOR@) # project which has already built hdf5 as a subproject #----------------------------------------------------------------------------- IF (NOT TARGET "hdf5") + IF (HDF5_ENABLE_Z_LIB_SUPPORT AND HDF5_PACKAGE_EXTLIBS) + INCLUDE (${SELF_DIR}/../ZLIB/ZLIB-targets.cmake) + ENDIF (HDF5_ENABLE_Z_LIB_SUPPORT AND HDF5_PACKAGE_EXTLIBS) + IF (HDF5_ENABLE_SZIP_SUPPORT AND HDF5_PACKAGE_EXTLIBS) + INCLUDE (${SELF_DIR}/../SZIP/SZIP-targets.cmake) + ENDIF (HDF5_ENABLE_SZIP_SUPPORT AND HDF5_PACKAGE_EXTLIBS) INCLUDE (${SELF_DIR}/hdf5-targets.cmake) ENDIF (NOT TARGET "hdf5") -- cgit v0.12