diff --git a/cmake/compilerDefinitions.cmake b/cmake/compilerDefinitions.cmake index 7179c6898..5ef19b4b6 100644 --- a/cmake/compilerDefinitions.cmake +++ b/cmake/compilerDefinitions.cmake @@ -5,5 +5,5 @@ if (UNIX) if (HAVE_RULES) add_definitions(-DHAVE_RULES -DTIXML_USE_STL) endif() - add_definitions(-DCFGDIR="${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME}") + add_definitions(-DCFGDIR="${CFGDIR}") endif() diff --git a/cmake/options.cmake b/cmake/options.cmake index 8a2c21ece..53f06a66e 100644 --- a/cmake/options.cmake +++ b/cmake/options.cmake @@ -46,3 +46,6 @@ set(CMAKE_LIB_DIRS_CONFIGCMAKE ${CMAKE_INSTALL_PREFIX}/lib CACHE PA set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin) set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib) + +set(CFGDIR ${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME} CACHE STRING "CFG files directory") +