File tree Expand file tree Collapse file tree 1 file changed +1
-18
lines changed
Expand file tree Collapse file tree 1 file changed +1
-18
lines changed Original file line number Diff line number Diff line change @@ -160,17 +160,7 @@ if (GGML_OPENMP)
160160
161161 add_compile_definitions (GGML_USE_OPENMP)
162162
163- # On non-MSVC platforms keep linking the imported OpenMP target
164- if (MSVC )
165- message (STATUS "MSVC detected — will request -openmp:experimental and avoid OpenMP::OpenMP_CXX to prevent /openmp being injected earlier" )
166- # record a flag to apply to the ggml target later (ensures it appears last on the command line)
167- set (GGML_MSVC_OPENMP_FLAG "-openmp:experimental" )
168- # Do NOT add OpenMP::OpenMP_C / CXX to GGML_EXTRA_LIBS on MSVC so that CMake's OpenMP usage requirements
169- # don't inject /openmp (which could override experimental if it appears later).
170- else ()
171- # Non-MSVC: keep the imported OpenMP targets
172- set (GGML_EXTRA_LIBS ${GGML_EXTRA_LIBS} OpenMP::OpenMP_C OpenMP::OpenMP_CXX)
173- endif ()
163+ set (GGML_EXTRA_LIBS ${GGML_EXTRA_LIBS} OpenMP::OpenMP_C OpenMP::OpenMP_CXX)
174164
175165 if (GGML_MUSA)
176166 set (GGML_EXTRA_INCLUDES ${GGML_EXTRA_INCLUDES} "/usr/lib/llvm-10/include/openmp" )
@@ -1579,13 +1569,6 @@ add_library(ggml
15791569 ggml-aarch64.c ggml-aarch64.h
15801570 )
15811571
1582- # Ensure MSVC experimental flag is appended to the compile options for the ggml target
1583- if (MSVC AND GGML_OPENMP AND DEFINED GGML_MSVC_OPENMP_FLAG)
1584- message (STATUS "Appending ${GGML_MSVC_OPENMP_FLAG} to target 'ggml' compile options" )
1585- # Use APPEND so the flag is added after any other compile options (last wins on MSVC)
1586- set_property (TARGET ggml APPEND PROPERTY COMPILE_OPTIONS "${GGML_MSVC_OPENMP_FLAG} " )
1587- endif ()
1588-
15891572if (EMSCRIPTEN)
15901573 set_target_properties (ggml PROPERTIES COMPILE_FLAGS "-msimd128" )
15911574endif ()
You can’t perform that action at this time.
0 commit comments