1 file(GLOB_RECURSE SOURCES "src/*.cpp")
2 file(GLOB_RECURSE TESTS "src/*.test.cpp")
3 list(REMOVE_ITEM SOURCES ${TESTS})
5 add_library(loco SHARED ${SOURCES})
6 target_include_directories(loco PUBLIC include)
7 # TODO Remove dependencies on angkor library
8 target_link_libraries(loco PUBLIC angkor)
9 # Let's apply nncc common compile options
11 # NOTE This will enable strict compilation (warnings as error).
12 # Please refer to the top-level CMakeLists.txt for details
13 target_link_libraries(loco PRIVATE nncc_common)
14 target_link_libraries(loco PUBLIC nncc_coverage)
15 # Q. HOW TO MAKE DEV PACKAGE(?)
16 install(TARGETS loco DESTINATION lib)
17 install(DIRECTORY include/ DESTINATION include
18 FILES_MATCHING PATTERN "*.h" PATTERN "*.lst")
22 endif(NOT ENABLE_TEST)
24 # Google Test is mandatory for internal testing
25 nnas_find_package(GTest REQUIRED)
27 GTest_AddTest(loco_test ${TESTS})
28 target_link_libraries(loco_test loco)