File tree Expand file tree Collapse file tree 1 file changed +13
-4
lines changed Expand file tree Collapse file tree 1 file changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -27,10 +27,12 @@ let package = Package(
27
27
targets: [ " StableDiffusion " ] ) ,
28
28
] ,
29
29
dependencies: [
30
- . package ( url: " https://github.com/ml-explore/mlx-swift " , from: " 0.21.2 " ) ,
31
- . package ( url: " https://github.com/huggingface/swift-transformers " , from: " 0.1.13 " ) ,
32
- . package ( url: " https://github.com/1024jp/GzipSwift " , " 6.0.1 " ... " 6.0.1 " ) ,
33
- . package ( url: " https://github.com/apple/swift-async-algorithms " , from: " 1.0.0 " ) ,
30
+ . package ( url: " https://github.com/ml-explore/mlx-swift " , . upToNextMinor( from: " 0.21.2 " ) ) ,
31
+ . package (
32
+ url: " https://github.com/huggingface/swift-transformers " , . upToNextMinor( from: " 0.1.13 " )
33
+ ) ,
34
+ . package (
35
+ url: " https://github.com/apple/swift-async-algorithms " , . upToNextMinor( from: " 1.0.0 " ) ) ,
34
36
] ,
35
37
targets: [
36
38
. target(
@@ -140,6 +142,13 @@ let package = Package(
140
142
]
141
143
)
142
144
145
+ // Add GzipSwift dependency only when building MLXMNIST
146
+ if package . targets. contains ( where: { $0. name == " MLXMNIST " } ) {
147
+ package . dependencies. append (
148
+ . package ( url: " https://github.com/1024jp/GzipSwift " , " 6.0.1 " ... " 6.0.1 " )
149
+ )
150
+ }
151
+
143
152
if Context . environment [ " MLX_SWIFT_BUILD_DOC " ] == " 1 "
144
153
|| Context . environment [ " SPI_GENERATE_DOCS " ] == " 1 "
145
154
{
You can’t perform that action at this time.
0 commit comments