diff options
author | Yochai <yochai@titat.info> | 2015-10-23 19:51:05 +0300 |
---|---|---|
committer | Yochai <yochai@titat.info> | 2015-10-23 19:51:05 +0300 |
commit | 837cdb03d346b55a1364bf26d94ddc7266016621 (patch) | |
tree | 363849121a13762295c290364cc717dba10d0e71 /pkgs | |
parent | 10c07911428563236b5248cbef4948baac610a42 (diff) | |
download | nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar.gz nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar.bz2 nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar.lz nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar.xz nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.tar.zst nixlib-837cdb03d346b55a1364bf26d94ddc7266016621.zip |
mfcj470dw: init at 3.0.0-1
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/misc/cups/drivers/mfcj470dw/default.nix | 50 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 2 |
2 files changed, 52 insertions, 0 deletions
diff --git a/pkgs/misc/cups/drivers/mfcj470dw/default.nix b/pkgs/misc/cups/drivers/mfcj470dw/default.nix new file mode 100644 index 000000000000..2bb406fa56b7 --- /dev/null +++ b/pkgs/misc/cups/drivers/mfcj470dw/default.nix @@ -0,0 +1,50 @@ +{stdenv, fetchurl, cups, dpkg, ghostscript, patchelf, bash, file}: + +stdenv.mkDerivation rec { + name = "mfcj470dw-cupswrapper-${version}"; + version = "3.0.0-1"; + + srcs = + [ (fetchurl { + url = "http://download.brother.com/welcome/dlf006843/mfcj470dwlpr-${version}.i386.deb"; + sha256 = "7202dd895d38d50bb767080f2995ed350eed99bc2b7871452c3c915c8eefc30a"; + }) + (fetchurl { + url = "http://download.brother.com/welcome/dlf006845/mfcj470dwcupswrapper-${version}.i386.deb"; + sha256 = "92af9024e821159eccd78a8925fc77fb92b4f247f2d2c824ca303004077076a7"; + }) + ]; + + buildInputs = [ dpkg cups patchelf bash ]; + + unpackPhase = "true"; + + installPhase = '' + for s in $srcs; do dpkg-deb -x $s $out; done + + substituteInPlace $out/opt/brother/Printers/mfcj470dw/cupswrapper/cupswrappermfcj470dw \ + --replace /opt "$out/opt" \ + --replace /usr "$out/usr" \ + --replace /etc "$out/etc" + + substituteInPlace $out/opt/brother/Printers/mfcj470dw/lpd/filtermfcj470dw \ + --replace /opt "$out/opt" \ + --replace file "/run/current-system/sw/bin/file" + + sed -i '/GHOST_SCRIPT=/c\GHOST_SCRIPT=gs' $out/opt/brother/Printers/mfcj470dw/lpd/psconvertij2 + + patchelf --set-interpreter ${stdenv.glibc}/lib/ld-linux.so.2 $out/opt/brother/Printers/mfcj470dw/lpd/brmfcj470dwfilter + patchelf --set-interpreter ${stdenv.glibc}/lib/ld-linux.so.2 $out/opt/brother/Printers/mfcj470dw/cupswrapper/brcupsconfpt1 + + mkdir -p $out/lib/cups/filter/ + ln -s $out/opt/brother/Printers/mfcj470dw/lpd/filtermfcj470dw $out/lib/cups/filter/brother_lpdwrapper_mfcj470dw + ''; + + meta = { + homepage = http://www.brother.com/; + description = "Driver for brother mfcj470dw pritners to print over WiFi and USB."; + license = stdenv.lib.licenses.unfree; + platforms = stdenv.lib.platforms.linux; + downloadPage = http://support.brother.com/g/b/downloadlist.aspx?c=us&lang=en&prod=mfcj470dw_us_eu_as&os=128; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 3d3b6f157407..fd3b10c91fd1 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -14988,6 +14988,8 @@ let sails = callPackage ../misc/sails { }; canon-cups-ufr2 = callPackage ../misc/cups/drivers/canon { }; + + mfcj470dw = callPackage_i686 ../misc/cups/drivers/mfcj470dw { }; samsungUnifiedLinuxDriver = callPackage ../misc/cups/drivers/samsung { gcc = import ../development/compilers/gcc/4.4 { |