Unverified Commit 34b2deb1 authored by boklm's avatar boklm
Browse files

binutils: make sure gold is used with the hardening wrapper on Linux

parent 17317b41
......@@ -15,6 +15,17 @@ patch -p2 < ../specify-timestamp.patch
./configure --prefix=$distdir [% c('var/configure_opt') %]
make -j4
make install
[% IF c("var/linux") %]
# Make sure gold is used with the hardening wrapper for full RELRO, see #13031.
cd $distdir/bin
rm ld
cp /usr/bin/hardened-ld ./
mv ld.gold ld.gold.real
ln -sf hardened-ld ld.gold
ln -sf ld.gold ld
[% END %]
cd /var/tmp/dist
[% c('tar', {
tar_src => [ project ],
......
......@@ -9,6 +9,16 @@ var:
configure_opt: '--disable-multilib --enable-gold --enable-deterministic-archives'
targets:
linux-x86_64:
var:
arch_deps:
- hardening-wrapper
linux-i686:
var:
arch_deps:
- hardening-wrapper
windows-i686:
var:
configure_opt: '--target=i686-w64-mingw32 --disable-multilib --enable-deterministic-archives'
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment