@@ -143,6 +143,8 @@ jobs:
143143 rustup target add aarch64-apple-ios
144144 rustup target add x86_64-apple-ios
145145 rustup target add aarch64-apple-ios-sim
146+ rustup target add x86_64-apple-ios-macabi
147+ rustup target add aarch64-apple-ios-macabi
146148
147149 - name : Build macOS x86_64
148150 run : |
@@ -219,6 +221,36 @@ jobs:
219221 --features xz2-static \
220222 --crate-type=staticlib
221223
224+ - name : Build macOS Catalyst x86_64
225+ run : |
226+ export PATH="$PATH:$HOME/.local/bin"
227+ . "$HOME/.cargo/env"
228+ cd ${{ env.RUST_PROJECT_DIR }}
229+ MACOSX_DEPLOYMENT_TARGET="15" \
230+ IPHONEOS_DEPLOYMENT_TARGET="18" \
231+ TVOS_DEPLOYMENT_TARGET="18" \
232+ WATCHOS_DEPLOYMENT_TARGET="11" \
233+ cargo rustc \
234+ --release \
235+ --target x86_64-apple-ios-macabi \
236+ --features xz2-static \
237+ --crate-type=staticlib
238+
239+ - name : Build macOS Catalyst arm64
240+ run : |
241+ export PATH="$PATH:$HOME/.local/bin"
242+ . "$HOME/.cargo/env"
243+ cd ${{ env.RUST_PROJECT_DIR }}
244+ MACOSX_DEPLOYMENT_TARGET="15" \
245+ IPHONEOS_DEPLOYMENT_TARGET="18" \
246+ TVOS_DEPLOYMENT_TARGET="18" \
247+ WATCHOS_DEPLOYMENT_TARGET="11" \
248+ cargo rustc \
249+ --release \
250+ --target aarch64-apple-ios-macabi \
251+ --features xz2-static \
252+ --crate-type=staticlib
253+
222254 - name : Create fat library
223255 run : |
224256 X86_64_LIB="dependencies/sdk-core/target/x86_64-apple-darwin/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}"
@@ -258,17 +290,26 @@ jobs:
258290 -output "libtemporal_ios_sim.a"
259291 echo "✅ iOS simulator library: libtemporal_ios_sim.a"
260292
293+ # macOS Catalyst
294+ lipo -create \
295+ "dependencies/sdk-core/target/x86_64-apple-ios-macabi/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}" \
296+ "dependencies/sdk-core/target/aarch64-apple-ios-macabi/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}" \
297+ -output "libtemporal_catalyst.a"
298+ echo "✅ macOS Catalyst library: libtemporal_catalyst.a"
299+
261300 - name : Create XCFramework
262301 run : |
263302 # Create temporary directories for each platform
264303 mkdir -p temp_macos/Headers
265304 mkdir -p temp_ios/Headers
266305 mkdir -p temp_ios_sim/Headers
306+ mkdir -p temp_catalyst/Headers
267307
268308 # Copy libraries and headers to each platform directory
269309 cp "libtemporal_fat.a" "temp_macos/libTemporal.a"
270310 cp "libtemporal_ios.a" "temp_ios/libTemporal.a"
271311 cp "libtemporal_ios_sim.a" "temp_ios_sim/libTemporal.a"
312+ cp "libtemporal_catalyst.a" "temp_catalyst/libTemporal.a"
272313
273314 # Copy headers to all platform directories
274315 for dir in temp_*/Headers; do
@@ -287,6 +328,7 @@ jobs:
287328 -library "temp_macos/libTemporal.a" -headers "temp_macos/Headers" \
288329 -library "temp_ios/libTemporal.a" -headers "temp_ios/Headers" \
289330 -library "temp_ios_sim/libTemporal.a" -headers "temp_ios_sim/Headers" \
331+ -library "temp_catalyst/libTemporal.a" -headers "temp_catalyst/Headers" \
290332 -output "${{ env.XCFRAMEWORK_NAME }}"
291333
292334 # Clean up temporary files
@@ -305,6 +347,8 @@ jobs:
305347 dependencies/sdk-core/target/aarch64-apple-ios/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}
306348 dependencies/sdk-core/target/x86_64-apple-ios/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}
307349 dependencies/sdk-core/target/aarch64-apple-ios-sim/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}
350+ dependencies/sdk-core/target/x86_64-apple-ios-macabi/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}
351+ dependencies/sdk-core/target/aarch64-apple-ios-macabi/release/${{ env.TEMPORAL_BUILT_LIB_NAME }}
308352 ${{ env.XCFRAMEWORK_NAME }}
309353 retention-days : 1
310354
0 commit comments