Conditionally add -fno-stack-protector to CFLAGS
PATCH 1/1 Conditionally add -fno-stack-protector to CFLAGS
When compile-testing on powerpc, I get errors like this:
/home/hskinnemoen/work/git/u-boot/net/nfs.c:422: undefined reference to `__stack_chk_fail_local'
This seems to be because -fstack-protector is on by default, so explicitly disable it on all architectures that support the option.
--- config.mk | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
config.mk +2 -0
@@ -164,6 +164,8 @@ else CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes endif +CFLAGS += $(call cc-option,-fno-stack-protector) + # avoid trigraph warnings while parsing pci.h (produced by NIOS gcc-2.9) # this option have to be placed behind -Wall -- that's why it is here ifeq ($(ARCH),nios)
Signature · 1 line
1.5.3.6
PATCH 1/1 Conditionally add -fno-stack-protector to CFLAGS
Quoted 6 lines · In message <[email protected]> you wrote:
When compile-testing on powerpc, I get errors like this:
/home/hskinnemoen/work/git/u-boot/net/nfs.c:422: undefined reference to `__stack_chk_fail_local'This seems to be because -fstack-protector is on by default, so explicitly disable it on all architectures that support the option.
Which toolchain is doing this?
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de "Anyone attempting to generate random numbers by deterministic means is, of course, living in a state of sin." - John Von Neumann
PATCH 1/1 Conditionally add -fno-stack-protector to CFLAGS
Quoted 9 lines · On Tue, 11 Dec 2007 17:16:47 +0100 Wolfgang Denk <[email protected]> wrote:
Quoted 6 lines · In message <[email protected]> you wrote:
When compile-testing on powerpc, I get errors like this:
/home/hskinnemoen/work/git/u-boot/net/nfs.c:422: undefined reference to `__stack_chk_fail_local'This seems to be because -fstack-protector is on by default, so explicitly disable it on all architectures that support the option.
Which toolchain is doing this?
gcc 4.2.1-5ubuntu4 compiled for x86_64 host and powerpc target.
Haavard
PATCH 1/1 Conditionally add -fno-stack-protector to CFLAGS
In reply to Wolfgang DenkQuoted 1 line · Wolfgang Denk
In message <[email protected]> you
Quoted 9 lines · wrote:
Quoted 7 lines
When compile-testing on powerpc, I get errors like this:
/home/hskinnemoen/work/git/u-boot/net/nfs.c:422: undefined reference to `__stack_chk_fail_local'This seems to be because -fstack-protector is on by default, so explicitly disable it on all architectures that support the option.
Which toolchain is doing this?
it isnt uncommon for distros to default to ssp turned on now that it's in mainline gcc. Gentoo has been doing it for years.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 827 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20071211/dfa74aa1/attachment.pgp