summaryrefslogtreecommitdiffstats
path: root/pkgs/build-support
diff options
context:
space:
mode:
authorJoachim Fasting <joachifm@fastmail.fm>2017-02-10 06:48:56 +0100
committerJoachim Fasting <joachifm@fastmail.fm>2017-02-10 06:52:02 +0100
commitfc54ece4709d39a9feaa61600d23a0490ce49bd1 (patch)
tree96b2d328b381fcc00f4eb489661d139ed7a674da /pkgs/build-support
parenta0ebb1497f46b9487c7148bb5528d21f81c82894 (diff)
Revert "grsecurity: overrideDerivation -> overrideAttrs"
This reverts commit 3d9017602b0f0dbe8e4c0706cda32e8f8b38311b. This didn't quite work as I had expected ... While it seemed okay at first, it fails to propagate all the attributes it used to (notably features). I'll revisit this later but reverting for now.
Diffstat (limited to 'pkgs/build-support')
-rw-r--r--pkgs/build-support/grsecurity/default.nix15
1 files changed, 6 insertions, 9 deletions
diff --git a/pkgs/build-support/grsecurity/default.nix b/pkgs/build-support/grsecurity/default.nix
index f1310446964d..ccd46e20654f 100644
--- a/pkgs/build-support/grsecurity/default.nix
+++ b/pkgs/build-support/grsecurity/default.nix
@@ -1,4 +1,6 @@
{ stdenv
+, lib
+, overrideDerivation
# required for gcc plugins
, gmp, libmpc, mpfr
@@ -17,22 +19,17 @@
assert (kernel.version == grsecPatch.kver);
-(kernel.override {
+overrideDerivation (kernel.override {
inherit modDirVersion;
- # TODO: unique is a work-around
- kernelPatches = stdenv.lib.unique ([ grsecPatch ] ++ kernelPatches ++ (kernel.kernelPatches or []));
+ kernelPatches = lib.unique ([ grsecPatch ] ++ kernelPatches ++ (kernel.kernelPatches or []));
extraConfig = ''
GRKERNSEC y
PAX y
${extraConfig}
'';
-
- # Enabling grsecurity/PaX deselects several other options implicitly,
- # causing the configfile checker to fail (when it finds that options
- # expected to be enabled are not).
ignoreConfigErrors = true;
-}).overrideAttrs (attrs: {
- nativeBuildInputs = (stdenv.lib.chooseDevOutputs [ gmp libmpc mpfr ]) ++ (attrs.nativeBuildInputs or []);
+}) (attrs: {
+ nativeBuildInputs = (lib.chooseDevOutputs [ gmp libmpc mpfr ]) ++ (attrs.nativeBuildInputs or []);
preConfigure = ''
echo ${localver} >localversion-grsec
${attrs.preConfigure or ""}