diff --git a/CMakeLists.txt b/CMakeLists.txt index 653cbbb4..340a9fbd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -438,7 +438,7 @@ add_custom_target(uninstall get_directory_property(NETGEN_COMPILE_DEFINITIONS COMPILE_DEFINITIONS) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/cmake/NetgenConfig.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/NetgenConfig.cmake @ONLY) + ${CMAKE_CURRENT_BINARY_DIR}/NetgenConfig.cmake @ONLY ESCAPE_QUOTES) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/NetgenConfig.cmake DESTINATION ${NG_INSTALL_DIR_CMAKE}) diff --git a/cmake/NetgenConfig.cmake.in b/cmake/NetgenConfig.cmake.in index 71447d6e..57b90bc9 100644 --- a/cmake/NetgenConfig.cmake.in +++ b/cmake/NetgenConfig.cmake.in @@ -2,19 +2,19 @@ set(PACKAGE_VERSION "@NETGEN_VERSION@") get_filename_component(NETGEN_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH) -set(NETGEN_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_DIR@") +get_filename_component(NETGEN_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_DIR@" ABSOLUTE) set(NETGEN_COMPILE_DEFINITIONS "@NETGEN_COMPILE_DEFINITIONS@") -set(NETGEN_INCLUDE_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_INCLUDE_DIR@") -set(NETGEN_BINARY_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_BINARY_DIR@") -set(NETGEN_LIBRARY_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_LIBRARY_DIR@") -set(NETGEN_PYTHON_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_PYTHON_DIR@") -set(NETGEN_RESOURCE_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_RESOURCE_DIR@") +get_filename_component(NETGEN_INCLUDE_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_INCLUDE_DIR@" ABSOLUTE) +get_filename_component(NETGEN_BINARY_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_BINARY_DIR@" ABSOLUTE) +get_filename_component(NETGEN_LIBRARY_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_LIBRARY_DIR@" ABSOLUTE) +get_filename_component(NETGEN_PYTHON_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_PYTHON_DIR@" ABSOLUTE) +get_filename_component(NETGEN_RESOURCE_DIR "${NETGEN_CMAKE_DIR}/@NETGEN_RESOURCE_DIR@" ABSOLUTE) set(NETGEN_SOURCE_DIR "@PROJECT_SOURCE_DIR@") -set(NETGEN_INCLUDE_DIRS "${NETGEN_CMAKE_DIR}/@NETGEN_INCLUDE_DIR@/include;${NETGEN_CMAKE_DIR}/@NETGEN_INCLUDE_DIR@") +set(NETGEN_INCLUDE_DIRS "${NETGEN_INCLUDE_DIR}/include;${NETGEN_INCLUDE_DIR}") set(NETGEN_CMAKE_THREAD_LIBS_INIT "@CMAKE_THREAD_LIBS_INIT@") set(NETGEN_FFMPEG_LIBRARIES "@FFMPEG_LIBRARIES@") set(NETGEN_JPEG_INCLUDE_DIR "@JPEG_INCLUDE_DIR@")