diff options
-rw-r--r-- | gr-dtv/lib/CMakeLists.txt | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gr-dtv/lib/CMakeLists.txt b/gr-dtv/lib/CMakeLists.txt index 9efbd7f9b0..61abd10dc2 100644 --- a/gr-dtv/lib/CMakeLists.txt +++ b/gr-dtv/lib/CMakeLists.txt @@ -117,7 +117,12 @@ if (MSVC) CHECK_C_COMPILER_FLAG ("/arch:SSE2" SSE2_SUPPORTED) endif(CMAKE_SIZEOF_VOID_P EQUAL 8) else () - CHECK_C_COMPILER_FLAG ("-msse2" SSE2_SUPPORTED) + # The "correct" way to test this would be to run + # check_c_compiler_flag("-msse2") + # ...but that's not reliable, in particular, on Clang and ARM, it will + # return TRUE when it shouldn't. Hence, we compile this snippet + # manually. + check_c_source_compiles("#include <emmintrin.h>\nint main(){__m128i m0, m1, m2; m0 = _mm_add_epi8(m1, m2);}" SSE2_SUPPORTED) endif(MSVC) if(SSE2_SUPPORTED) |