diff options
-rw-r--r-- | src/CMakeLists.txt | 2 | ||||
-rw-r--r-- | src/GUDHIConfig.cmake.in | 7 |
2 files changed, 7 insertions, 2 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index c60346d5..6c446104 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -71,7 +71,7 @@ export(PACKAGE GUDHI) message("++ make install will install ${PROJECT_NAME} in the following directory : ${CMAKE_INSTALL_PREFIX}") # Create the GUDHIConfig.cmake and GUDHIConfigVersion files -set(CONF_INCLUDE_DIRS "${CMAKE_INSTALL_PREFIX}/include") +set(CONF_INCLUDE_DIRS "${CMAKE_SOURCE_DIR}/include;${CMAKE_INSTALL_PREFIX}/include") configure_file(GUDHIConfig.cmake.in "${PROJECT_BINARY_DIR}/GUDHIConfig.cmake" @ONLY) configure_file(GUDHIConfigVersion.cmake.in "${PROJECT_BINARY_DIR}/GUDHIConfigVersion.cmake" @ONLY) diff --git a/src/GUDHIConfig.cmake.in b/src/GUDHIConfig.cmake.in index 02b540dc..8d82f235 100644 --- a/src/GUDHIConfig.cmake.in +++ b/src/GUDHIConfig.cmake.in @@ -1,7 +1,12 @@ # - Config file for the GUDHI package # It defines the following variables # GUDHI_INCLUDE_DIRS - include directories for GUDHI +# +# Order is : +# 1. user defined GUDHI_INCLUDE_DIRS +# 2. ${CMAKE_SOURCE_DIR}/include => Where the 'cmake' has been done +# 3. ${CMAKE_INSTALL_PREFIX}/include => Where the 'make install' has been performed # Compute paths -set(GUDHI_INCLUDE_DIRS "@CONF_INCLUDE_DIRS@") +set(GUDHI_INCLUDE_DIRS "${GUDHI_INCLUDE_DIRS};@CONF_INCLUDE_DIRS@") |