@@ -169,6 +169,11 @@ lldb_path = lit_config.params.get(
169169 "lldb" ,
170170 os .path .join (package_path , "usr" , "bin" , "lldb" ))
171171lit_config .note ("testing using 'lldb': {}" .format (lldb_path ))
172+
173+ repl_swift_dummy_path = lit_config .params .get (
174+ "repl_swift" ,
175+ os .path .join (package_path , "usr" , "bin" , "repl_swift" ))
176+ lit_config .note ("testing using 'repl_swift': {}" .format (repl_swift_dummy_path ))
172177
173178# Verify they exist.
174179if not os .path .exists (swift_path ):
@@ -182,12 +187,17 @@ if not os.path.exists(lldb_path):
182187 lldb_path = subprocess .check_output (["xcrun" , "--find" , "lldb" ]).strip ()
183188 else :
184189 lit_config .fatal ("lldb does not exist!" )
190+ if not os .path .exists (repl_swift_dummy_path ):
191+ if platform .system () == 'Linux' :
192+ lit_config .fatal ("repl_swift does not exist!" )
185193
186194# Define our supported substitutions.
187195config .substitutions .append ( ('%{package_path}' , package_path ) )
188196config .substitutions .append ( ('%{python}' , sys .executable ) )
189197config .substitutions .append ( ('%{not}' , os .path .join (srcroot , "not" )) )
190198config .substitutions .append ( ('%{lldb}' , lldb_path ) )
199+ if platform .system () == 'Linux' :
200+ config .substitutions .append ( ('%{repl_swift}' , repl_swift_dummy_path ) )
191201config .substitutions .append ( ('%{swift}' , swift_path ) )
192202config .substitutions .append ( ('%{swiftc}' , swiftc_path ) )
193203config .substitutions .append ( ('%{FileCheck}' , filecheck_path ) )
0 commit comments