13 [Setup instructions](http://support.brother.com/g/s/id/linux/en/instruction_prn1a.html).
16 ~ `lpd://BRW0080927AFBCE/binary_p1`
21 `/tmp/br_lpdfilter_ml1.log` when `$ENV{LPD_DEBUG} > 0` in `filter_BrGenML1`
22 which is activated automatically when `DEBUG > 0` in `brother_lpdwrapper_BrGenML1`
23 from the cups wrapper.
28 - filter_BrGenML1 ln 196 `my $GHOST_SCRIPT=`which gs`;`
30 `GHOST_SCRIPT` is empty resulting in an empty `/tmp/br_lpdfilter_ml1_gsout.dat` file.
31 See `/tmp/br_lpdfilter_ml1.log` for the executed command.
36 - The `setupPrintcap` has totally no use in our context.
41 patchelf --set-interpreter \
42 ${stdenv.cc.libc}/lib/ld-linux${lib.optionalString stdenv.hostPlatform.is64bit "-x86-64"}.so.2 \
46 stdenv.mkDerivation rec {
47 pname = "brgenml1lpr";
51 url = "https://download.brother.com/welcome/dlf101123/brgenml1lpr-${version}.i386.deb";
52 sha256 = "0zdvjnrjrz9sba0k525linxp55lr4cyivfhqbkq1c11br2nvy09f";
60 nativeBuildInputs = [ makeWrapper ];
72 INFDIR=opt/brother/Printers/BrGenML1/inf
73 LPDDIR=opt/brother/Printers/BrGenML1/lpd
75 # Setup max debug log by default.
76 substituteInPlace $LPDDIR/filter_BrGenML1 \
77 --replace "BR_PRT_PATH =~" "BR_PRT_PATH = \"$out/opt/brother/Printers/BrGenML1\"; #" \
78 --replace "PRINTER =~" "PRINTER = \"BrGenML1\"; #"
80 ${myPatchElf "$INFDIR/braddprinter"}
81 ${myPatchElf "$LPDDIR/brprintconflsr3"}
82 ${myPatchElf "$LPDDIR/rawtobr3"}
86 INFDIR=opt/brother/Printers/BrGenML1/inf
87 LPDDIR=opt/brother/Printers/BrGenML1/lpd
90 cp -rp $INFDIR/* $out/$INFDIR
92 cp -rp $LPDDIR/* $out/$LPDDIR
94 wrapProgram $out/$LPDDIR/filter_BrGenML1 \
95 --prefix PATH ":" "${ghostscript}/bin" \
96 --prefix PATH ":" "${which}/bin"
102 description = "Brother BrGenML1 LPR driver";
103 homepage = "http://www.brother.com";
104 sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
105 platforms = lib.platforms.linux;
106 license = lib.licenses.unfreeRedistributable;
107 maintainers = with lib.maintainers; [ jraygauthier ];