Skip to content

Commit 0713b7e

Browse files
committed
Remove support for installing the swift modules in a toolchain
We haven’t been installing the modules into the toolchain since late 2019, there’s no need to have an option for it.
1 parent 69eebd9 commit 0713b7e

File tree

1 file changed

+1
-22
lines changed

1 file changed

+1
-22
lines changed

build-script.py

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -607,7 +607,7 @@ def check_and_sync(file_path, install_path):
607607
fatal_error("install failed with exit status %d" % (result,))
608608

609609

610-
def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
610+
def install(build_dir, dylib_dir, stdlib_rpath):
611611
for dylib_name in get_installed_dylib_names():
612612

613613
dylib_path = os.path.join(build_dir, dylib_name)
@@ -621,15 +621,6 @@ def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
621621
file_path=dylib_path, install_path=os.path.join(dylib_dir, dylib_name)
622622
)
623623

624-
# Optionally install .swiftmodule
625-
if swiftmodule_base_name:
626-
module_path = os.path.join(build_dir, "SwiftSyntax.swiftmodule")
627-
doc_path = os.path.join(build_dir, "SwiftSyntax.swiftdoc")
628-
module_dest = swiftmodule_base_name + ".swiftmodule"
629-
doc_dest = swiftmodule_base_name + ".swiftdoc"
630-
check_and_sync(file_path=module_path, install_path=module_dest)
631-
check_and_sync(file_path=doc_path, install_path=doc_dest)
632-
633624

634625
# -----------------------------------------------------------------------------
635626
# Arugment Parsing
@@ -654,17 +645,6 @@ def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
654645
"""
655646

656647

657-
_SWIFTMODULE_BASE_NAME_HELP = """
658-
The name under which the Swift module should be installed. A .swiftdoc and
659-
.swiftmodule file extension will be added to this path and the corresponding
660-
files will be copied there.
661-
662-
Example /path/to/SwiftSyntax.swiftmodule/x86_64 copies files to
663-
/path/to/SwiftSyntax.swiftmodule/x86_64.swiftmodule and
664-
/path/to/SwiftSyntax.swiftmodule/x86_64.swiftdoc
665-
"""
666-
667-
668648
def parse_args():
669649
parser = argparse.ArgumentParser(
670650
formatter_class=argparse.RawDescriptionHelpFormatter, description=_DESCRIPTION
@@ -809,7 +789,6 @@ def main():
809789
install(
810790
build_dir=build_dir,
811791
dylib_dir=args.dylib_dir,
812-
swiftmodule_base_name=args.swiftmodule_base_name,
813792
stdlib_rpath=stdlib_rpath,
814793
)
815794
sys.exit(0)

0 commit comments

Comments
 (0)