From 58e0d95c3a80e29b657cfce1dbea182c13ae6451 Mon Sep 17 00:00:00 2001 From: Michael Hanley Date: Tue, 23 Aug 2022 11:48:41 -0400 Subject: [PATCH] smartmontools: fix missing sed w/o enableMail Fixes #185095. Added gnused to smartmontools regardless of `enableMail`. The previous fix only works when `enableMail = true`. Also fixing this while I'm at it: ``` warning: String 'configureFlags' is deprecated and will be removed in release 23.05. Please use a list of strings. ``` --- pkgs/tools/system/smartmontools/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/system/smartmontools/default.nix b/pkgs/tools/system/smartmontools/default.nix index 987ede77747f..10ec02369dc8 100644 --- a/pkgs/tools/system/smartmontools/default.nix +++ b/pkgs/tools/system/smartmontools/default.nix @@ -18,6 +18,7 @@ let sha256 = "sha256-0dtLev4JjeHsS259+qOgg19rz4yjkeX4D3ooUgS4RTI="; name = "smartmontools-drivedb.h"; }; + scriptPath = lib.makeBinPath ([ gnused ] ++ lib.optional enableMail [ inetutils mailutils ]); in stdenv.mkDerivation rec { @@ -37,7 +38,7 @@ stdenv.mkDerivation rec { cp -v ${driverdb} drivedb.h ''; - configureFlags = lib.optional enableMail "--with-scriptpath=${lib.makeBinPath [ gnused inetutils mailutils ]}"; + configureFlags = [ "--with-scriptpath=${scriptPath}" ]; nativeBuildInputs = [ autoreconfHook ]; buildInputs = lib.optionals stdenv.isDarwin [ IOKit ApplicationServices ];