From 9d1b0d95e84f4d16e5e03195e80c1fbf5d8ed183 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Wed, 29 Jun 2022 21:32:50 +0200 Subject: [PATCH] libass: replace mkFlag with lib.enableFeature --- pkgs/development/libraries/libass/default.nix | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/pkgs/development/libraries/libass/default.nix b/pkgs/development/libraries/libass/default.nix index 704dcd2c73d0..15e0396142f4 100644 --- a/pkgs/development/libraries/libass/default.nix +++ b/pkgs/development/libraries/libass/default.nix @@ -8,10 +8,6 @@ assert fontconfigSupport -> fontconfig != null; -let - mkFlag = optSet: flag: if optSet then "--enable-${flag}" else "--disable-${flag}"; -in - with lib; stdenv.mkDerivation rec { pname = "libass"; @@ -23,9 +19,9 @@ stdenv.mkDerivation rec { }; configureFlags = [ - (mkFlag fontconfigSupport "fontconfig") - (mkFlag rasterizerSupport "rasterizer") - (mkFlag largeTilesSupport "large-tiles") + (enableFeature fontconfigSupport "fontconfig") + (enableFeature rasterizerSupport "rasterizer") + (enableFeature largeTilesSupport "large-tiles") ]; nativeBuildInputs = [ pkg-config yasm ];