mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-02 07:31:26 +00:00
wbg: use lib.mesonEnable
This commit is contained in:
parent
6821ff041a
commit
939606a99c
@ -16,12 +16,6 @@
|
||||
, libjpeg
|
||||
}:
|
||||
|
||||
let
|
||||
# Courtesy of sternenseemann and FRidh, commit c9a7fdfcfb420be8e0179214d0d91a34f5974c54
|
||||
mesonFeatureFlag = feature: flag:
|
||||
"-D${feature}=${if flag then "enabled" else "disabled"}";
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "wbg";
|
||||
version = "1.0.2";
|
||||
@ -52,8 +46,8 @@ stdenv.mkDerivation rec {
|
||||
mesonBuildType = "release";
|
||||
|
||||
mesonFlags = [
|
||||
(mesonFeatureFlag "png" enablePNG)
|
||||
(mesonFeatureFlag "jpeg" enableJPEG)
|
||||
(lib.mesonEnable "png" enablePNG)
|
||||
(lib.mesonEnable "jpeg" enableJPEG)
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user