[PATCH] D56456: [Driver] Default to -fno-addrsig on Android.

Dan Albert via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 8 14:25:42 PST 2019


danalbert created this revision.
danalbert added reviewers: srhines, pirama.

The Android NDK still uses GNU binutils by default.


Repository:
  rC Clang

https://reviews.llvm.org/D56456

Files:
  lib/Driver/ToolChains/Clang.cpp
  test/Driver/addrsig.c


Index: test/Driver/addrsig.c
===================================================================
--- test/Driver/addrsig.c
+++ test/Driver/addrsig.c
@@ -8,6 +8,7 @@
 // RUN: %clang -### -target x86_64-unknown-linux -fno-addrsig -c %s 2>&1 | FileCheck -check-prefix=NO-ADDRSIG %s
 // RUN: %clang -### -target x86_64-apple-darwin -c %s 2>&1 | FileCheck -check-prefix=NO-ADDRSIG %s
 // RUN: %clang -### -target x86_64-scei-ps4 -c %s 2>&1 | FileCheck -check-prefix=NO-ADDRSIG %s
+// RUN: %clang -### -target x86_64-linux-android21 -c %s 2>&1 | FileCheck -check-prefix=NO-ADDRSIG %s
 
 // ADDRSIG: -faddrsig
 // NO-ADDRSIG-NOT: -faddrsig
Index: lib/Driver/ToolChains/Clang.cpp
===================================================================
--- lib/Driver/ToolChains/Clang.cpp
+++ lib/Driver/ToolChains/Clang.cpp
@@ -5292,6 +5292,7 @@
                       !TC.getTriple().isPS4() &&
                       !TC.getTriple().isOSNetBSD() &&
                       !Distro(D.getVFS()).IsGentoo() &&
+                      !TC.getTriple().isAndroid() &&
                        TC.useIntegratedAs()))
     CmdArgs.push_back("-faddrsig");
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56456.180738.patch
Type: text/x-patch
Size: 1136 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190108/a7d99bea/attachment.bin>


More information about the cfe-commits mailing list