15 nix-shell -E 'with import <nixpkgs> { }; brscan4-etc-files'
21 nix-shell -E 'with import <nixpkgs> { }; brscan4-etc-files.override{netDevices=[{name="a"; model="MFC-7860DW"; nodename="BRW0080927AFBCE";} {name="b"; model="MFC-7860DW"; ip="192.168.1.2";}];}'
32 if (lib.hasAttr "nodename" nd && nd.nodename != null) then
33 ''nodename="${nd.nodename}"''
37 addAllNetDev = xs: lib.concatStringsSep "\n" (map addNetDev xs);
42 pname = "brscan4-etc-files";
44 src = "${brscan4}/opt/brother/scanner/brscan4";
46 nativeBuildInputs = [ brscan4 ];
51 TARGET_DIR="$out/etc/opt/brother/scanner/brscan4"
52 mkdir -p "$TARGET_DIR"
53 cp -rp "./models4" "$TARGET_DIR"
54 cp -rp "./Brsane4.ini" "$TARGET_DIR"
55 cp -rp "./brsanenetdevice4.cfg" "$TARGET_DIR"
57 export BRSANENETDEVICE4_CFG_FILENAME="$TARGET_DIR/brsanenetdevice4.cfg"
59 printf '${addAllNetDev netDevices}\n'
61 ${addAllNetDev netDevices}
69 description = "Brother brscan4 sane backend driver etc files";
70 homepage = "http://www.brother.com";
71 platforms = platforms.linux;
72 license = licenses.unfree;
73 maintainers = with maintainers; [ jraygauthier ];