From e740711cf6a18d9e2d2965e07b6f6913e6b62d8b Mon Sep 17 00:00:00 2001 From: Artturin Date: Wed, 8 Sep 2021 19:06:33 +0300 Subject: [PATCH] virtualbox: remove components/VBoxREM.so when hardened or headless is enabled arch does it as well https://github.com/archlinux/svntogit-community/blob/1b2aaf41138f4f00aca84700fe08bb213d909f79/trunk/PKGBUILD#L184 --- pkgs/applications/virtualization/virtualbox/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/applications/virtualization/virtualbox/default.nix b/pkgs/applications/virtualization/virtualbox/default.nix index c693fa8fdcf1..f54f9d84546b 100644 --- a/pkgs/applications/virtualization/virtualbox/default.nix +++ b/pkgs/applications/virtualization/virtualbox/default.nix @@ -200,6 +200,11 @@ in stdenv.mkDerivation { done ''} + # https://github.com/NixOS/nixpkgs/issues/137104 + ${optionalString (enableHardening || headless) '' + rm $libexec/components/VBoxREM.so + ''} + cp -rv out/linux.*/${buildType}/bin/src "$modsrc" '';