Skip to content

Commit 6c92851

Browse files
committed
Put the static libXCTest.a into a static/ subdir when building
- This simplifies linking in static libraries over shared libraries when using -static-stdlib during build testing.
1 parent d902534 commit 6c92851

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

build_script.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,8 @@ def build(args):
207207
foundation_build_dir=foundation_build_dir))
208208

209209
# Build the static library
210-
run("ar rcs {build_dir}/libXCTest.a {build_dir}/XCTest.o".format(
210+
run("mkdir -p {build_dir}/static".format(build_dir=build_dir))
211+
run("ar rcs {build_dir}/static/libXCTest.a {build_dir}/XCTest.o".format(
211212
build_dir=build_dir))
212213

213214
if args.test:
@@ -320,7 +321,7 @@ def install(args):
320321
_mkdirp(static_library_install_path)
321322
xctest_a = "libXCTest.a"
322323
run("cp {} {}".format(
323-
os.path.join(build_dir, xctest_a),
324+
os.path.join(build_dir, "static/", xctest_a),
324325
os.path.join(static_library_install_path, xctest_a)))
325326

326327
@staticmethod

0 commit comments

Comments
 (0)