mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-06-11 06:23:08 +00:00
fix windows not copy library bug
This commit is contained in:
@@ -808,7 +808,8 @@ function(Snapmaker_Orca_copy_dlls target config postfix output_dlls)
|
||||
${CMAKE_PREFIX_PATH}/bin/freetype.dll
|
||||
DESTINATION ${_out_dir})
|
||||
|
||||
set(${output_dlls}
|
||||
# Build the DLL list in a local variable first
|
||||
set(_dll_list
|
||||
${_out_dir}/libgmp-10.dll
|
||||
${_out_dir}/libmpfr-4.dll
|
||||
${_out_dir}/WebView2Loader.dll
|
||||
@@ -841,20 +842,19 @@ function(Snapmaker_Orca_copy_dlls target config postfix output_dlls)
|
||||
${_out_dir}/TKXSBase.dll
|
||||
|
||||
${_out_dir}/freetype.dll
|
||||
|
||||
PARENT_SCOPE
|
||||
)
|
||||
|
||||
# Add Sentry DLLs to the output list if Sentry is enabled
|
||||
# Add Sentry DLLs to the list if Sentry is enabled
|
||||
if (SLIC3R_SENTRY)
|
||||
set(${output_dlls}
|
||||
${${output_dlls}}
|
||||
list(APPEND _dll_list
|
||||
${_out_dir}/sentry.dll
|
||||
${_out_dir}/crashpad_handler.exe
|
||||
PARENT_SCOPE
|
||||
)
|
||||
endif()
|
||||
|
||||
# Set the output variable in parent scope (only once, with complete list)
|
||||
set(${output_dlls} ${_dll_list} PARENT_SCOPE)
|
||||
|
||||
endfunction()
|
||||
|
||||
|
||||
|
||||
@@ -226,8 +226,13 @@ if (WIN32)
|
||||
foreach (CONF ${CMAKE_CONFIGURATION_TYPES})
|
||||
if ("${CONF}" STREQUAL "Debug")
|
||||
Snapmaker_Orca_copy_dlls(COPY_DLLS "${CONF}" "d" output_dlls_Debug)
|
||||
else()
|
||||
elseif ("${CONF}" STREQUAL "Release")
|
||||
Snapmaker_Orca_copy_dlls(COPY_DLLS "${CONF}" "" output_dlls_Release)
|
||||
elseif ("${CONF}" STREQUAL "RelWithDebInfo")
|
||||
Snapmaker_Orca_copy_dlls(COPY_DLLS "${CONF}" "" output_dlls_RelWithDebInfo)
|
||||
else()
|
||||
# MinSizeRel or other configs
|
||||
Snapmaker_Orca_copy_dlls(COPY_DLLS "${CONF}" "" _unused_dlls)
|
||||
endif()
|
||||
endforeach ()
|
||||
else ()
|
||||
|
||||
Reference in New Issue
Block a user