2 buffer_manager_test.cpp
3 callback_interpreter_system.cpp
5 osc_dispatcher_test.cpp
7 server_dsp_thread_queue_test.cpp
8 server_dsp_thread_test.cpp
9 server_node_graph_test.cpp
10 server_scheduler_test.cpp
11 server_synth_factory_test.cpp
15 sndfile_backend_test.cpp
23 static_allocator_test.cpp
28 if (CMAKE_SYSTEM_NAME MATCHES "Linux")
29 set(simple_tests ${simple_tests}
34 if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_INTEL OR CMAKE_COMPILER_IS_CLANG)
35 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x")
37 message(FATAL_ERROR "unknown compiler. supernova testsuite cannot be compiled")
40 find_package(Sndfile REQUIRED)
42 include_directories(${CMAKE_SOURCE_DIR}/include/common
43 ${CMAKE_SOURCE_DIR}/include/plugin_interface
44 ${CMAKE_SOURCE_DIR}/include/server
45 ${CMAKE_SOURCE_DIR}/server/supernova
46 ${CMAKE_SOURCE_DIR}/external_libraries/boost
47 ${CMAKE_SOURCE_DIR}/external_libraries/boost_endian
48 ${CMAKE_SOURCE_DIR}/external_libraries/boost-lockfree
49 ${CMAKE_SOURCE_DIR}/external_libraries/oscpack
50 ${CMAKE_SOURCE_DIR}/external_libraries/
51 ${CMAKE_SOURCE_DIR}/external_libraries/nova-tt
52 ${CMAKE_SOURCE_DIR}/external_libraries/TLSF-2.4.6/src
53 ${SNDFILE_INCLUDE_DIR}
57 find_package(Portaudio)
58 if(NOT PORTAUDIO_FOUND)
59 message(FATAL_ERROR "Portaudio missing")
61 add_definitions(-DPORTAUDIO_BACKEND ${PORTAUDIO_DEFINITIONS})
62 include_directories(${PORTAUDIO_INCLUDE_DIRS})
64 find_library(JACK NAMES jack)
66 add_definitions(-DJACK_BACKEND)
67 include_directories(${JACK_INCLUDE_DIRS})
72 add_library(boost_test STATIC boost_test.cpp)
75 foreach(test ${simple_tests})
76 string(REPLACE .cpp "" test_name ${test} )
77 add_executable(${test_name} ${test})
80 target_link_libraries(${test_name} ${Boost_THREAD_LIBRARY} ${Boost_SYSTEM_LIBRARY} ${Boost_TEST_LIBRARY})
82 target_link_libraries(${test_name} boost_thread boost_system boost_test)
84 target_link_libraries(${test_name} oscpack tlsf)
85 target_link_libraries(${test_name} ${PTHREADS_LIBRARY})
86 target_link_libraries(${test_name} ${SNDFILE_LIBRARIES})
87 target_link_libraries(${test_name} libsupernova)
90 target_link_libraries(${test_name} "-framework CoreAudio")
93 add_test(${test_name}_run ${EXECUTABLE_OUTPUT_PATH}/${test_name})