@@ -100,7 +100,7 @@ jobs:
100
100
- name : Upload Artifacts
101
101
102
102
with :
103
- name : ios -slice-${{ matrix.flavor }}-${{ matrix.slice }}
103
+ name : prebuild -slice-${{ matrix.flavor }}-${{ matrix.slice }}
104
104
path : |
105
105
packages/react-native/third-party/.build/Build/Products
106
106
- name : Save Cache
@@ -111,3 +111,57 @@ jobs:
111
111
enableCrossOsArchive : true
112
112
path : |
113
113
packages/react-native/third-party/.build/Build/Products
114
+
115
+ create-xcframework :
116
+ name : Prepare XCFramework
117
+ runs-on : macos-14
118
+ needs : [build-apple-slices]
119
+ strategy :
120
+ fail-fast : false
121
+ matrix :
122
+ flavor : [Debug, Release]
123
+ steps :
124
+ - name : Checkout
125
+ uses : actions/checkout@v4
126
+ - name : Setup node.js
127
+ uses : ./.github/actions/setup-node
128
+ - name : Setup xcode
129
+ uses : ./.github/actions/setup-xcode
130
+ with :
131
+ xcode-version : ' 16.1'
132
+ - name : Restore XCFramework
133
+ id : restore-xcframework
134
+ uses : actions/cache/restore@v4
135
+ with :
136
+ path : packages/react-native/third-party/ReactNativeDependencies${{ matrix.flavor }}.xcframework
137
+ key : v1-ios-dependencies-xcframework-${{ matrix.flavor }}-${{ hashfiles('scripts/releases/ios-prebuilds/configuration.js') }}
138
+ # If cache hit, we already have our binary. We don't need to do anything.
139
+ - name : Yarn Install
140
+ if : steps.restore-xcframework.outputs.cache-hit != 'true'
141
+ uses : ./.github/actions/yarn-install
142
+ - name : Download slices
143
+ if : steps.restore-xcframework.outputs.cache-hit != 'true'
144
+ uses : actions/download-artifact@v4
145
+ with :
146
+ pattern : prebuild-slice-${{ matrix.flavor }}-*
147
+ path : packages/react-native/third-party/.build/Build/Products
148
+ merge-multiple : true
149
+ - name : Create XCFramework
150
+ if : steps.restore-xcframework.outputs.cache-hit != 'true'
151
+ run : node scripts/releases/prepare-ios-prebuilds.js -c
152
+ - name : Rename XCFramework
153
+ if : steps.restore-xcframework.outputs.cache-hit != 'true'
154
+ run : mv packages/react-native/third-party/ReactNativeDependencies.xcframework packages/react-native/third-party/ReactNativeDependencies${{ matrix.flavor }}.xcframework
155
+ - name : Upload XCFramework Artifact
156
+ uses : actions/upload-artifact@v4
157
+ with :
158
+ name : ReactNativeDependencies${{ matrix.flavor }}.xcframework
159
+ path : |
160
+ packages/react-native/third-party/ReactNativeDependencies${{ matrix.flavor }}.xcframework
161
+ - name : Save XCFramework in Cache
162
+ if : ${{ github.ref == 'refs/heads/main' }} # To avoid that the cache explode
163
+ uses : actions/cache/save@v4
164
+ with :
165
+ path : |
166
+ packages/react-native/third-party/ReactNativeDependencies${{ matrix.flavor }}.xcframework
167
+ key : v1-ios-dependencies-xcframework-${{ matrix.flavor }}-${{ hashfiles('scripts/releases/ios-prebuilds/configuration.js') }}
0 commit comments