##// END OF EJS Templates
Add Catalogue API dependency
perrinel -
r1096:bf5c5de37807
parent child
Show More
@@ -0,0 +1,29
1 # - Try to find CatalogueAPI Module
2 # Once done this will define
3 # CATALOGUEAPI_FOUND - System has CatalogueAPI
4 # CATALOGUEAPI_INCLUDE_DIRS - The CatalogueAPI include directories
5 # CATALOGUEAPI_LIBRARIES - The libraries needed to use CatalogueAPI
6 # CATALOGUEAPI_SHARED_LIBRARIES - The shared libraries for CatalogueAPI
7
8 set(CATALOGUEAPI_ROOT_DIR "${CATALOGUEAPI_EXTERN_FOLDER}"
9 CACHE PATHS
10 "Path to the installation of CatalogueAPI"
11 ${libRootDirForceValue})
12
13 find_path(CATALOGUEAPI_INCLUDE_DIR CatalogueDao.h
14 HINTS ${CATALOGUEAPI_ROOT_DIR} ${CATALOGUEAPI_EXTERN_FOLDER}
15 PATH_SUFFIXES src )
16
17 find_library(CATALOGUEAPI_LIBRARY NAMES CatalogueAPI
18 HINTS ${CATALOGUEAPI_ROOT_DIR} ${CATALOGUEAPI_EXTERN_FOLDER}
19 PATH_SUFFIXES lib)
20
21 set(CATALOGUEAPI_LIBRARIES ${CATALOGUEAPI_LIBRARY} )
22 set(CATALOGUEAPI_INCLUDE_DIRS ${CATALOGUEAPI_INCLUDE_DIR} )
23
24 include(FindPackageHandleStandardArgs)
25 # handle the QUIETLY and REQUIRED arguments and set CATALOGUEAPI_FOUND to TRUE
26 # if all listed variables are TRUE
27 find_package_handle_standard_args(CatalogueAPI FOUND_VAR CATALOGUEAPI_FOUND
28 REQUIRED_VARS CATALOGUEAPI_LIBRARY CATALOGUEAPI_INCLUDE_DIR)
29 mark_as_advanced(CATALOGUEAPI_INCLUDE_DIR CATALOGUEAPI_LIBRARY )
@@ -13,6 +13,13 FIND_PACKAGE(Qt5Test REQUIRED)
13 FIND_PACKAGE(Qt5Gui REQUIRED)
13 FIND_PACKAGE(Qt5Gui REQUIRED)
14
14
15 #
15 #
16 # CatalogueAPI
17 #
18 LIST( APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
19 FIND_PACKAGE(CatalogueAPI)
20
21
22 #
16 # doxygen tools
23 # doxygen tools
17 #
24 #
18 FIND_PACKAGE(Doxygen)
25 FIND_PACKAGE(Doxygen)
@@ -45,6 +45,12 set_property(TARGET ${SQPCORE_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON)
45 TARGET_LINK_LIBRARIES(${SQPCORE_LIBRARY_NAME})
45 TARGET_LINK_LIBRARIES(${SQPCORE_LIBRARY_NAME})
46 qt5_use_modules(${SQPCORE_LIBRARY_NAME} Core Network)
46 qt5_use_modules(${SQPCORE_LIBRARY_NAME} Core Network)
47
47
48 # Find CATALOGUE_API
49 if(CATALOGUEAPI_FOUND)
50 include_directories("${CATALOGUEAPI_INCLUDE_DIRS}")
51 TARGET_LINK_LIBRARIES(${SQPCORE_LIBRARY_NAME} ${CATALOGUEAPI_LIBRARIES})
52 endif()
53
48 INSTALL(TARGETS ${SQPCORE_LIBRARY_NAME}
54 INSTALL(TARGETS ${SQPCORE_LIBRARY_NAME}
49 RUNTIME DESTINATION ${INSTALL_BINARY_DIR}
55 RUNTIME DESTINATION ${INSTALL_BINARY_DIR}
50 LIBRARY DESTINATION ${INSTALL_LIBRARY_DIR}
56 LIBRARY DESTINATION ${INSTALL_LIBRARY_DIR}
General Comments 3
Under Review
author

Auto status change to "Under Review"

Approved

Status change > Approved

You need to be logged in to leave comments. Login now