mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-28 11:21:30 +00:00
Fix MacOS 27 Xcode and Command Line build failures (#15923)
This commit is contained in:
+7
-2
@@ -56,9 +56,9 @@ You can do this in Environment Variables settings.
|
|||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
# if CMAKE_OSX_DEPLOYMENT_TARGET is not set, set it to 11.3
|
# if CMAKE_OSX_DEPLOYMENT_TARGET is not set, set it to 12.0 (the lowest Xcode 27 accepts)
|
||||||
if (NOT CMAKE_OSX_DEPLOYMENT_TARGET)
|
if (NOT CMAKE_OSX_DEPLOYMENT_TARGET)
|
||||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.3" CACHE STRING "Minimum OS X deployment version" FORCE)
|
set(CMAKE_OSX_DEPLOYMENT_TARGET "12.0" CACHE STRING "Minimum OS X deployment version" FORCE)
|
||||||
endif ()
|
endif ()
|
||||||
message(STATUS "CMAKE_OSX_DEPLOYMENT_TARGET: ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
message(STATUS "CMAKE_OSX_DEPLOYMENT_TARGET: ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||||
endif ()
|
endif ()
|
||||||
@@ -279,6 +279,11 @@ if (APPLE)
|
|||||||
endif()
|
endif()
|
||||||
SET(CMAKE_XCODE_ATTRIBUTE_PRODUCT_BUNDLE_IDENTIFIER "com.orcaslicer.OrcaSlicer")
|
SET(CMAKE_XCODE_ATTRIBUTE_PRODUCT_BUNDLE_IDENTIFIER "com.orcaslicer.OrcaSlicer")
|
||||||
|
|
||||||
|
# The macOS CI jobs build with Ninja (build_release_macos.sh -x), so the Xcode generator
|
||||||
|
# is not covered. Xcode adds -Wshorten-64-to-32 by default ("Implicit Conversion to 32 Bit
|
||||||
|
# Type"); Ninja/-Wall does not, and under -Werror it fails Xcode builds on code CI accepts.
|
||||||
|
set(CMAKE_XCODE_ATTRIBUTE_GCC_WARN_64_TO_32_BIT_CONVERSION "NO")
|
||||||
|
|
||||||
message(STATUS "Orca: IS_CROSS_COMPILE: ${IS_CROSS_COMPILE}")
|
message(STATUS "Orca: IS_CROSS_COMPILE: ${IS_CROSS_COMPILE}")
|
||||||
elseif (CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
elseif (CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||||
set(CMAKE_INSTALL_RPATH "$ORIGIN")
|
set(CMAKE_INSTALL_RPATH "$ORIGIN")
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ while getopts ":dpa:snt:xbc:i:j:Tuh" opt; do
|
|||||||
echo " -s: Build slicer only"
|
echo " -s: Build slicer only"
|
||||||
echo " -u: Build universal app only (requires existing arm64 and x86_64 app bundles)"
|
echo " -u: Build universal app only (requires existing arm64 and x86_64 app bundles)"
|
||||||
echo " -n: Nightly build"
|
echo " -n: Nightly build"
|
||||||
echo " -t: Specify minimum version of the target platform, default is 11.3"
|
echo " -t: Specify minimum version of the target platform, default is 12.0"
|
||||||
echo " -x: Use Ninja Multi-Config CMake generator, default is Xcode"
|
echo " -x: Use Ninja Multi-Config CMake generator, default is Xcode"
|
||||||
echo " -b: Build without reconfiguring CMake"
|
echo " -b: Build without reconfiguring CMake"
|
||||||
echo " -c: Set CMake build configuration, default is Release"
|
echo " -c: Set CMake build configuration, default is Release"
|
||||||
@@ -95,7 +95,7 @@ if [ -z "$DEPS_CMAKE_GENERATOR" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$OSX_DEPLOYMENT_TARGET" ]; then
|
if [ -z "$OSX_DEPLOYMENT_TARGET" ]; then
|
||||||
export OSX_DEPLOYMENT_TARGET="11.3"
|
export OSX_DEPLOYMENT_TARGET="12.0"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$CMAKE_IGNORE_PREFIX_PATH" ]; then
|
if [ -z "$CMAKE_IGNORE_PREFIX_PATH" ]; then
|
||||||
|
|||||||
Vendored
+2
-2
@@ -26,9 +26,9 @@ endif()
|
|||||||
|
|
||||||
cmake_minimum_required(VERSION 3.2)
|
cmake_minimum_required(VERSION 3.2)
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
# if CMAKE_OSX_DEPLOYMENT_TARGET is not set, set it to 11.3
|
# if CMAKE_OSX_DEPLOYMENT_TARGET is not set, set it to 12.0 (the lowest Xcode 27 accepts)
|
||||||
if (NOT CMAKE_OSX_DEPLOYMENT_TARGET)
|
if (NOT CMAKE_OSX_DEPLOYMENT_TARGET)
|
||||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.3" CACHE STRING "Minimum OS X deployment version" FORCE)
|
set(CMAKE_OSX_DEPLOYMENT_TARGET "12.0" CACHE STRING "Minimum OS X deployment version" FORCE)
|
||||||
endif ()
|
endif ()
|
||||||
message(STATUS "CMAKE_OSX_DEPLOYMENT_TARGET: ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
message(STATUS "CMAKE_OSX_DEPLOYMENT_TARGET: ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user