diff options
author | Ben Siraphob <bensiraphob@gmail.com> | 2021-01-15 20:21:58 +0700 |
---|---|---|
committer | Ben Siraphob <bensiraphob@gmail.com> | 2021-01-16 17:58:11 +0700 |
commit | badf51221db8fae81bf9948c39eaf8342dfd5597 (patch) | |
tree | 34eeb35ca97f0b081da465e9ddd6c120a9d2b7df /pkgs/applications/graphics/sane | |
parent | a9bb54359eeedf2594fdf191de5b673fd1dd102d (diff) | |
download | nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar.gz nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar.bz2 nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar.lz nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar.xz nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.tar.zst nixpkgs-badf51221db8fae81bf9948c39eaf8342dfd5597.zip |
treewide: stdenv.lib -> lib
Diffstat (limited to 'pkgs/applications/graphics/sane')
7 files changed, 27 insertions, 27 deletions
diff --git a/pkgs/applications/graphics/sane/backends/brscan4/default.nix b/pkgs/applications/graphics/sane/backends/brscan4/default.nix index 4ad5c24ddd6..0e768afdde1 100644 --- a/pkgs/applications/graphics/sane/backends/brscan4/default.nix +++ b/pkgs/applications/graphics/sane/backends/brscan4/default.nix @@ -1,7 +1,7 @@ -{ stdenv, fetchurl, callPackage, patchelf, makeWrapper, coreutils, libusb-compat-0_1 }: +{ lib, stdenv, fetchurl, callPackage, patchelf, makeWrapper, coreutils, libusb-compat-0_1 }: let - myPatchElf = file: with stdenv.lib; '' + myPatchElf = file: with lib; '' patchelf --set-interpreter \ ${stdenv.glibc}/lib/ld-linux${optionalString stdenv.is64bit "-x86-64"}.so.2 \ ${file} @@ -44,7 +44,7 @@ in stdenv.mkDerivation rec { done ''; - installPhase = with stdenv.lib; '' + installPhase = with lib; '' PATH_TO_BRSCAN4="opt/brother/scanner/brscan4" mkdir -p $out/$PATH_TO_BRSCAN4 cp -rp $PATH_TO_BRSCAN4/* $out/$PATH_TO_BRSCAN4 @@ -87,8 +87,8 @@ in stdenv.mkDerivation rec { meta = { description = "Brother brscan4 sane backend driver"; homepage = "http://www.brother.com"; - platforms = stdenv.lib.platforms.linux; - license = stdenv.lib.licenses.unfree; - maintainers = with stdenv.lib.maintainers; [ jraygauthier ]; + platforms = lib.platforms.linux; + license = lib.licenses.unfree; + maintainers = with lib.maintainers; [ jraygauthier ]; }; } diff --git a/pkgs/applications/graphics/sane/backends/brscan4/udev_rules_type1.nix b/pkgs/applications/graphics/sane/backends/brscan4/udev_rules_type1.nix index 682e401c069..9ca0a702060 100644 --- a/pkgs/applications/graphics/sane/backends/brscan4/udev_rules_type1.nix +++ b/pkgs/applications/graphics/sane/backends/brscan4/udev_rules_type1.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, libsaneUDevRuleNumber ? "49"}: +{ lib, stdenv, fetchurl, libsaneUDevRuleNumber ? "49"}: stdenv.mkDerivation rec { name = "brother-udev-rule-type1-1.0.0-1"; @@ -48,8 +48,8 @@ stdenv.mkDerivation rec { meta = { description = "Brother type1 scanners udev rules"; homepage = "http://www.brother.com"; - platforms = stdenv.lib.platforms.linux; - license = stdenv.lib.licenses.unfree; - maintainers = with stdenv.lib.maintainers; [ jraygauthier ]; + platforms = lib.platforms.linux; + license = lib.licenses.unfree; + maintainers = with lib.maintainers; [ jraygauthier ]; }; } diff --git a/pkgs/applications/graphics/sane/backends/dsseries/default.nix b/pkgs/applications/graphics/sane/backends/dsseries/default.nix index 37ac0298706..8a01f70c6b0 100644 --- a/pkgs/applications/graphics/sane/backends/dsseries/default.nix +++ b/pkgs/applications/graphics/sane/backends/dsseries/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, rpmextract }: +{ lib, stdenv, fetchurl, rpmextract }: stdenv.mkDerivation rec { pname = "libsane-dsseries"; @@ -46,8 +46,8 @@ stdenv.mkDerivation rec { meta = { description = "Brother DSSeries SANE backend driver"; homepage = "http://www.brother.com"; - platforms = stdenv.lib.platforms.linux; - license = stdenv.lib.licenses.unfree; - maintainers = with stdenv.lib.maintainers; [ callahad ]; + platforms = lib.platforms.linux; + license = lib.licenses.unfree; + maintainers = with lib.maintainers; [ callahad ]; }; } diff --git a/pkgs/applications/graphics/sane/backends/generic.nix b/pkgs/applications/graphics/sane/backends/generic.nix index cef48daca11..31ec8e8ddc7 100644 --- a/pkgs/applications/graphics/sane/backends/generic.nix +++ b/pkgs/applications/graphics/sane/backends/generic.nix @@ -39,19 +39,19 @@ stdenv.mkDerivation { enableParallelBuilding = true; configureFlags = [] - ++ stdenv.lib.optional (avahi != null) "--enable-avahi" - ++ stdenv.lib.optional (libusb1 != null) "--with-usb" + ++ lib.optional (avahi != null) "--enable-avahi" + ++ lib.optional (libusb1 != null) "--with-usb" ; postInstall = let compatFirmware = extraFirmware - ++ stdenv.lib.optional (gt68xxFirmware != null) { + ++ lib.optional (gt68xxFirmware != null) { src = gt68xxFirmware.fw; inherit (gt68xxFirmware) name; backend = "gt68xx"; } - ++ stdenv.lib.optional (snapscanFirmware != null) { + ++ lib.optional (snapscanFirmware != null) { src = snapscanFirmware; name = "your-firmwarefile.bin"; backend = "snapscan"; @@ -75,7 +75,7 @@ stdenv.mkDerivation { # net.conf conflicts with the file generated by the nixos module rm -f $out/etc/sane.d/net.conf - '' + stdenv.lib.concatStrings (builtins.map installFirmware compatFirmware); + '' + lib.concatStrings (builtins.map installFirmware compatFirmware); meta = with lib; { description = "SANE (Scanner Access Now Easy) backends"; diff --git a/pkgs/applications/graphics/sane/config.nix b/pkgs/applications/graphics/sane/config.nix index 2ef1e26f5ac..304df652f15 100644 --- a/pkgs/applications/graphics/sane/config.nix +++ b/pkgs/applications/graphics/sane/config.nix @@ -1,8 +1,8 @@ -{ stdenv }: +{ lib, stdenv }: { paths }: -with stdenv.lib; +with lib; let installSanePath = path: '' if [ -e "${path}/lib/sane" ]; then find "${path}/lib/sane" -maxdepth 1 -not -type d | while read backend; do diff --git a/pkgs/applications/graphics/sane/frontends.nix b/pkgs/applications/graphics/sane/frontends.nix index 86a1f201f82..8f5a10268e4 100644 --- a/pkgs/applications/graphics/sane/frontends.nix +++ b/pkgs/applications/graphics/sane/frontends.nix @@ -14,7 +14,7 @@ stdenv.mkDerivation rec { ''; buildInputs = [ sane-backends libX11 gtk2 ] - ++ stdenv.lib.optional (libusb-compat-0_1 != null) libusb-compat-0_1; + ++ lib.optional (libusb-compat-0_1 != null) libusb-compat-0_1; nativeBuildInputs = [ pkgconfig ]; enableParallelBuilding = true; diff --git a/pkgs/applications/graphics/sane/xsane.nix b/pkgs/applications/graphics/sane/xsane.nix index 04d19dee8a8..b9e45a76751 100644 --- a/pkgs/applications/graphics/sane/xsane.nix +++ b/pkgs/applications/graphics/sane/xsane.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, sane-backends, sane-frontends, libX11, gtk2, pkgconfig, libpng +{ lib, stdenv, fetchurl, sane-backends, sane-frontends, libX11, gtk2, pkgconfig, libpng , libusb-compat-0_1 ? null , gimpSupport ? false, gimp ? null }: @@ -21,13 +21,13 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ pkgconfig ]; buildInputs = [libpng sane-backends sane-frontends libX11 gtk2 ] ++ (if libusb-compat-0_1 != null then [libusb-compat-0_1] else []) - ++ stdenv.lib.optional gimpSupport gimp; + ++ lib.optional gimpSupport gimp; meta = { homepage = "http://www.sane-project.org/"; description = "Graphical scanning frontend for sane"; - license = stdenv.lib.licenses.gpl2Plus; - maintainers = with stdenv.lib.maintainers; [peti]; - platforms = with stdenv.lib.platforms; linux; + license = lib.licenses.gpl2Plus; + maintainers = with lib.maintainers; [peti]; + platforms = with lib.platforms; linux; }; } |