Merge branch 'main' of https://github.com/OrcaSlicer/OrcaSlicer_priv into feat/printer-agent-impl

This commit is contained in:
Ian Chua
2026-09-14 12:53:04 +08:00
4822 changed files with 51649 additions and 21136 deletions
+9 -7
View File
@@ -15,7 +15,13 @@ if(WIN32)
# See https://github.com/python/cpython/issues/153438
# Patch from https://github.com/python/cpython/pull/153608
# This patch has not been merged to 3.12 yet so we need to apply it manually
set(_patch_cmd git init && ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/01-windows-nuget.patch)
#
# Without core.autocrlf=false the patched find_python.bat comes out LF and
# cmd.exe cannot find its goto labels.
set(_patch_cmd git init
&& ${GIT_EXECUTABLE} -c core.autocrlf=false apply --verbose
--ignore-space-change --whitespace=fix
${CMAKE_CURRENT_LIST_DIR}/01-windows-nuget.patch)
if(MSVC_VERSION EQUAL 1800)
set(_python_platform_toolset v120)
@@ -53,12 +59,9 @@ if(WIN32)
set(_python_pcbuild_output_dir win32)
endif()
# pybind11 undefines _DEBUG around Python.h so a debug build links the
# release python3xx.lib; Py_DEBUG could not load release plugin modules.
set(_python_pcbuild_config Release)
set(_python_layout_debug OFF)
if(DEFINED DEP_DEBUG AND DEP_DEBUG)
set(_python_pcbuild_config Debug)
set(_python_layout_debug ON)
endif()
# CPython's PCbuild needs a 64-bit-hosted toolchain: find_msbuild.bat picks the
# 32-bit Bin\MSBuild.exe, whose x86 cl.exe/link.exe run out of address space
@@ -101,7 +104,6 @@ if(WIN32)
-DPYTHON_BUILD_DIR=<SOURCE_DIR>/PCbuild/${_python_pcbuild_output_dir}
-DPYTHON_DEST_DIR=${DESTDIR}/libpython
-DPYTHON_LAYOUT_ARCH=${_python_layout_arch}
-DPYTHON_DEBUG=${_python_layout_debug}
-P ${CMAKE_CURRENT_LIST_DIR}/stage_windows.cmake
)
elseif(APPLE)
+3 -17
View File
@@ -9,9 +9,6 @@ foreach(_var PYTHON_SOURCE_DIR PYTHON_BUILD_DIR PYTHON_DEST_DIR PYTHON_LAYOUT_AR
endforeach()
set(_python_exe "${PYTHON_BUILD_DIR}/python.exe")
if(PYTHON_DEBUG)
set(_python_exe "${PYTHON_BUILD_DIR}/python_d.exe")
endif()
if(NOT EXISTS "${_python_exe}")
message(FATAL_ERROR "Built Python executable not found: ${_python_exe}")
@@ -49,22 +46,11 @@ endif()
set(_required_files
"${PYTHON_DEST_DIR}/Lib/encodings/__init__.py"
"${PYTHON_DEST_DIR}/include/Python.h"
"${PYTHON_DEST_DIR}/python.exe"
"${PYTHON_DEST_DIR}/python${_python_abi}.dll"
"${PYTHON_DEST_DIR}/libs/python${_python_abi}.lib"
)
if(PYTHON_DEBUG)
list(APPEND _required_files
"${PYTHON_DEST_DIR}/python_d.exe"
"${PYTHON_DEST_DIR}/python${_python_abi}_d.dll"
"${PYTHON_DEST_DIR}/libs/python${_python_abi}_d.lib"
)
else()
list(APPEND _required_files
"${PYTHON_DEST_DIR}/python.exe"
"${PYTHON_DEST_DIR}/python${_python_abi}.dll"
"${PYTHON_DEST_DIR}/libs/python${_python_abi}.lib"
)
endif()
foreach(_required_file IN LISTS _required_files)
if(NOT EXISTS "${_required_file}")
message(FATAL_ERROR "Staged Python file missing: ${_required_file}")
@@ -0,0 +1,29 @@
diff --git a/src/osx/cocoa/colour.mm b/src/osx/cocoa/colour.mm
index 31515d146f..86b33e94a2 100644
--- a/src/osx/cocoa/colour.mm
+++ b/src/osx/cocoa/colour.mm
@@ -125,3 +125,3 @@
wxOSXEffectiveAppearanceSetter helper;
- if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpaceName:NSCalibratedRGBColorSpace] )
+ if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpace:[NSColorSpace sRGBColorSpace]] )
return [colRGBA redComponent];
@@ -134,3 +134,3 @@
wxOSXEffectiveAppearanceSetter helper;
- if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpaceName:NSCalibratedRGBColorSpace] )
+ if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpace:[NSColorSpace sRGBColorSpace]] )
return [colRGBA greenComponent];
@@ -143,3 +143,3 @@
wxOSXEffectiveAppearanceSetter helper;
- if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpaceName:NSCalibratedRGBColorSpace] )
+ if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpace:[NSColorSpace sRGBColorSpace]] )
return [colRGBA blueComponent];
@@ -152,3 +152,3 @@
wxOSXEffectiveAppearanceSetter helper;
- if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpaceName:NSCalibratedRGBColorSpace] )
+ if ( NSColor* colRGBA = [m_nsColour colorUsingColorSpace:[NSColorSpace sRGBColorSpace]] )
return [colRGBA alphaComponent];
@@ -160,3 +160,3 @@
{
- return [m_nsColour colorUsingColorSpaceName:NSCalibratedRGBColorSpace] != nil;
+ return [m_nsColour colorUsingColorSpace:[NSColorSpace sRGBColorSpace]] != nil;
}
+10
View File
@@ -21,12 +21,22 @@ else ()
set(_wx_edge "-DwxUSE_WEBVIEW_EDGE=OFF")
endif ()
set(_wx_patch_command "")
if (APPLE)
set(_wx_patch_command
${GIT_EXECUTABLE} checkout -f -- src/osx/cocoa/colour.mm
COMMAND ${GIT_EXECUTABLE} apply --verbose
${CMAKE_CURRENT_LIST_DIR}/0001-macos-use-srgb-colour-components.patch
)
endif ()
orcaslicer_add_cmake_project(
wxWidgets
GIT_REPOSITORY "https://github.com/SoftFever/Orca-deps-wxWidgets"
GIT_TAG v3.3.2
GIT_SHALLOW ON
GIT_SUBMODULES 3rdparty/catch 3rdparty/pcre 3rdparty/libwebp
PATCH_COMMAND ${_wx_patch_command}
DEPENDS ${PNG_PKG} ${ZLIB_PKG} ${EXPAT_PKG} ${JPEG_PKG}
CMAKE_ARGS
-DwxBUILD_PRECOMP=ON