diff options
author | Magnus Lundborg <lundborg.magnus@gmail.com> | 2013-02-11 07:27:54 (GMT) |
---|---|---|
committer | Magnus Lundborg <lundborg.magnus@gmail.com> | 2013-02-11 07:27:54 (GMT) |
commit | 1d4bcf5ef8bc3cec9dac0d1b97079dbe835517e6 (patch) | |
tree | dfdb0bb1931a6e0f1b13f9a3c029f4816b317db4 /src/tests/CMakeLists.txt | |
parent | 8a7c0daaccb5ee837b2a036a9f3cf39a1ca9435e (diff) |
Remove omp header stubs
Diffstat (limited to 'src/tests/CMakeLists.txt')
-rw-r--r-- | src/tests/CMakeLists.txt | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index 1a276ed..8ec785b 100644 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -13,8 +13,10 @@ include_directories(${CMAKE_BINARY_DIR}/generated/) add_executable(tng_testing tng_io_testing.c) target_link_libraries(tng_testing tng_io) -add_executable(md_openmp md_openmp.c) -target_link_libraries(md_openmp tng_io ${OpenMP_LIBS} m) +if(OPENMP_FOUND) + add_executable(md_openmp md_openmp.c) + target_link_libraries(md_openmp tng_io ${OpenMP_LIBS} m) +endif() add_executable(tng_io_read_pos tng_io_read_pos.c) target_link_libraries(tng_io_read_pos tng_io) @@ -30,7 +32,9 @@ if(BUILD_FORTRAN) if (Fortran_COMPILER_NAME STREQUAL "gfortran") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -fcray-pointer ${OpenMP_C_FLAGS} -std=legacy") endif() - add_executable(md_openmp_f md_openmp.f) - target_link_libraries(md_openmp_f tng_io ${OpenMP_LIBS}) + if(OPENMP_FOUND) + add_executable(md_openmp_f md_openmp.f) + target_link_libraries(md_openmp_f tng_io ${OpenMP_LIBS}) + endif() endif() endif() |