Skip to content

Commit 3bf06c7

Browse files
mayeuthenryiii
authored andcommitted
Only build 1 platform wheel for macOS
1 parent 72a77b7 commit 3bf06c7

File tree

5 files changed

+14
-31
lines changed

5 files changed

+14
-31
lines changed

.travis.yml

-12
Original file line numberDiff line numberDiff line change
@@ -17,24 +17,12 @@ matrix:
1717
- PYTHON_VERSION=3.7.9
1818
- MACOSX_DEPLOYMENT_TARGET=10.10
1919

20-
- os: osx
21-
language: generic
22-
env:
23-
- PYTHON_VERSION=3.7.9
24-
- MACOSX_DEPLOYMENT_TARGET=10.13
25-
2620
- os: osx
2721
language: generic
2822
env:
2923
- PYTHON_VERSION=2.7.18
3024
- MACOSX_DEPLOYMENT_TARGET=10.10
3125

32-
- os: osx
33-
language: generic
34-
env:
35-
- PYTHON_VERSION=2.7.18
36-
- MACOSX_DEPLOYMENT_TARGET=10.13
37-
3826
- arch: arm64-graviton2
3927
virt: vm
4028
group: edge

CMakeLists.txt

+1-3
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,8 @@ if(CMakePythonDistributions_SUPERBUILD)
6868
if(APPLE)
6969
if("${CMAKE_OSX_DEPLOYMENT_TARGET}" VERSION_LESS "10.10")
7070
message(FATAL_ERROR "Unsupported macOS deployment target: ${CMAKE_OSX_DEPLOYMENT_TARGET} is less than 10.10")
71-
elseif("${CMAKE_OSX_DEPLOYMENT_TARGET}" VERSION_LESS "10.13")
72-
set(binary_archive "macos10_10_binary")
7371
else()
74-
set(binary_archive "macos10_13_binary")
72+
set(binary_archive "macos10_10_binary")
7573
endif()
7674
endif()
7775
if(WIN32)

CMakeUrls.cmake

-3
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,6 @@ set(linux32_binary_sha256 "NA")
1616
set(linux64_binary_url "https://github.com/Kitware/CMake/releases/download/v3.20.2/cmake-3.20.2-linux-x86_64.tar.gz")
1717
set(linux64_binary_sha256 "3f827544f9c82e74ddf5016461fdfcfea4ede58a26f82612f473bf6bfad8bfc2")
1818

19-
set(macos10_13_binary_url "https://github.com/Kitware/CMake/releases/download/v3.20.2/cmake-3.20.2-macos-universal.tar.gz")
20-
set(macos10_13_binary_sha256 "0100663380a3bd977b001183cd487412db7aad9de6859927bde97e1e6e44e645")
21-
2219
set(macos10_10_binary_url "https://github.com/Kitware/CMake/releases/download/v3.20.2/cmake-3.20.2-macos10.10-universal.tar.gz")
2320
set(macos10_10_binary_sha256 "6d9c1c1aecb61d085b1a20503fa94b0c28abae617e20189df61eea4cf876fba0")
2421

scikit-ci.yml

+13-9
Original file line numberDiff line numberDiff line change
@@ -124,16 +124,20 @@ test:
124124
additional_platforms = []
125125
if "MACOSX_DEPLOYMENT_TARGET" in os.environ:
126126
target = tuple(int(p) for p in os.environ["MACOSX_DEPLOYMENT_TARGET"].split("."))
127-
if target == (10, 13):
128-
# let's add universal2 platform for this wheel.
129-
# given pip support for universal2 was added after arm64 introduction
130-
# let's also add arm64 platform.
127+
# let's add universal2 platform for this wheel.
128+
additional_platforms = ["macosx_{}_{}_universal2".format(*target)]
129+
130+
# given pip support for universal2 was added after arm64 introduction
131+
# let's also add arm64 platform.
132+
arm64_target = target
133+
if arm64_target < (11, 0):
134+
arm64_target = (11, 0)
135+
additional_platforms.append("macosx_{}_{}_arm64".format(*arm64_target))
136+
137+
if target < (11, 0):
131138
# They're were also issues with pip not picking up some universal2 wheels, tag twice
132-
additional_platforms = [
133-
"macosx_10_13_universal2",
134-
"macosx_11_0_universal2",
135-
"macosx_11_0_arm64",
136-
]
139+
additional_platforms.append("macosx_11_0_universal2")
140+
137141
for wheel in wheels:
138142
convert_to_generic_platform_wheel(wheel, remove_original=True, additional_platforms=additional_platforms)
139143

scripts/update_cmake_version.py

-4
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ def get_cmake_archive_urls_and_sha256s(version, verbose=False):
4646
"cmake-%s.tar.gz" % version: "unix_source",
4747
"cmake-%s.zip" % version: "win_source",
4848
"cmake-%s-linux-x86_64.tar.gz" % version: "linux64_binary",
49-
"cmake-%s-macos-universal.tar.gz" % version: "macos10_13_binary",
5049
"cmake-%s-macos10.10-universal.tar.gz" % version: "macos10_10_binary",
5150
"cmake-%s-windows-i386.zip" % version: "win32_binary",
5251
"cmake-%s-windows-x86_64.zip" % version: "win64_binary",
@@ -118,9 +117,6 @@ def generate_cmake_variables(urls_and_sha256s):
118117
set(linux64_binary_url "{linux64_binary_url}")
119118
set(linux64_binary_sha256 "{linux64_binary_sha256}")
120119
121-
set(macos10_13_binary_url "{macos10_13_binary_url}")
122-
set(macos10_13_binary_sha256 "{macos10_13_binary_sha256}")
123-
124120
set(macos10_10_binary_url "{macos10_10_binary_url}")
125121
set(macos10_10_binary_sha256 "{macos10_10_binary_sha256}")
126122

0 commit comments

Comments
 (0)