diff --git a/srcpkgs/iscan-plugin-gt-x820/INSTALL b/srcpkgs/iscan-plugin-gt-x820/INSTALL new file mode 100644 index 00000000000000..8750e24d592573 --- /dev/null +++ b/srcpkgs/iscan-plugin-gt-x820/INSTALL @@ -0,0 +1,5 @@ +if [ "$UPDATE" = "no" ] && [ "$ACTION" = "post" ]; then + usr/bin/iscan-registry --add interpreter usb 0x04b8 0x013a \ + /usr/lib/iscan/libesintA1 /usr/share/iscan/esfwA1.bin +fi + diff --git a/srcpkgs/iscan-plugin-gt-x820/REMOVE b/srcpkgs/iscan-plugin-gt-x820/REMOVE new file mode 100644 index 00000000000000..8e73eabc5fdb03 --- /dev/null +++ b/srcpkgs/iscan-plugin-gt-x820/REMOVE @@ -0,0 +1,7 @@ +if [ "$UPDATE" = "no" ] && [ "$ACTION" = "pre" ]; then + # If we're removing sane-epkowa together with this package, + # there's no point (and no success) in calling iscan-registry + [ -x usr/bin/iscan-registry ] || exit 0 + usr/bin/iscan-registry --remove interpreter usb 0x04b8 0x013a \ + /usr/lib/iscan/libesintA1 /usr/share/iscan/esfwA1.bin +fi diff --git a/srcpkgs/iscan-plugin-gt-x820/template b/srcpkgs/iscan-plugin-gt-x820/template new file mode 100644 index 00000000000000..2d01d6ee70298d --- /dev/null +++ b/srcpkgs/iscan-plugin-gt-x820/template @@ -0,0 +1,39 @@ +# Template file for 'iscan-plugin-gt-x820' +pkgname=iscan-plugin-gt-x820 +version=2.2.1 +revision=1 +_bundlever=2.30.4 +archs="i686 x86_64" +depends="sane-epkowa" +short_desc="SANE/iscan plugin for Epson GT-X820/Perfection V600 Photo" +maintainer="yosh " +license="custom:EPSON" +homepage="http://download.ebz.epson.net/dsc/search/01/search/?OSC=LX" +case "$XBPS_TARGET_MACHINE" in + x86_64) + _arch=x64 + _plugin=x86_64 + checksum=63647dac68e26bfee5bd75108cc6a4df0fddb8453a1e3bac2d63dea7db518bee + ;; + i686) + _arch=x86 + _plugin=i686 + checksum=20f96a10e99be16a261bb1d716998dc4b041e4abb722228e2a9326db1a83901c + ;; +esac +distfiles="https://download2.ebz.epson.net/iscan/plugin/gt-x820/rpm/${_arch}/iscan-gt-x820-bundle-${_bundlever}.${_arch}.rpm.tar.gz" +repository=nonfree +restricted=yes + +post_extract() { + cd plugins + bsdtar -xf iscan-plugin-gt-x820-${version}-1.${_plugin}.rpm +} + +do_install() { + cd plugins + vlicense usr/share/doc/iscan-plugin-gt-x820-${version}/COPYING.EPSON.en.txt + vlicense usr/share/doc/iscan-plugin-gt-x820-${version}/COPYING.EPSON.ja.txt + vcopy usr/share/iscan usr/share + vcopy usr/lib*/* usr/lib +}