软著提交相关内容补充
This commit is contained in:
25
DIDKit/cmake/DIDKitConfig.cmake.in
Normal file
25
DIDKit/cmake/DIDKitConfig.cmake.in
Normal file
@@ -0,0 +1,25 @@
|
||||
set(DIDKIT_LIBRARIES DIDKit)
|
||||
|
||||
# The configuration options.
|
||||
set(DIDKIT_BUILD_SHARED_LIBS "@BUILD_SHARED_LIBS@")
|
||||
|
||||
get_filename_component(SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
|
||||
if(EXISTS ${SELF_DIR}/DIDKITTargets.cmake)
|
||||
# This is an install tree
|
||||
include(${SELF_DIR}/DIDKITTargets.cmake)
|
||||
get_filename_component(DIDKIT_INCLUDE_ROOT "${SELF_DIR}/../../../include" ABSOLUTE)
|
||||
set(DIDKIT_INCLUDE_DIRS ${DIDKIT_INCLUDE_ROOT})
|
||||
else()
|
||||
if(EXISTS ${SELF_DIR}/DIDKITExports.cmake)
|
||||
# This is a build tree
|
||||
set( DIDKIT_INCLUDE_DIRS "@CMAKE_SOURCE_DIR@/include")
|
||||
|
||||
include(${SELF_DIR}/DIDKITExports.cmake)
|
||||
|
||||
else()
|
||||
message(FATAL_ERROR "fail to load DIDKIT")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Backward compatible part:
|
||||
set(DIDKIT_FOUND TRUE)
|
||||
Reference in New Issue
Block a user