aboutsummaryrefslogtreecommitdiff
path: root/audio/libmysofa/files/patch-CMakeLists.txt
blob: 6f0b48a1ace92bbd70880965f8e40d72b9685d64 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
The tests/compare.sh script is written to be run relative to the directory it
is in, so we need to direct CMake to execute it from the tests directory
instead of the top source directory.

--- CMakeLists.txt.orig	2017-07-11 11:36:33 UTC
+++ CMakeLists.txt
@@ -38,14 +38,14 @@ if(BUILD_TESTS)
 
   enable_testing()
 
-  add_test(CIPIC_subject_003_hrir_final ../tests/compare.sh ../tests/CIPIC_subject_003_hrir_final)
-  add_test(FHK_HRIR_L2354.sofa ../tests/compare.sh ../tests/FHK_HRIR_L2354)
-  add_test(LISTEN_1002_IRC_1002_C_HRIR.sofa ../tests/compare.sh ../tests/LISTEN_1002_IRC_1002_C_HRIR)
-  add_test(MIT_KEMAR_large_pinna.sofa ../tests/compare.sh ../tests/MIT_KEMAR_large_pinna)
-  add_test(Pulse ../tests/compare.sh ../tests/Pulse)
-  add_test(Tester ../tests/compare.sh ../tests/tester)
-  add_test(TU-Berlin_QU_KEMAR_anechoic_radius_0.5_1_2_3_m.sofa ../tests/compare.sh ../tests/TU-Berlin_QU_KEMAR_anechoic_radius_0.5_1_2_3_m)
-  add_test(TU-Berlin_QU_KEMAR_anechoic_radius_0.5m.sofa ../tests/compare.sh ../tests/TU-Berlin_QU_KEMAR_anechoic_radius_0.5m)
+  add_test(NAME CIPIC_subject_003_hrir_final COMMAND compare.sh CIPIC_subject_003_hrir_final WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME FHK_HRIR_L2354.sofa COMMAND compare.sh FHK_HRIR_L2354 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME LISTEN_1002_IRC_1002_C_HRIR.sofa COMMAND compare.sh LISTEN_1002_IRC_1002_C_HRIR WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME MIT_KEMAR_large_pinna.sofa COMMAND compare.sh MIT_KEMAR_large_pinna WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME Pulse COMMAND compare.sh Pulse WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME Tester COMMAND compare.sh tester WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME TU-Berlin_QU_KEMAR_anechoic_radius_0.5_1_2_3_m.sofa COMMAND compare.sh TU-Berlin_QU_KEMAR_anechoic_radius_0.5_1_2_3_m WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
+  add_test(NAME TU-Berlin_QU_KEMAR_anechoic_radius_0.5m.sofa COMMAND compare.sh TU-Berlin_QU_KEMAR_anechoic_radius_0.5m WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/tests)
 endif(BUILD_TESTS)
 
 add_subdirectory(src)