[PATCH] D61383: [Driver] Explicitly request platform rtlib in the Driver pic test

Petr Hosek via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 1 09:02:43 PDT 2019


phosek created this revision.
phosek added a reviewer: juliehockett.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

This test checks whether crtbegin.o and crtend.o appear on the link
line, but names of these files may be affected by the choice of the
rtlib, specifically when compiler-rt is used as the default rtlib
the names will be clang_rt.crtbegin.o and clang_rt.crtend.o instead
of crtbeginS.o and crtendS.o. To avoid the test failure, explicitly
request to use the platform rtlib.


Repository:
  rC Clang

https://reviews.llvm.org/D61383

Files:
  clang/test/Driver/pic.c


Index: clang/test/Driver/pic.c
===================================================================
--- clang/test/Driver/pic.c
+++ clang/test/Driver/pic.c
@@ -123,15 +123,15 @@
 // Make sure -pie is passed to along to ld and that the right *crt* files
 // are linked in.
 // RUN: %clang %s -target i386-unknown-freebsd -fPIE -pie -### \
-// RUN: --gcc-toolchain="" \
+// RUN: --gcc-toolchain="" -rtlib=platform \
 // RUN: --sysroot=%S/Inputs/basic_freebsd_tree 2>&1 \
 // RUN:   | FileCheck %s --check-prefix=CHECK-PIE-LD
 // RUN: %clang %s -target i386-linux-gnu -fPIE -pie -### \
-// RUN: --gcc-toolchain="" \
+// RUN: --gcc-toolchain="" -rtlib=platform \
 // RUN: --sysroot=%S/Inputs/basic_linux_tree 2>&1 \
 // RUN:   | FileCheck %s --check-prefix=CHECK-PIE-LD
 // RUN: %clang %s -target i386-linux-gnu -fPIC -pie -### \
-// RUN: --gcc-toolchain="" \
+// RUN: --gcc-toolchain="" -rtlib=platform \
 // RUN: --sysroot=%S/Inputs/basic_linux_tree 2>&1 \
 // RUN:   | FileCheck %s --check-prefix=CHECK-PIE-LD
 //


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61383.197564.patch
Type: text/x-patch
Size: 1012 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190501/7a47568c/attachment.bin>


More information about the cfe-commits mailing list