anbox: drop (#370821)
[NixPkgs.git] / pkgs / misc / drivers / utsushi / networkscan.nix
blob7f339c15e404dc33cf673db9c8c5b1daa7325dff
2   lib,
3   stdenv,
4   fetchurl,
5   rpmextract,
6 }:
8 stdenv.mkDerivation rec {
9   pname = "imagescan-plugin-networkscan";
10   imagescanVersion = "3.65.0";
11   version = "1.1.4";
13   src = fetchurl {
14     urls = [
15       "https://buzo.eu/mirror/epson/imagescan-bundle-fedora-32-${imagescanVersion}.x64.rpm.tar.gz"
16       "https://web.archive.org/web/20221027001620if_/https://download2.ebz.epson.net/imagescanv3/fedora/latest1/rpm/x64/imagescan-bundle-fedora-32-${imagescanVersion}.x64.rpm.tar.gz"
17     ];
18     sha256 = "sha256-fxi63sV+YJOlv1aVTfCPIXOPfNAo+R7zNPvA11sFmMk=";
19   };
21   nativeBuildInputs = [ rpmextract ];
23   installPhase = ''
24     rpmextract plugins/imagescan-plugin-networkscan-${version}-*.x86_64.rpm
25     install -Dm755 usr/libexec/utsushi/networkscan $out/libexec/utsushi/networkscan
26     patchelf \
27       --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
28       --set-rpath ${lib.makeLibraryPath [ stdenv.cc.cc ]} \
29       $out/libexec/utsushi/networkscan
30   '';
32   meta = with lib; {
33     homepage = "https://support.epson.net/linux/en/imagescanv3.php";
34     description = "Network scan plugin for ImageScan v3";
35     sourceProvenance = with sourceTypes; [ binaryNativeCode ];
36     license = licenses.unfree;
37     maintainers = with maintainers; [ abbradar ];
38     platforms = [ "x86_64-linux" ];
39   };