From bc3d5934d7f276a21537b40159491257ee163d94 Mon Sep 17 00:00:00 2001 From: Felix Buehler Date: Tue, 14 Feb 2023 19:11:59 +0100 Subject: treewide: use lib.optionals --- pkgs/games/xjump/default.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'pkgs/games/xjump') diff --git a/pkgs/games/xjump/default.nix b/pkgs/games/xjump/default.nix index 3c13fc1a9b7..2c56e0bba4f 100644 --- a/pkgs/games/xjump/default.nix +++ b/pkgs/games/xjump/default.nix @@ -12,12 +12,8 @@ stdenv.mkDerivation { nativeBuildInputs = [ autoconf automake ]; buildInputs = [ libX11 libXt libXpm libXaw ]; preConfigure = "autoreconf --install"; - patches = if stdenv.buildPlatform.isDarwin then [ ./darwin.patch ] else []; - configureFlags = - if localStateDir != null then - ["--localstatedir=${localStateDir}"] - else - []; + patches = lib.optionals stdenv.buildPlatform.isDarwin [ ./darwin.patch ]; + configureFlags = lib.optionals (localStateDir != null) ["--localstatedir=${localStateDir}"]; meta = with lib; { description = "The falling tower game"; -- cgit 1.4.1