diff --git a/cmake/urdfdom_headers-config.cmake.in b/cmake/urdfdom_headers-config.cmake.in --- a/cmake/urdfdom_headers-config.cmake.in +++ b/cmake/urdfdom_headers-config.cmake.in @@ -3,8 +3,8 @@ if (@PACKAGE_NAME@_CONFIG_INCLUDED) endif() set(@PACKAGE_NAME@_CONFIG_INCLUDED TRUE) -set(@PACKAGE_NAME@_INCLUDE_DIRS "${@PROJECT_NAME@_DIR}/@RELATIVE_PATH_CMAKE_DIR_TO_PREFIX@/include") +set(@PACKAGE_NAME@_INCLUDE_DIRS "${CMAKE_CURRENT_LIST_DIR}/../../../include") -include("${@PACKAGE_NAME@_DIR}/@PACKAGE_NAME@Export.cmake") +include("${CMAKE_CURRENT_LIST_DIR}/@PACKAGE_NAME@Export.cmake") list(APPEND @PACKAGE_NAME@_TARGETS @PACKAGE_NAME@::@PACKAGE_NAME@) diff --git a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -23,10 +23,10 @@ add_subdirectory(urdf_model_state) add_subdirectory(urdf_world) add_subdirectory(urdf_exception) -if(WIN32 AND NOT CYGWIN) +if(FALSE) set(CMAKE_CONFIG_INSTALL_DIR CMake) else() - set(CMAKE_CONFIG_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}/${PROJECT_NAME}/cmake) + set(CMAKE_CONFIG_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}) endif() string(REGEX REPLACE "[^/]+" ".." RELATIVE_PATH_CMAKE_DIR_TO_PREFIX "${CMAKE_CONFIG_INSTALL_DIR}")