Skip to content

Commit a5f17fe

Browse files
committed
Installation
1 parent 3324ef5 commit a5f17fe

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Utilities/bootstrap

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,8 @@ def install(args):
395395
# Install swiftpm content in all of the passed prefixes.
396396
for prefix in args.install_prefixes:
397397
install_swiftpm(prefix, args)
398+
config_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), "config.json")
399+
install_file(args, config_path, os.path.join(os.path.join(prefix, "share"), "pm"))
398400

399401
# Install libSwiftPM if an install directory was provided.
400402
if args.libswiftpm_install_dir:
@@ -461,9 +463,11 @@ def install_dylib(args, library_name, install_dir, module_names):
461463
# Helper function that installs a single built artifact to a particular directory. The source may be either a file or a directory.
462464
def install_binary(args, binary, destination, destination_is_directory=True, ignored_patterns=[]):
463465
src = os.path.join(args.bin_dir, binary)
466+
install_file(args, src, destination, destination_is_directory=destination_is_directory, ignored_patterns=ignored_patterns)
464467

468+
def install_file(args, src, destination, destination_is_directory=True, ignored_patterns=[]):
465469
if destination_is_directory:
466-
dest = os.path.join(destination, binary)
470+
dest = os.path.join(destination, os.path.basename(src))
467471
mkdir_p(os.path.dirname(dest))
468472
else:
469473
dest = destination

Utilities/config.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"version":1,"swiftSyntaxVersionForMacroTemplate":{"major":509,"minor":0,"patch":0}}

0 commit comments

Comments
 (0)