blob: b1a0d6880b18bfb909d7879a55ff728724d8b94c [file] [log] [blame]
Chandler Carruthc4cc4032011-10-01 00:37:39 +00001// General tests that ld invocations on Linux targets sane.
2//
3// RUN: %clang -no-canonical-prefixes -ccc-host-triple i386-unknown-linux %s -### -o %t.o 2>&1 \
4// RUN: | FileCheck --check-prefix=CHECK-LD-32 %s
Chandler Carruthf3a852a2011-10-01 01:26:40 +00005// 32-bit machines may use 'lib' or 'lib32' dependending on how they setup multilib.
Chandler Carruth00ca8482011-10-01 02:08:56 +00006// CHECK-LD-32: "{{.*}}ld{{(.exe)?}}" {{.*}} "-L/lib/../lib{{(32)?}}" "-L/usr/lib/../lib{{(32)?}}"
Chandler Carruthc4cc4032011-10-01 00:37:39 +00007//
8// RUN: %clang -no-canonical-prefixes -ccc-host-triple x86_64-unknown-linux %s -### -o %t.o 2>&1 \
9// RUN: | FileCheck --check-prefix=CHECK-LD-64 %s
Chandler Carruthf3a852a2011-10-01 01:26:40 +000010// FIXME: Should we allow 'lib' instead of 'lib64' here?
Chandler Carruth00ca8482011-10-01 02:08:56 +000011// CHECK-LD-64: "{{.*}}ld{{(.exe)?}}" {{.*}} "-L/lib/../lib64" "-L/usr/lib/../lib64"