aboutsummaryrefslogtreecommitdiff
path: root/tests/CMakeLists.txt
diff options
context:
space:
mode:
authorAndreas Schneider <asn@cryptomilk.org>2018-08-22 12:52:20 +0200
committerAndreas Schneider <asn@cryptomilk.org>2018-08-22 13:02:28 +0200
commitc49a7bc032c751095bc8cc24c6e54887c059866a (patch)
treee8b246900874353e8776c9e5891088ebfd39042d /tests/CMakeLists.txt
parentb8cf442fb82b720161a9c5b1551c3bd6482f5a75 (diff)
downloadcmocka-c49a7bc032c751095bc8cc24c6e54887c059866a.tar.gz
cmocka-c49a7bc032c751095bc8cc24c6e54887c059866a.tar.xz
cmocka-c49a7bc032c751095bc8cc24c6e54887c059866a.zip
cmake: Add new CompilerCheck.cmake
Diffstat (limited to 'tests/CMakeLists.txt')
-rw-r--r--tests/CMakeLists.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 7a529d4..3789b1b 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -28,6 +28,7 @@ set(CMOCKA_TESTS
foreach(_CMOCKA_TEST ${CMOCKA_TESTS})
add_cmocka_test(${_CMOCKA_TEST} ${_CMOCKA_TEST}.c ${CMOCKA_STATIC_LIBRARY})
+ target_compile_options(${_CMOCKA_TEST} PRIVATE ${DEFAULT_C_COMPILE_FLAGS})
endforeach()
### Special Cases
@@ -35,6 +36,7 @@ if (${CMAKE_C_COMPILER_ID} MATCHES "(GNU|Clang)")
set_source_files_properties(test_cmockery.c PROPERTIES COMPILE_FLAGS "-Wno-deprecated-declarations")
endif()
add_cmocka_test(test_cmockery test_cmockery.c ${CMOCKA_STATIC_LIBRARY})
+target_compile_options(test_cmockery PRIVATE ${DEFAULT_C_COMPILE_FLAGS})
### Exceptions