cmake: fix GCC linking errors for 'test_internal' target

This commit is contained in:
Hugues Delorme 2015-04-09 18:02:31 +02:00
parent 6b7c63a175
commit f66e35638d

View File

@ -224,6 +224,10 @@ add_executable(test_internal EXCLUDE_FROM_ALL tests/stream_buffer.c
src/gmio_core/internal/string_parse.c) src/gmio_core/internal/string_parse.c)
add_executable(test_platform EXCLUDE_FROM_ALL tests/test_platform.c) add_executable(test_platform EXCLUDE_FROM_ALL tests/test_platform.c)
if(CMAKE_COMPILER_IS_GNUCC)
target_link_libraries(test_internal m) # -lm
endif()
add_test(test_internal test_internal) add_test(test_internal test_internal)
add_test(test_platform test_platform) add_test(test_platform test_platform)