2 pkg_check_modules(test_pkgs REQUIRED dlog zlib minizip storage glib-2.0)
4 FOREACH(flag ${test_pkgs_CFLAGS})
5 SET(TEST_CFLAGS "${TEST_CFLAGS} ${flag}")
7 SET(CMAKE_C_FLAGS "${EXTRA_CFLAGS} ${TEST_CFLAGS}")
9 # Local include directories
10 INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/inc)
12 SET(SRCS ${CMAKE_SOURCE_DIR}/test/src/test_app2ext.c)
14 ADD_EXECUTABLE(test_app2ext ${SRCS})
15 TARGET_LINK_LIBRARIES(test_app2ext app2ext ${test_pkgs_LDFLAGS})
16 SET_TARGET_PROPERTIES(test_app2ext PROPERTIES COMPILE_FLAGS ${CFLAGS} "-fPIE")
17 SET_TARGET_PROPERTIES(test_app2ext PROPERTIES LINK_FLAGS "-pie")
19 INSTALL(TARGETS test_app2ext DESTINATION /usr/bin COMPONENT Runtime)