treewide: disable pie in more places
Some packages don’t work correctly with pie. Here I disable it for: - busybox - linux kernel - kexectools I also get rid of the Musl conditional for disabling pie in GCC and Binutils. Some day we might want to enable PIE without Musl and it will be useful to have the *just* work with our compiler and linkers.
This commit is contained in:
@@ -177,7 +177,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
inherit patches;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
outputs = [ "out" "lib" "man" "info" ];
|
||||
setOutputFlags = false;
|
||||
|
||||
@@ -185,7 +185,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
inherit patches;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
outputs = if langJava || langGo then ["out" "man" "info"]
|
||||
else [ "out" "lib" "man" "info" ];
|
||||
|
||||
@@ -178,7 +178,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
libc_dev = stdenv.cc.libc_dev;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
# This should kill all the stdinc frameworks that gcc and friends like to
|
||||
# insert into default search paths.
|
||||
|
||||
@@ -178,7 +178,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
libc_dev = stdenv.cc.libc_dev;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
# This should kill all the stdinc frameworks that gcc and friends like to
|
||||
# insert into default search paths.
|
||||
|
||||
@@ -149,7 +149,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
libc_dev = stdenv.cc.libc_dev;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
# This should kill all the stdinc frameworks that gcc and friends like to
|
||||
# insert into default search paths.
|
||||
|
||||
@@ -143,7 +143,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
libc_dev = stdenv.cc.libc_dev;
|
||||
|
||||
hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie";
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
# This should kill all the stdinc frameworks that gcc and friends like to
|
||||
# insert into default search paths.
|
||||
|
||||
@@ -137,7 +137,7 @@ stdenv.mkDerivation ({
|
||||
|
||||
libc_dev = stdenv.cc.libc_dev;
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
hardeningDisable = [ "format" "pie" ];
|
||||
|
||||
postPatch =
|
||||
if targetPlatform != hostPlatform || stdenv.cc.libc != null then
|
||||
|
||||
Reference in New Issue
Block a user