From 77fcfe70bef55b4e6f932b809ceb5653c375b2a4 Mon Sep 17 00:00:00 2001 From: NAKAMURA Takumi Date: Mon, 1 Jul 2013 09:51:55 +0000 Subject: [PATCH] clang/test/lit.cfg: Improve is_filesystem_case_insensitive() to work properly on cygwin. Cygwin does not accept the form /CYGDRIVE/X/PATH/TO/FILE against /cygdrive/X/PATH/TO/FILE. "cygdrive" must be lower-cased. llvm-svn: 185323 --- clang/test/lit.cfg | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/clang/test/lit.cfg b/clang/test/lit.cfg index 80243193c1e1..bf8528b3f68a 100644 --- a/clang/test/lit.cfg +++ b/clang/test/lit.cfg @@ -246,7 +246,11 @@ if platform.system() not in ['Windows']: # Case-insensitive file system def is_filesystem_case_insensitive(): handle, path = tempfile.mkstemp(prefix='case-test', dir=config.test_exec_root) - isInsensitive = os.path.exists(path.upper()) + isInsensitive = os.path.exists( + os.path.join( + os.path.dirname(path), + os.path.basename(path).upper() + )) os.close(handle) os.remove(path) return isInsensitive -- 2.34.1