FEAT: Universal Mac Builds - Unified WHL for ARM64 and Intel #86
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This pull request introduces changes to standardize macOS builds by adopting the "universal2" architecture, which supports both
arm64
andx86_64
. The updates simplify the build process, ensure consistency across tools, and improve compatibility. Key changes include modifications to the CMake configuration, build scripts, and Python packaging setup.macOS Build Standardization:
mssql_python/pybind/CMakeLists.txt
: Replaced architecture-specific logic with a universal2 configuration for macOS, settingARCHITECTURE
to "universal2" and ensuringCMAKE_OSX_ARCHITECTURES
is set toarm64;x86_64
. UpdatedWHEEL_ARCH
to "universal2" for macOS builds. [1] [2] [3]mssql_python/pybind/build.sh
: Simplified the macOS build script by removing architecture-specific handling and ensuring the build process defaults to creating universal2 binaries. Added diagnostics to verify the resulting binary. [1] [2]Python Packaging Updates:
setup.py
: Updated macOS-specific logic to always use the "universal2" platform tag (macosx_15_0_universal2
) for wheel packaging. Removed architecture detection and replaced it with a unified configuration. [1] [2]These changes streamline the macOS build process, reduce complexity, and ensure compatibility with both Apple Silicon and Intel-based Macs.
Issue Reference
Fixes AB#37761
Checklist
Testing Performed
Additional Notes