ComparatorLib:core: Add menu option to conditionally enable
This commit is contained in:
@@ -1,21 +1,26 @@
|
|||||||
add_library(coreComp SHARED
|
option(ENABLE_COMPARATORLIB_core
|
||||||
coreComp.cpp
|
"Enable comparator lib core (libcoreComp.so)" ON)
|
||||||
)
|
|
||||||
|
|
||||||
set_target_properties(coreComp PROPERTIES
|
if(ENABLE_COMPARATORLIB_core)
|
||||||
VERSION ${PROJECT_VERSION}
|
add_library(coreComp SHARED
|
||||||
SOVERSION ${PROJECT_VERSION_MAJOR}
|
coreComp.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
target_include_directories(coreComp PUBLIC
|
set_target_properties(coreComp PROPERTIES
|
||||||
${CMAKE_SOURCE_DIR}/include
|
VERSION ${PROJECT_VERSION}
|
||||||
${CMAKE_SOURCE_DIR}/smocore/include
|
SOVERSION ${PROJECT_VERSION_MAJOR}
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(coreComp PUBLIC
|
target_include_directories(coreComp PUBLIC
|
||||||
spinscale
|
${CMAKE_SOURCE_DIR}/include
|
||||||
)
|
${CMAKE_SOURCE_DIR}/smocore/include
|
||||||
|
)
|
||||||
|
|
||||||
install(TARGETS coreComp
|
target_link_libraries(coreComp PUBLIC
|
||||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} NAMELINK_SKIP
|
spinscale
|
||||||
)
|
)
|
||||||
|
|
||||||
|
install(TARGETS coreComp
|
||||||
|
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} NAMELINK_SKIP
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|||||||
Reference in New Issue
Block a user