Skip to content

Commit 2a31c39

Browse files
authored
Merge pull request #28710 from aciidb0mb3r/swiftpm-new-boostrap
Migration to SwiftpM’s new boostrap script
2 parents 05081ee + 288edfd commit 2a31c39

File tree

1 file changed

+8
-13
lines changed
  • utils/swift_build_support/swift_build_support/products

1 file changed

+8
-13
lines changed

utils/swift_build_support/swift_build_support/products/swiftpm.py

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,33 +30,28 @@ def should_build(self, host_target):
3030

3131
def run_bootstrap_script(self, action, host_target, additional_params=[]):
3232
script_path = os.path.join(
33-
self.source_dir, 'Utilities', 'bootstrap')
33+
self.source_dir, 'Utilities', 'new-bootstrap')
3434
toolchain_path = self.install_toolchain_path()
3535
swiftc = os.path.join(toolchain_path, "usr", "bin", "swiftc")
36-
sbt = os.path.join(toolchain_path, "usr", "bin", "swift-build-tool")
37-
38-
llbuild_src = os.path.join(os.path.dirname(self.source_dir), "llbuild")
3936

4037
# FIXME: We require llbuild build directory in order to build. Is
4138
# there a better way to get this?
4239
build_root = os.path.dirname(self.build_dir)
4340
llbuild_build_dir = os.path.join(
4441
build_root, '%s-%s' % ("llbuild", host_target))
4542

46-
helper_cmd = [script_path]
47-
48-
if action != "build":
49-
helper_cmd.append(action)
43+
helper_cmd = [script_path, action]
5044

5145
if self.is_release():
5246
helper_cmd.append("--release")
5347

5448
helper_cmd += [
55-
"--swiftc", swiftc,
56-
"--sbt", sbt,
57-
"--build", self.build_dir,
58-
"--llbuild-source-dir", llbuild_src,
59-
"--llbuild-build-dir", llbuild_build_dir,
49+
"--swiftc-path", swiftc,
50+
"--clang-path", self.toolchain.cc,
51+
"--cmake-path", self.toolchain.cmake,
52+
"--ninja-path", self.toolchain.ninja,
53+
"--build-dir", self.build_dir,
54+
"--llbuild-build-dir", llbuild_build_dir
6055
]
6156
helper_cmd.extend(additional_params)
6257

0 commit comments

Comments
 (0)