Skip to content

Commit 2d6f883

Browse files
authored
Merge pull request swiftlang#30212 from lorentey/fix-just-built-tests
[test] Make sure tests use just-built libraries if use_os_stdlib isn't set
2 parents 711fc48 + 55a32d5 commit 2d6f883

File tree

2 files changed

+17
-17
lines changed

2 files changed

+17
-17
lines changed

test/Interpreter/objc_class_properties_runtime.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// RUN: %clang -arch x86_64 -mmacosx-version-min=10.11 -isysroot %sdk -fobjc-arc %S/Inputs/ObjCClasses/ObjCClasses.m -c -o %t/ObjCClasses.o
44

55
// RUN: %swiftc_driver -target $(echo '%target-triple' | sed -E -e 's/macosx10.(9|10).*/macosx10.11/') -sdk %sdk -I %S/Inputs/ObjCClasses/ %t/ObjCClasses.o %s -o %t/a.out
6-
// RUN: %t/a.out
6+
// RUN: %target-run %t/a.out
77

88
// REQUIRES: OS=macosx
99
// REQUIRES: executable_test

test/lit.cfg

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1523,22 +1523,6 @@ rth_flags = ''
15231523
if swift_execution_tests_extra_flags:
15241524
rth_flags = swift_execution_tests_extra_flags + ' -wmo'
15251525

1526-
# FIXME: why can we not use %rth and have that be expanded out?
1527-
config.target_resilience_test = (
1528-
'%r %s --target-build-swift "%s" --target-run "%s" --t %%t --S %%S '
1529-
'--s %%s --lib-prefix "%s" --lib-suffix "%s" --target-codesign "%s" '
1530-
'--additional-compile-flags "%s" --triple "%s"'
1531-
% (sys.executable, config.rth, config.target_build_swift,
1532-
config.target_run, config.target_shared_library_prefix,
1533-
config.target_shared_library_suffix, config.target_codesign,
1534-
rth_flags, config.variant_triple))
1535-
1536-
# FIXME: Get symbol diffing working with binutils nm as well. The flags are slightly
1537-
# different.
1538-
if platform.system() != 'Darwin' or swift_test_mode == 'optimize_none_with_implicit_dynamic':
1539-
config.target_resilience_test = ('%s --no-symbol-diff' %
1540-
config.target_resilience_test)
1541-
15421526
platform_module_dir = make_path(test_resource_dir, config.target_sdk_name)
15431527
if run_vendor != 'apple':
15441528
platform_module_dir = make_path(platform_module_dir, run_cpu)
@@ -1639,6 +1623,22 @@ if not getattr(config, 'target_run_simple_swift', None):
16391623
'%s %%t/a.out'
16401624
% (config.target_build_swift, mcp_opt, config.target_codesign, config.target_run))
16411625

1626+
# FIXME: why can we not use %rth and have that be expanded out?
1627+
config.target_resilience_test = (
1628+
'%r %s --target-build-swift "%s" --target-run "%s" --t %%t --S %%S '
1629+
'--s %%s --lib-prefix "%s" --lib-suffix "%s" --target-codesign "%s" '
1630+
'--additional-compile-flags "%s" --triple "%s"'
1631+
% (sys.executable, config.rth, config.target_build_swift,
1632+
config.target_run, config.target_shared_library_prefix,
1633+
config.target_shared_library_suffix, config.target_codesign,
1634+
rth_flags, config.variant_triple))
1635+
1636+
# FIXME: Get symbol diffing working with binutils nm as well. The flags are slightly
1637+
# different.
1638+
if platform.system() != 'Darwin' or swift_test_mode == 'optimize_none_with_implicit_dynamic':
1639+
config.target_resilience_test = ('%s --no-symbol-diff' %
1640+
config.target_resilience_test)
1641+
16421642
#
16431643
# When changing substitutions, update docs/Testing.md.
16441644
#

0 commit comments

Comments
 (0)