mfcl2720dwlpr: init at 3.2.0-1

Brother MFC-L2720DW lpr driver
This commit is contained in:
xeji 2018-02-18 19:37:19 +01:00
parent e612f70393
commit 380d759659
2 changed files with 47 additions and 0 deletions

View File

@ -0,0 +1,45 @@
{ pkgs, stdenv, fetchurl, dpkg, makeWrapper, coreutils, ghostscript, gnugrep, gnused, which, perl }:
stdenv.mkDerivation rec {
name = "mfcl2720dwlpr-${version}";
version = "3.2.0-1";
src = fetchurl {
url = "http://download.brother.com/welcome/dlf101801/${name}.i386.deb";
sha256 = "088217e9ad118ec1e7f3d3f8f60f3bd839fe2c7d7c1136b249e9ac648dc742af";
};
nativeBuildInputs = [ dpkg makeWrapper ];
phases = [ "installPhase" ];
installPhase = ''
dpkg-deb -x $src $out
dir=$out/opt/brother/Printers/MFCL2720DW
substituteInPlace $dir/lpd/filter_MFCL2720DW \
--replace /usr/bin/perl ${perl}/bin/perl \
--replace "BR_PRT_PATH =~" "BR_PRT_PATH = \"$dir\"; #" \
--replace "PRINTER =~" "PRINTER = \"MFCL2720DW\"; #"
wrapProgram $dir/lpd/filter_MFCL2720DW \
--prefix PATH : ${stdenv.lib.makeBinPath [
coreutils ghostscript gnugrep gnused which
]}
# need to use i686 glibc here, these are 32bit proprietary binaries
interpreter=${pkgs.pkgsi686Linux.glibc}/lib/ld-linux.so.2
patchelf --set-interpreter "$interpreter" $dir/inf/braddprinter
patchelf --set-interpreter "$interpreter" $dir/lpd/brprintconflsr3
patchelf --set-interpreter "$interpreter" $dir/lpd/rawtobr3
'';
meta = {
description = "Brother MFC-L2720DW lpr driver";
homepage = http://www.brother.com/;
license = stdenv.lib.licenses.unfree;
platforms = [ "x86_64-linux" "i686-linux" ];
maintainers = [ stdenv.lib.maintainers.xeji ];
};
}

View File

@ -20205,6 +20205,8 @@ with pkgs;
mfcl2700dncupswrapper = callPackage ../misc/cups/drivers/mfcl2700dncupswrapper { };
mfcl2700dnlpr = callPackage_i686 ../misc/cups/drivers/mfcl2700dnlpr { };
mfcl2720dwlpr = callPackage ../misc/cups/drivers/mfcl2720dwlpr { };
samsung-unified-linux-driver_1_00_37 = callPackage ../misc/cups/drivers/samsung { };
samsung-unified-linux-driver_4_01_17 = callPackage ../misc/cups/drivers/samsung/4.01.17.nix { };
samsung-unified-linux-driver = callPackage ../misc/cups/drivers/samsung/4.00.39 { };