Add test for link flags added by -fcatch-undefined-behavior.

llvm-svn: 167306
This commit is contained in:
Richard Smith 2012-11-02 20:34:30 +00:00
parent 437abed3ae
commit ea6ae57485
1 changed files with 10 additions and 0 deletions

View File

@ -0,0 +1,10 @@
// Test UndefinedBehaviorSanitizer ld flags.
// RUN: %clang -fcatch-undefined-behavior %s -### -o %t.o 2>&1 \
// RUN: -target i386-unknown-linux \
// RUN: --sysroot=%S/Inputs/basic_linux_tree \
// RUN: | FileCheck --check-prefix=CHECK-LINUX %s
// CHECK-LINUX: "{{.*}}ld{{(.exe)?}}"
// CHECK-LINUX-NOT: "-lc"
// CHECK-LINUX: libclang_rt.ubsan-i386.a"
// CHECK-LINUX: "-lpthread"