OSDN Git Service

x86/mips: enable _FORTIFY_SOURCE=2
authorNick Kralevich <nnk@google.com>
Mon, 29 Apr 2013 19:41:53 +0000 (12:41 -0700)
committerNick Kralevich <nnk@google.com>
Mon, 29 Apr 2013 19:41:53 +0000 (12:41 -0700)
Enable _FORTIFY_SOURCE=2 for x86 and MIPS.

Currently, this change is a no-op, as Android's libc doesn't
support _FORTIFY_SOURCE > 1, yet.

The ARM change was made in 316f720b91f879c4e3972d6d595535de0ac707b2

Change-Id: Iafe90beadf9b6a41ea294b7107cf4f18141acf3a

core/combo/TARGET_linux-mips.mk
core/combo/TARGET_linux-x86.mk

index 41928f8..85eaec9 100644 (file)
@@ -93,7 +93,7 @@ TARGET_GLOBAL_CFLAGS += \
                        -funwind-tables \
                        -Wa,--noexecstack \
                        -Werror=format-security \
-                       -D_FORTIFY_SOURCE=1 \
+                       -D_FORTIFY_SOURCE=2 \
                        $(arch_variant_cflags)
 
 android_config_h := $(call select-android-config-h,linux-mips)
index 04531b2..5c9a76b 100644 (file)
@@ -90,7 +90,7 @@ TARGET_GLOBAL_CFLAGS += \
                        -Ulinux \
                        -Wa,--noexecstack \
                        -Werror=format-security \
-                       -D_FORTIFY_SOURCE=1 \
+                       -D_FORTIFY_SOURCE=2 \
                        -Wstrict-aliasing=2 \
                        -fPIC -fPIE \
                        -ffunction-sections \