CMakeLists.txt fix for OpenMP
This commit is contained in:
parent
bf10e1ac2e
commit
3b1eb44865
1 changed files with 3 additions and 2 deletions
|
|
@ -30,13 +30,14 @@ target_link_libraries(OCCTSurfacer
|
||||||
|
|
||||||
|
|
||||||
if(OpenMP_CXX_FOUND)
|
if(OpenMP_CXX_FOUND)
|
||||||
target_compile_options(OCCTSurfacer PUBLIC -Xpreprocessor -fopenmp)
|
target_link_libraries(OCCTSurfacer PUBLIC OpenMP::OpenMP_CXX)
|
||||||
target_link_libraries(OCCTSurfacer PUBLIC omp)
|
|
||||||
target_compile_definitions(OCCTSurfacer PUBLIC ENABLE_OPENMP)
|
target_compile_definitions(OCCTSurfacer PUBLIC ENABLE_OPENMP)
|
||||||
else()
|
else()
|
||||||
message(WARNING "OpenMP not found. The program will be built without OpenMP support.")
|
message(WARNING "OpenMP not found. The program will be built without OpenMP support.")
|
||||||
target_compile_definitions(OCCTSurfacer PUBLIC DISABLE_OPENMP)
|
target_compile_definitions(OCCTSurfacer PUBLIC DISABLE_OPENMP)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
install(TARGETS OCCTSurfacer RUNTIME DESTINATION bin)
|
||||||
|
|
||||||
include(CTest)
|
include(CTest)
|
||||||
enable_testing()
|
enable_testing()
|
||||||
Loading…
Reference in a new issue