File: CMakeLists.txt

package info (click to toggle)
msgpuck 1.0.3-1.2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 380 kB
  • sloc: ansic: 2,721; makefile: 4
file content (21 lines) | stat: -rw-r--r-- 507 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
include_directories("../")

#find_program(PROVE prove)
if (PROVE)
    set(TEST_RUNNER prove)
else()
    set(TEST_RUNNER)
endif()

set(alltests)
foreach (test msgpuck)
    add_executable(${test}.test ${test}.c test.c)
    target_link_libraries(${test}.test msgpuck)

    list(APPEND alltests ${test}.test_run)
    add_custom_target(${test}.test_run
        DEPENDS ${test}.test
        COMMAND ${TEST_RUNNER} ${PROJECT_BINARY_DIR}/test/${test}.test)
endforeach()

add_custom_target(test DEPENDS ${alltests})