7575 strategy :
7676 fail-fast : false
7777 matrix :
78- os : [ubuntu-latest, macos-latest, ubuntu-22.04-arm]
78+ os :
79+ - ubuntu-latest
80+ - ubuntu-22.04-arm
81+ - macos-15-intel
82+ - macos-latest
7983 python :
8084 - " cp38"
8185 - " cp39"
@@ -85,17 +89,17 @@ jobs:
8589 - " cp313"
8690 - " cp314"
8791 - " cp314t"
88- cibw_arch : ["x86_64", "aarch64", "universal2"]
89- exclude :
92+ - " cp315"
93+ - " cp315t"
94+ include :
9095 - os : ubuntu-latest
91- cibw_arch : universal2
92- - os : ubuntu-latest
93- cibw_arch : aarch64
94- - os : macos-latest
95- cibw_arch : aarch64
96- - os : ubuntu-22.04-arm
9796 cibw_arch : x86_64
9897 - os : ubuntu-22.04-arm
98+ cibw_arch : aarch64
99+ # Use native OpenSSL when compiling x86_64 test dependencies.
100+ - os : macos-15-intel
101+ cibw_arch : x86_64
102+ - os : macos-latest
99103 cibw_arch : universal2
100104
101105 defaults :
@@ -104,6 +108,13 @@ jobs:
104108
105109 env :
106110 PIP_DISABLE_PIP_VERSION_CHECK : 1
111+ CIBW_BUILD_VERBOSITY : 1
112+ CIBW_BUILD : ${{ matrix.python }}-*
113+ CIBW_ARCHS : ${{ matrix.cibw_arch }}
114+ # Let tests inside Linux containers recognize GitHub CI.
115+ CIBW_ENVIRONMENT_PASS_LINUX : GITHUB_WORKFLOW
116+ # Exercise arm64 here; x86_64 wheels have their own test jobs.
117+ CIBW_TEST_SKIP : " *universal2:x86_64"
107118
108119 steps :
109120 - uses : actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
@@ -114,14 +125,23 @@ jobs:
114125 - name : Install macOS deps
115126 if : startsWith(matrix.os, 'macos')
116127 run : |
117- brew install gnu-sed libtool autoconf automake
128+ brew install gnu-sed libtool autoconf automake openssl@3
129+ echo "OPENSSL_DIR=$(brew --prefix openssl@3)" >> "$GITHUB_ENV"
118130
131+ # cibuildwheel 4 added Python 3.15 but removed Python 3.8.
119132 - uses : pypa/cibuildwheel@7c619efba910c04005a835b110b057fc28fd6e93 # v3.2.0
133+ if : matrix.python == 'cp38'
134+
135+ - uses : pypa/cibuildwheel@1828c10ab37f080699c7b81cea34097c684a7074 # v4.2.0
136+ if : matrix.python != 'cp38'
120137 env :
121- CIBW_BUILD_VERBOSITY : 1
122- CIBW_BUILD : ${{ matrix.python }}-*
123- CIBW_ARCHS : ${{ matrix.cibw_arch }}
124- CIBW_TEST_SKIP : " *universal2:arm64"
138+ CIBW_BEFORE_ALL_LINUX : >-
139+ ${{ matrix.python == 'cp315t' && 'bash {project}/.github/workflows/install-linux-test-deps.sh' || '' }}
140+ # Build universal2 wheels, but compile their test dependencies for arm64.
141+ CIBW_TEST_ENVIRONMENT_MACOS : >-
142+ ${{ matrix.cibw_arch == 'universal2'
143+ && 'ARCHFLAGS="-arch arm64" _PYTHON_HOST_PLATFORM="macosx-11.0-arm64"'
144+ || '' }}
125145
126146 - uses : actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
127147 with :
0 commit comments