Skip to content

Commit 8af59ab

Browse files
author
Mike Ferris
committed
Merge pull request #53 from swiftix/WIP-linker-command-fix
Use swiftc for linking.
2 parents eb0d41a + 0189401 commit 8af59ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

build_script.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ def main():
100100
run("{0} -c {1} -emit-object {2} -module-name XCTest -parse-as-library -emit-module "
101101
"-emit-module-path {3}/XCTest.swiftmodule -o {3}/XCTest.o -force-single-frontend-invocation "
102102
"-module-link-name XCTest".format(swiftc, style_options, " ".join(sourcePaths), build_dir))
103-
run("clang {1}/lib/swift/linux/{2}/swift_begin.o {0}/XCTest.o {1}/lib/swift/linux/{2}/swift_end.o -shared -o {0}/libXCTest.so -Wl,--no-undefined -Wl,-soname,libXCTest.so -L{1}/lib/swift/linux/ -lswiftGlibc -lswiftCore -lm".format(build_dir, swift_build_dir, args.arch))
103+
run("{0} -emit-library {1}/XCTest.o -o {1}/libXCTest.so -lswiftGlibc -lswiftCore -lm".format(swiftc, build_dir))
104104

105105
# If we were given an install directive, perform installation
106106
if args.module_path is not None and args.lib_path is not None:

0 commit comments

Comments
 (0)