From 8bdc08767b3a74756d5d69603a07157ffc2b9be1 Mon Sep 17 00:00:00 2001 From: Markus Rickert Date: Wed, 27 Sep 2017 12:14:19 -0700 Subject: [PATCH] Add namespace ccd to exported CMake targets --- ccd-config.cmake.in | 2 +- src/CMakeLists.txt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ccd-config.cmake.in b/ccd-config.cmake.in index 8f13af9..693aff5 100644 --- a/ccd-config.cmake.in +++ b/ccd-config.cmake.in @@ -9,6 +9,6 @@ set(CCD_SOVERSION @CCD_SOVERSION@) set(CCD_FOUND ON) set_and_check(CCD_INCLUDE_DIRS "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@") set_and_check(CCD_LIBRARY_DIRS "@PACKAGE_CMAKE_INSTALL_LIBDIR@") -set(CCD_LIBRARIES ccd) +set(CCD_LIBRARIES ccd::ccd) include("${CMAKE_CURRENT_LIST_DIR}/ccd-targets.cmake") diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 62bf475..4c56eb7 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -58,7 +58,7 @@ if(NOT WIN32) endif() endif() -export(TARGETS ccd FILE "${CMAKE_BINARY_DIR}/ccd-targets.cmake") +export(TARGETS ccd NAMESPACE ccd:: FILE "${CMAKE_BINARY_DIR}/ccd-targets.cmake") install(TARGETS ccd EXPORT ccd-targets @@ -67,7 +67,7 @@ install(TARGETS ccd LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" PUBLIC_HEADER DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/ccd" RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}") -install(EXPORT ccd-targets DESTINATION "${CMAKE_INSTALL_LIBDIR}/ccd") +install(EXPORT ccd-targets DESTINATION "${CMAKE_INSTALL_LIBDIR}/ccd" NAMESPACE ccd::) if(NOT WIN32 AND BUILD_TESTING) add_subdirectory(testsuites)