[PATCH] D19029: Always use --eh-frame-hdr on FreeBSD, even for -static
Ed Maste via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 12 13:42:15 PDT 2016
emaste updated this revision to Diff 53452.
emaste added a comment.
Test --eh-frame-hdr addition
http://reviews.llvm.org/D19029
Files:
lib/Driver/Tools.cpp
test/Driver/freebsd.c
Index: test/Driver/freebsd.c
===================================================================
--- test/Driver/freebsd.c
+++ test/Driver/freebsd.c
@@ -82,6 +82,7 @@
// RUN: %clang -no-canonical-prefixes -target x86_64-pc-freebsd8 -static %s \
// RUN: --sysroot=%S/Inputs/multiarch_freebsd64_tree -### 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-STATIC %s
+// CHECK-STATIC: ld{{.*}}" "--eh-frame-hdr" "-Bstatic"
// CHECK-STATIC: crt1.o
// CHECK-STATIC: crtbeginT.o
Index: lib/Driver/Tools.cpp
===================================================================
--- lib/Driver/Tools.cpp
+++ lib/Driver/Tools.cpp
@@ -8197,12 +8197,12 @@
if (IsPIE)
CmdArgs.push_back("-pie");
+ CmdArgs.push_back("--eh-frame-hdr");
if (Args.hasArg(options::OPT_static)) {
CmdArgs.push_back("-Bstatic");
} else {
if (Args.hasArg(options::OPT_rdynamic))
CmdArgs.push_back("-export-dynamic");
- CmdArgs.push_back("--eh-frame-hdr");
if (Args.hasArg(options::OPT_shared)) {
CmdArgs.push_back("-Bshareable");
} else {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19029.53452.patch
Type: text/x-patch
Size: 1062 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160412/af0e6db0/attachment.bin>
More information about the cfe-commits
mailing list