diff options
author | Daniil Cherednik <dan.cherednik@gmail.com> | 2023-11-18 22:29:30 +0100 |
---|---|---|
committer | Daniil Cherednik <dan.cherednik@gmail.com> | 2023-11-19 00:22:33 +0100 |
commit | 5a5274daecb00b0c4df1b25dc57a65f3f44fe9a8 (patch) | |
tree | 25acd680fa565ecd60cee3dfba1a85c0221cf430 /test | |
parent | 9d1c670a6ad2eefda7180640c5bf0fcdb01b3e0f (diff) | |
download | atracdenc-5a5274daecb00b0c4df1b25dc57a65f3f44fe9a8.tar.gz |
Get rid of gtest files. Use system package if available.
(cherry picked from commit ff401eccf9f4d37193751633c2cf9beada2fd754)
Diffstat (limited to 'test')
-rw-r--r-- | test/CMakeLists.txt | 29 |
1 files changed, 4 insertions, 25 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 250f7d6..4b5c295 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -1,28 +1,7 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 2.8) +CMAKE_MINIMUM_REQUIRED(VERSION 3.1) -macro(use_11) - if (CMAKE_VERSION VERSION_LESS "3.1") - message ("cmake version: " ${CMAKE_VERSION} " --std arguments will be forced") - - set (CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}" CACHE STRING "" FORCE) - set (CMAKE_C_FLAGS "-std=c11 ${CMAKE_C_FLAGS}" CACHE STRING "" FORCE) - else () - set (CMAKE_CXX_STANDARD 11) - set (CMAKE_C_STANDARD 11) - endif () -endmacro(use_11) - -use_11() - -if (CMAKE_SYSTEM_PROCESSOR MATCHES "(x86)|(X86)|(amd64)|(AMD64)") - message ("Using -fsanitize=address") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -fsanitize=address -fno-omit-frame-pointer") -else () - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -fno-omit-frame-pointer") -endif () - - -include_directories(${gtest_SOURCE_DIR}/include) +set (CMAKE_CXX_STANDARD 11) +set (CMAKE_C_STANDARD 11) set(atracdenc_ut ../src/mdct/mdct_ut.cpp @@ -37,9 +16,9 @@ add_executable(atracdenc_ut ${atracdenc_ut}) target_link_libraries(atracdenc_ut bitstream fft_impl - gtest_main atracdenc_impl oma + GTest::gtest_main ) enable_testing() |