summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Coval <philippe.coval@open.eurogiciel.org>2014-12-08 16:00:20 +0100
committerPhilippe Coval <philippe.coval@open.eurogiciel.org>2014-12-08 16:05:00 +0100
commite85af05c326509a171ea7551b6508a851ebc8bc8 (patch)
tree74ea7cd0e33b89e2fec11651823ee28827605f0e
parent34297356fec103c001cacc7c40efef374fff211a (diff)
downloadrpm-e85af05c326509a171ea7551b6508a851ebc8bc8.tar.gz
rpm-e85af05c326509a171ea7551b6508a851ebc8bc8.tar.bz2
rpm-e85af05c326509a171ea7551b6508a851ebc8bc8.zip
optflags: set _FORTIFY_SOURCE for preproc
Without it will fail if optflags are not overridden and raise an error like : configure: CFLAGS error: CFLAGS may only be used to specify C compiler flags, not macro definitions. Use CPPFLAGS for: -D_FORTIFY_SOURCE=2 configure: error: Can not continue. Fix errors mentioned immediately above this line. error: Bad exit status from /var/tmp/rpm-tmp.AoOYbS (%build) More details at : https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/Preprocessor-Options.html#index-Wp-986 Change-Id: I49c8545a0526a1922905ef55de3a59edf9036068 Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
-rw-r--r--rpmrc.in22
1 files changed, 11 insertions, 11 deletions
diff --git a/rpmrc.in b/rpmrc.in
index 30481b24c..19626000a 100644
--- a/rpmrc.in
+++ b/rpmrc.in
@@ -12,16 +12,16 @@
# "fat" binary with both archs, for Darwin
optflags: fat -O2 -g -arch i386 -arch ppc
-optflags: i386 -O2 -g -m32 -march=i486 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: i486 -O2 -g -m32 -march=i486 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: i586 -O2 -g -m32 -march=i586 -mtune=i686 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: i686 -O2 -g -m32 -march=i686 -mtune=i686 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: i386 -O2 -g -m32 -march=i486 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: i486 -O2 -g -m32 -march=i486 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: i586 -O2 -g -m32 -march=i586 -mtune=i686 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: i686 -O2 -g -m32 -march=i686 -mtune=i686 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
optflags: pentium3 -O2 -g -m32 -march=pentium3
optflags: pentium4 -O2 -g -m32 -march=pentium4
optflags: athlon -O2 -g -m32 -march=athlon
optflags: geode -Os -g -m32 -march=geode
-optflags: ia64 -O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: x86_64 -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: ia64 -O2 -g -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: x86_64 -O2 -g -m64 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
optflags: amd64 -O2 -g
optflags: ia32e -O2 -g
@@ -41,14 +41,14 @@ optflags: sparc64v -O2 -g -m64 -mtune=niagara
optflags: m68k -O2 -g -fomit-frame-pointer
-optflags: ppc -O2 -g -m32 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: ppc -O2 -g -m32 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
optflags: ppc8260 -O2 -g -m32
optflags: ppc8560 -O2 -g -m32
optflags: ppc32dy4 -O2 -g -m32
optflags: ppciseries -O2 -g -m32
optflags: ppcpseries -O2 -g -m32
-optflags: ppc64 -O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: ppc64p7 -O3 -mtune=power7 -mcpu=power7 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: ppc64 -O2 -g -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: ppc64p7 -O3 -mtune=power7 -mcpu=power7 -g -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
optflags: parisc -O2 -g -mpa-risc-1-0
optflags: hppa -O2 -g -mpa-risc-1-0
@@ -78,8 +78,8 @@ optflags: atariclone -O2 -g -fomit-frame-pointer
optflags: milan -O2 -g -fomit-frame-pointer
optflags: hades -O2 -g -fomit-frame-pointer
-optflags: s390 -O2 -g -m31 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
-optflags: s390x -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: s390 -O2 -g -m31 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
+optflags: s390x -O2 -g -m64 -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables
optflags: sh3 -O2 -g
optflags: sh4 -O2 -g -mieee