@@ -207,7 +207,7 @@ if lit_config.params.get('disable_unittests', None) is not None:
207
207
# test_source_root: The root path where tests are located.
208
208
config .test_source_root = os .path .dirname (__file__ )
209
209
210
- # test_exec_root : The root path where tests should be run .
210
+ # swift_obj_root : The path to the swift build root .
211
211
swift_obj_root = getattr (config , 'swift_obj_root' , None )
212
212
213
213
# cmake. The path to the cmake executable we used to configure swift.
@@ -1799,12 +1799,6 @@ if sftp_server_path:
1799
1799
config .substitutions .append (('%sftp-server' ,
1800
1800
sftp_server_path or 'no-sftp-server' ))
1801
1801
1802
- subst_target_jit_run = ""
1803
- if 'swift_interpreter' in config .available_features :
1804
- subst_target_jit_run = (
1805
- "%s -interpret %s" %
1806
- (config .target_swift_frontend , sdk_overlay_link_path ))
1807
-
1808
1802
subst_target_repl_run_simple_swift = ""
1809
1803
if 'swift_repl' in config .available_features :
1810
1804
subst_target_repl_run_simple_swift = (
@@ -1891,6 +1885,17 @@ if not kIsWindows:
1891
1885
"SIMCTL_CHILD_DYLD_LIBRARY_PATH='{0}' " # Simulator option
1892
1886
.format (all_stdlib_path , libdispatch_path )) + config .target_run
1893
1887
1888
+ subst_target_jit_prefix = ""
1889
+ if platform .system () == 'Darwin' and config .target_run :
1890
+ subst_target_jit_prefix = config .target_run
1891
+
1892
+ subst_target_jit_run = ""
1893
+ if 'swift_interpreter' in config .available_features :
1894
+ subst_target_jit_run = (
1895
+ "%s %s -interpret %s" %
1896
+ (subst_target_jit_prefix ,
1897
+ config .target_swift_frontend , sdk_overlay_link_path ))
1898
+
1894
1899
if not getattr (config , 'target_run_simple_swift' , None ):
1895
1900
config .target_run_simple_swift_parameterized = SubstituteCaptures (
1896
1901
r"%%empty-directory(%%t) && "
@@ -2080,10 +2085,14 @@ config.substitutions.append(('%target-swift-reflection-test', config.target_swif
2080
2085
2081
2086
config .substitutions .append (('%target-swift-reflection-dump' , '{} {} {}' .format (config .swift_reflection_dump , '-arch' , run_cpu )))
2082
2087
config .substitutions .append (('%target-swiftc_driver' , config .target_swiftc_driver ))
2088
+
2083
2089
config .substitutions .append (('%target-swift-remoteast-test-with-sdk' ,
2084
- '%s -sdk %r' %
2085
- (config .swift_remoteast_test , config .variant_sdk )))
2086
- config .substitutions .append (('%target-swift-remoteast-test' , config .swift_remoteast_test ))
2090
+ '%s %s -sdk %r' %
2091
+ (subst_target_jit_prefix ,
2092
+ config .swift_remoteast_test , config .variant_sdk )))
2093
+ config .substitutions .append (('%target-swift-remoteast-test' ,
2094
+ '%s %s' % (subst_target_jit_prefix ,
2095
+ config .swift_remoteast_test )))
2087
2096
2088
2097
if hasattr (config , 'target_swift_autolink_extract' ):
2089
2098
config .available_features .add ('autolink-extract' )
0 commit comments