Skip to content

Commit 5d0481a

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 4f6125c commit 5d0481a

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
@@ -605,7 +605,7 @@ def check_and_sync(file_path, install_path):
605605
fatal_error("install failed with exit status %d" % (result,))
606606

607607

608-
def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
608+
def install(build_dir, dylib_dir, stdlib_rpath):
609609
for dylib_name in get_installed_dylib_names():
610610

611611
dylib_path = os.path.join(build_dir, dylib_name)
@@ -619,15 +619,6 @@ def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
619619
file_path=dylib_path, install_path=os.path.join(dylib_dir, dylib_name)
620620
)
621621

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

632623
# -----------------------------------------------------------------------------
633624
# Arugment Parsing
@@ -652,17 +643,6 @@ def install(build_dir, dylib_dir, swiftmodule_base_name, stdlib_rpath):
652643
"""
653644

654645

655-
_SWIFTMODULE_BASE_NAME_HELP = """
656-
The name under which the Swift module should be installed. A .swiftdoc and
657-
.swiftmodule file extension will be added to this path and the corresponding
658-
files will be copied there.
659-
660-
Example /path/to/SwiftSyntax.swiftmodule/x86_64 copies files to
661-
/path/to/SwiftSyntax.swiftmodule/x86_64.swiftmodule and
662-
/path/to/SwiftSyntax.swiftmodule/x86_64.swiftdoc
663-
"""
664-
665-
666646
def parse_args():
667647
parser = argparse.ArgumentParser(
668648
formatter_class=argparse.RawDescriptionHelpFormatter, description=_DESCRIPTION
@@ -807,7 +787,6 @@ def main():
807787
install(
808788
build_dir=build_dir,
809789
dylib_dir=args.dylib_dir,
810-
swiftmodule_base_name=args.swiftmodule_base_name,
811790
stdlib_rpath=stdlib_rpath,
812791
)
813792
sys.exit(0)

0 commit comments

Comments
 (0)