diff --git a/pybind_interface/avx2/CMakeLists.txt b/pybind_interface/avx2/CMakeLists.txt index 18047a1e..ab7d6d83 100644 --- a/pybind_interface/avx2/CMakeLists.txt +++ b/pybind_interface/avx2/CMakeLists.txt @@ -14,3 +14,5 @@ if(APPLE) endif() INCLUDE(../GetPybind11.cmake) pybind11_add_module(qsim_avx2 pybind_main_avx2.cpp) + +target_link_libraries(qsim_avx2 PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/avx512/CMakeLists.txt b/pybind_interface/avx512/CMakeLists.txt index 5875c08c..9d635dd0 100644 --- a/pybind_interface/avx512/CMakeLists.txt +++ b/pybind_interface/avx512/CMakeLists.txt @@ -16,3 +16,5 @@ endif() INCLUDE(../GetPybind11.cmake) pybind11_add_module(qsim_avx512 pybind_main_avx512.cpp) + +target_link_libraries(qsim_avx512 PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/basic/CMakeLists.txt b/pybind_interface/basic/CMakeLists.txt index 36bdfc8d..ab9cd94b 100644 --- a/pybind_interface/basic/CMakeLists.txt +++ b/pybind_interface/basic/CMakeLists.txt @@ -16,3 +16,5 @@ endif() INCLUDE(../GetPybind11.cmake) pybind11_add_module(qsim_basic pybind_main_basic.cpp) + +target_link_libraries(qsim_basic PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/cuda/CMakeLists.txt b/pybind_interface/cuda/CMakeLists.txt index 29fd367c..89df1948 100644 --- a/pybind_interface/cuda/CMakeLists.txt +++ b/pybind_interface/cuda/CMakeLists.txt @@ -26,3 +26,5 @@ set_target_properties(qsim_cuda PROPERTIES SUFFIX "${PYTHON_MODULE_EXTENSION}" ) set_source_files_properties(pybind_main_cuda.cpp PROPERTIES LANGUAGE CUDA) + +target_link_libraries(qsim_cuda PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/custatevec/CMakeLists.txt b/pybind_interface/custatevec/CMakeLists.txt index 1c34a1d9..77fe6631 100644 --- a/pybind_interface/custatevec/CMakeLists.txt +++ b/pybind_interface/custatevec/CMakeLists.txt @@ -44,3 +44,5 @@ set_target_properties(qsim_custatevec PROPERTIES SUFFIX "${PYTHON_MODULE_EXTENSION}" ) set_source_files_properties(pybind_main_custatevec.cpp PROPERTIES LANGUAGE CUDA) + +target_link_libraries(qsim_custatevec PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/decide/CMakeLists.txt b/pybind_interface/decide/CMakeLists.txt index b3dac71c..15d51707 100644 --- a/pybind_interface/decide/CMakeLists.txt +++ b/pybind_interface/decide/CMakeLists.txt @@ -44,3 +44,5 @@ elseif(has_hipcc) else() pybind11_add_module(qsim_decide decide.cpp) endif() + +target_link_libraries(qsim_decide PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/hip/CMakeLists.txt b/pybind_interface/hip/CMakeLists.txt index b56687ab..8d540c90 100644 --- a/pybind_interface/hip/CMakeLists.txt +++ b/pybind_interface/hip/CMakeLists.txt @@ -22,3 +22,5 @@ set_target_properties(qsim_hip PROPERTIES SUFFIX "${PYTHON_MODULE_EXTENSION}" ) set_source_files_properties(pybind_main_hip.cpp PROPERTIES LANGUAGE HIP) + +target_link_libraries(qsim_hip PUBLIC OpenMP::OpenMP_CXX) diff --git a/pybind_interface/sse/CMakeLists.txt b/pybind_interface/sse/CMakeLists.txt index 9be08400..a9123a5a 100644 --- a/pybind_interface/sse/CMakeLists.txt +++ b/pybind_interface/sse/CMakeLists.txt @@ -16,3 +16,5 @@ endif() INCLUDE(../GetPybind11.cmake) pybind11_add_module(qsim_sse pybind_main_sse.cpp) + +target_link_libraries(qsim_sse PUBLIC OpenMP::OpenMP_CXX)