]> granicus.if.org Git - clang/commitdiff
Handle both Linux and Windows path separator for the resource dir
authorPetr Hosek <phosek@chromium.org>
Thu, 28 Jun 2018 03:54:08 +0000 (03:54 +0000)
committerPetr Hosek <phosek@chromium.org>
Thu, 28 Jun 2018 03:54:08 +0000 (03:54 +0000)
The resource dir path used for the multiarch runtimes support is
constructed in a platform independent way and therefore will use
native path separators on each platform. We need to make sure that
the per target runtime directory test handles both to not fail
when the test is being executed on Windows.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@335810 91177308-0d34-0410-b5e6-96231b3b80d8

test/Driver/linux-per-target-runtime-dir.c

index 17a4d6dc6ee4aa54b1c6490c33ac1f83f2e4fcc2..89310c11d981b361fb007b88a70e367ba84c83e2 100644 (file)
 // CHECK-PER-TARGET-RUNTIME: "-internal-isystem" "[[RESDIR]]/include/c++/v1"
 // CHECK-PER-TARGET-RUNTIME: "-internal-isystem" "[[SYSROOT]]/usr/local/include"
 // CHECK-PER-TARGET-RUNTIME: "--sysroot=[[SYSROOT]]"
-// CHECK-PER-TARGET-RUNTIME: "-L[[RESDIR]]/x86_64-linux-gnu/lib"
+// CHECK-PER-TARGET-RUNTIME: "-L[[RESDIR]]{{/|\\\\}}x86_64-linux-gnu{{/|\\\\}}lib"
 
 // RUN: %clang -rtlib=compiler-rt -print-libgcc-file-name 2>&1 \
 // RUN:     --target=x86_64-linux-gnu \
 // RUN:     -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
 // RUN:   | FileCheck --check-prefix=CHECK-CLANGRT-X8664 %s
-// CHECK-CLANGRT-X8664: x86_64-linux-gnu/lib/libclang_rt.builtins.a
+// CHECK-CLANGRT-X8664: x86_64-linux-gnu{{/|\\\\}}lib{{/|\\\\}}libclang_rt.builtins.a