]> git.ipfire.org Git - people/ms/ipfire-3.x.git/blobdiff - pakfire/patches/0014-Explicitely-add-hardening-CFLAGS.patch
pakfire: Import latest patches from upstream.
[people/ms/ipfire-3.x.git] / pakfire / patches / 0014-Explicitely-add-hardening-CFLAGS.patch
diff --git a/pakfire/patches/0014-Explicitely-add-hardening-CFLAGS.patch b/pakfire/patches/0014-Explicitely-add-hardening-CFLAGS.patch
new file mode 100644 (file)
index 0000000..3afaca9
--- /dev/null
@@ -0,0 +1,25 @@
+From 6216f7249be57583516131398d98eadc2ca1a08d Mon Sep 17 00:00:00 2001
+From: Michael Tremer <michael.tremer@ipfire.org>
+Date: Tue, 12 Feb 2013 20:36:30 +0100
+Subject: [PATCH 14/17] Explicitely add hardening CFLAGS.
+
+---
+ macros/cflags.macro | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/macros/cflags.macro b/macros/cflags.macro
+index 5dee6f8..a2c583c 100644
+--- a/macros/cflags.macro
++++ b/macros/cflags.macro
+@@ -1,6 +1,7 @@
+ # Export CFLAGS + CXXFLAGS
+-GLOBAL_CFLAGS   = -O2 -g -pipe -Wall -fexceptions --param=ssp-buffer-size=4
++GLOBAL_CFLAGS   = -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fPIC
++GLOBAL_CFLAGS  += -fstack-protector-all --param=ssp-buffer-size=4
+ CFLAGS_i686     = -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables
+ CFLAGS_x86_64   = -m64 -mtune=generic
+-- 
+1.8.1.2
+