-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
38 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,50 @@ | ||
@PACKAGE_INIT@ | ||
if (NOT TARGET LCI::LCT) | ||
|
||
LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/LCI") | ||
include(CMakeFindDependencyMacro) | ||
@PACKAGE_INIT@ | ||
|
||
set(CMAKE_THREAD_PREFER_PTHREAD TRUE) | ||
set(THREADS_PREFER_PTHREAD_FLAG TRUE) | ||
find_dependency(Threads) | ||
LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/LCI") | ||
include(CMakeFindDependencyMacro) | ||
|
||
set_and_check(LCT_INCLUDE_DIRS "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@") | ||
set_and_check(LCT_SHARED_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_SHARED_LIBRARY_PREFIX@lct@CMAKE_SHARED_LIBRARY_SUFFIX@") | ||
set(CMAKE_THREAD_PREFER_PTHREAD TRUE) | ||
set(THREADS_PREFER_PTHREAD_FLAG TRUE) | ||
find_dependency(Threads) | ||
|
||
add_library(LCI::LCT SHARED IMPORTED) | ||
set_target_properties(LCI::LCT PROPERTIES | ||
IMPORTED_LOCATION ${LCT_SHARED_LIBRARY} | ||
) | ||
target_include_directories(LCI::LCT INTERFACE ${LCT_INCLUDE_DIRS}) | ||
target_link_libraries(LCI::LCT INTERFACE Threads::Threads) | ||
set_and_check(LCT_INCLUDE_DIRS "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@") | ||
set_and_check(LCT_SHARED_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_SHARED_LIBRARY_PREFIX@lct@CMAKE_SHARED_LIBRARY_SUFFIX@") | ||
|
||
check_required_components(LCT) | ||
add_library(LCI::LCT SHARED IMPORTED) | ||
set_target_properties(LCI::LCT PROPERTIES | ||
IMPORTED_LOCATION ${LCT_SHARED_LIBRARY} | ||
) | ||
target_include_directories(LCI::LCT INTERFACE ${LCT_INCLUDE_DIRS}) | ||
target_link_libraries(LCI::LCT INTERFACE Threads::Threads) | ||
|
||
set(LCI_WITH_LCT_ONLY @LCI_WITH_LCT_ONLY@) | ||
if (NOT LCI_WITH_LCT_ONLY) | ||
find_dependency(@FABRIC@) | ||
check_required_components(LCT) | ||
|
||
set_and_check(LCI_INCLUDE_DIRS "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@") | ||
set_and_check(LCI_SHARED_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_SHARED_LIBRARY_PREFIX@lci@CMAKE_SHARED_LIBRARY_SUFFIX@") | ||
# set_and_check(LCI_STATIC_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_STATIC_LIBRARY_PREFIX@lci@CMAKE_STATIC_LIBRARY_SUFFIX@") | ||
set(LCI_WITH_LCT_ONLY @LCI_WITH_LCT_ONLY@) | ||
if (NOT LCI_WITH_LCT_ONLY) | ||
find_dependency(@FABRIC@) | ||
|
||
add_library(LCI::Shared SHARED IMPORTED) | ||
set_target_properties(LCI::Shared PROPERTIES | ||
IMPORTED_LOCATION ${LCI_SHARED_LIBRARY} | ||
) | ||
target_include_directories(LCI::Shared INTERFACE ${LCI_INCLUDE_DIRS}) | ||
target_link_libraries(LCI::Shared INTERFACE Threads::Threads @FABRIC@::@FABRIC@ LCI::LCT) | ||
set_and_check(LCI_INCLUDE_DIRS "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@") | ||
set_and_check(LCI_SHARED_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_SHARED_LIBRARY_PREFIX@lci@CMAKE_SHARED_LIBRARY_SUFFIX@") | ||
# set_and_check(LCI_STATIC_LIBRARY "@PACKAGE_CMAKE_INSTALL_LIBDIR@/@CMAKE_STATIC_LIBRARY_PREFIX@lci@CMAKE_STATIC_LIBRARY_SUFFIX@") | ||
|
||
add_library(LCI::Shared SHARED IMPORTED) | ||
set_target_properties(LCI::Shared PROPERTIES | ||
IMPORTED_LOCATION ${LCI_SHARED_LIBRARY} | ||
) | ||
target_include_directories(LCI::Shared INTERFACE ${LCI_INCLUDE_DIRS}) | ||
target_link_libraries(LCI::Shared INTERFACE Threads::Threads @FABRIC@::@FABRIC@ LCI::LCT) | ||
|
||
add_library(LCI::LCI ALIAS LCI::Shared) | ||
add_library(LCI::LCI ALIAS LCI::Shared) | ||
|
||
# add_library(LCI::Static STATIC IMPORTED) | ||
# set_target_properties(LCI::Static PROPERTIES | ||
# IMPORTED_LOCATION ${LCI_STATIC_LIBRARY} | ||
# ) | ||
# target_include_directories(LCI::Static INTERFACE ${LCI_INCLUDE_DIRS}) | ||
# target_link_libraries(LCI::Static INTERFACE Threads::Threads @FABRIC@::@FABRIC@) | ||
# add_library(LCI::Static STATIC IMPORTED) | ||
# set_target_properties(LCI::Static PROPERTIES | ||
# IMPORTED_LOCATION ${LCI_STATIC_LIBRARY} | ||
# ) | ||
# target_include_directories(LCI::Static INTERFACE ${LCI_INCLUDE_DIRS}) | ||
# target_link_libraries(LCI::Static INTERFACE Threads::Threads @FABRIC@::@FABRIC@) | ||
|
||
check_required_components(LCI) | ||
check_required_components(LCI) | ||
endif() | ||
endif() |