| Index: test/lit.cfg
|
| diff --git a/test/lit.cfg b/test/lit.cfg
|
| index 4567f179f8167f0229e5a38ba49bf6f8a7b6a280..1ce1221899c8b62a6e25418872a5df7d8af4a9e3 100644
|
| --- a/test/lit.cfg
|
| +++ b/test/lit.cfg
|
| @@ -14,6 +14,16 @@ import lit.util
|
| # name: The name of this test suite.
|
| config.name = 'Clang'
|
|
|
| +# @LOCALMOD-START
|
| +# Msys tools like make and bash output paths like /c/dir/path. We need Windows
|
| +# drive letters. Makefile.rules has $(ECHOPATH) to try to get Windows paths but
|
| +# it doesn't work with autoconf substitutions like @FOO@=$(path)
|
| +def FixMsysPath(path):
|
| + if sys.platform == 'win32' and path and path.startswith('/'):
|
| + return path[1] + ':' + path[2:]
|
| + return path
|
| +# @LOCALMOD-END
|
| +
|
| # Tweak PATH for Win32
|
| if platform.system() == 'Windows':
|
| # Seek sane tools in directories and set to $PATH.
|
| @@ -55,7 +65,7 @@ config.excludes = ['Inputs', 'CMakeLists.txt', 'README.txt', 'LICENSE.txt']
|
| config.test_source_root = os.path.dirname(__file__)
|
|
|
| # test_exec_root: The root path where tests should be run.
|
| -clang_obj_root = getattr(config, 'clang_obj_root', None)
|
| +clang_obj_root = FixMsysPath(getattr(config, 'clang_obj_root', None))# @LOCALMOD
|
| if clang_obj_root is not None:
|
| config.test_exec_root = os.path.join(clang_obj_root, 'test')
|
|
|
| @@ -93,10 +103,10 @@ for name in possibly_dangerous_env_vars:
|
|
|
| # Tweak the PATH to include the tools dir and the scripts dir.
|
| if clang_obj_root is not None:
|
| - clang_tools_dir = getattr(config, 'clang_tools_dir', None)
|
| + clang_tools_dir = FixMsysPath(getattr(config, 'clang_tools_dir', None)) # @LOCALMOD
|
| if not clang_tools_dir:
|
| lit_config.fatal('No Clang tools dir set!')
|
| - llvm_tools_dir = getattr(config, 'llvm_tools_dir', None)
|
| + llvm_tools_dir = FixMsysPath(getattr(config, 'llvm_tools_dir', None)) # @LOCALMOD
|
| if not llvm_tools_dir:
|
| lit_config.fatal('No LLVM tools dir set!')
|
| path = os.path.pathsep.join((
|
|
|