File tree Expand file tree Collapse file tree 1 file changed +15
-2
lines changed Expand file tree Collapse file tree 1 file changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -172,9 +172,17 @@ jobs:
172172
173173 - name : Stage native libraries in project
174174 run : |
175+ set -euo pipefail
176+
175177 mkdir -p src/MLXSharp/runtimes/osx-arm64/native
176178 cp artifacts/native/osx-arm64/libmlxsharp.dylib src/MLXSharp/runtimes/osx-arm64/native/
177- cp artifacts/native/osx-arm64/mlx.metallib src/MLXSharp/runtimes/osx-arm64/native/
179+
180+ if [ -f artifacts/native/osx-arm64/mlx.metallib ]; then
181+ cp artifacts/native/osx-arm64/mlx.metallib src/MLXSharp/runtimes/osx-arm64/native/
182+ else
183+ echo "::warning::mlx.metallib not found in macOS native artifact; continuing without Metal shaders"
184+ fi
185+
178186 mkdir -p src/MLXSharp/runtimes/linux-x64/native
179187 cp artifacts/native/linux-x64/libmlxsharp.so src/MLXSharp/runtimes/linux-x64/native/
180188
@@ -186,7 +194,12 @@ jobs:
186194 TEST_OUTPUT="src/MLXSharp.Tests/bin/Release/net9.0"
187195 mkdir -p "$TEST_OUTPUT/runtimes/osx-arm64/native"
188196 cp src/MLXSharp/runtimes/osx-arm64/native/libmlxsharp.dylib "$TEST_OUTPUT/runtimes/osx-arm64/native/"
189- cp src/MLXSharp/runtimes/osx-arm64/native/mlx.metallib "$TEST_OUTPUT/runtimes/osx-arm64/native/"
197+
198+ if [ -f src/MLXSharp/runtimes/osx-arm64/native/mlx.metallib ]; then
199+ cp src/MLXSharp/runtimes/osx-arm64/native/mlx.metallib "$TEST_OUTPUT/runtimes/osx-arm64/native/"
200+ else
201+ echo "::warning::mlx.metallib not staged; tests will continue without Metal shaders"
202+ fi
190203 ls -la "$TEST_OUTPUT/runtimes/osx-arm64/native/"
191204
192205 - name : Run tests
You can’t perform that action at this time.
0 commit comments