Skip to content

Commit a0ff5f1

Browse files
build: Build Swift SDK earlier than SwiftPM to allow SwiftPM to use it
Just built Swift SDK would be useful for SwiftPM to perform integration tests. All of those products do not depend on just built SwiftPM (WasmKit is built using host tools), so it is safe to build them earlier.
1 parent df70a97 commit a0ff5f1

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

utils/swift_build_support/swift_build_support/build_script_invocation.py

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -648,6 +648,21 @@ def compute_product_pipelines(self):
648648
# Begin the post build-script-impl build phase.
649649
builder.begin_pipeline()
650650

651+
builder.add_product(products.WASILibc,
652+
is_enabled=self.args.build_wasmstdlib)
653+
builder.add_product(products.WasmLLVMRuntimeLibs,
654+
is_enabled=self.args.build_wasmstdlib)
655+
builder.add_product(products.WasmThreadsLLVMRuntimeLibs,
656+
is_enabled=self.args.build_wasmstdlib)
657+
builder.add_product(products.WasmKit,
658+
is_enabled=self.args.build_wasmkit)
659+
builder.add_product(products.WasmStdlib,
660+
is_enabled=self.args.build_wasmstdlib)
661+
builder.add_product(products.WasmThreadsStdlib,
662+
is_enabled=self.args.build_wasmstdlib)
663+
builder.add_product(products.WasmSwiftSDK,
664+
is_enabled=self.args.build_wasmstdlib)
665+
651666
builder.add_product(products.SwiftPM,
652667
is_enabled=self.args.build_swiftpm)
653668
builder.add_product(products.SwiftSyntax,
@@ -674,20 +689,6 @@ def compute_product_pipelines(self):
674689
is_enabled=self.args.install_swiftdocc)
675690
builder.add_product(products.MinimalStdlib,
676691
is_enabled=self.args.build_minimalstdlib)
677-
builder.add_product(products.WASILibc,
678-
is_enabled=self.args.build_wasmstdlib)
679-
builder.add_product(products.WasmLLVMRuntimeLibs,
680-
is_enabled=self.args.build_wasmstdlib)
681-
builder.add_product(products.WasmThreadsLLVMRuntimeLibs,
682-
is_enabled=self.args.build_wasmstdlib)
683-
builder.add_product(products.WasmKit,
684-
is_enabled=self.args.build_wasmkit)
685-
builder.add_product(products.WasmStdlib,
686-
is_enabled=self.args.build_wasmstdlib)
687-
builder.add_product(products.WasmThreadsStdlib,
688-
is_enabled=self.args.build_wasmstdlib)
689-
builder.add_product(products.WasmSwiftSDK,
690-
is_enabled=self.args.build_wasmstdlib)
691692

692693
# Keep SwiftDriver at last.
693694
# swift-driver's integration with the build scripts is not fully

0 commit comments

Comments
 (0)