Gentoo Archives: gentoo-dev

From: Magnus Granberg <zorry@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] [PATCH] To enable ssp default in Gcc the toolchain.eclass need some changes.
Date: Thu, 09 Jan 2014 21:00:14
Message-Id: 7554031.Sacz2dxc8i@laptop1.gw.ume.nu
1 Hi
2
3 Some time ago we discussed that we should enable stack smashing
4 (-fstack-protector) by default. So we opened a bug to track this [1].
5 The affected Gcc version will be 4.8.2 and newer. Only amd64, x86, mips, ppc,
6 ppc64 and arm will be affected by this change.
7
8 You can turn off ssp by using the nossp USE flag or by adding
9 -fno-stack-protector to the CFLAGS and/or CXXFLAGS. We are using the same
10 patch as Debian/Ubuntu but with some Gentoo fixes.
11
12 The patch will move the sed for the HARD_CFLAGS, ALLCFLAGS and
13 ALLCXXFLAGS from do_gcc_PIE_patches() to make_gcc_hard(). We will
14 make_gcc_hard() the default for all Gcc versions 4.8 and newer, and turn
15 it on or off with hardened_gcc_works() that will make some sanity checks.
16
17 /Magnus

Attachments

File name MIME type
toolchin.eclass.patch text/x-patch

Replies