From 1805d6851503d870a6b99de23f10c50547dd4f3f Mon Sep 17 00:00:00 2001 From: Giuseppe Fierro Date: Tue, 6 Feb 2018 14:52:15 +0100 Subject: [PATCH] New package: imagescan-3.35.0 Closes: #11419 [via git-merge-pr] --- srcpkgs/imagescan/files/imagescan.desktop | 11 ++++++ .../patches/makefile_in-sane_dll_d.patch | 37 +++++++++++++++++++ srcpkgs/imagescan/template | 32 ++++++++++++++++ 3 files changed, 80 insertions(+) create mode 100644 srcpkgs/imagescan/files/imagescan.desktop create mode 100644 srcpkgs/imagescan/patches/makefile_in-sane_dll_d.patch create mode 100644 srcpkgs/imagescan/template diff --git a/srcpkgs/imagescan/files/imagescan.desktop b/srcpkgs/imagescan/files/imagescan.desktop new file mode 100644 index 00000000000..ec5bb2beb5b --- /dev/null +++ b/srcpkgs/imagescan/files/imagescan.desktop @@ -0,0 +1,11 @@ +[Desktop Entry] +Encoding=UTF-8 +Type=Application +Categories=Application;Graphics;RasterGraphics;Scanning;GTK; + +Name=Image Scan +GenericName=Scan Dialog + +Exec=utsushi scan +Terminal=false +Icon=scanner diff --git a/srcpkgs/imagescan/patches/makefile_in-sane_dll_d.patch b/srcpkgs/imagescan/patches/makefile_in-sane_dll_d.patch new file mode 100644 index 00000000000..d1ceb3b8614 --- /dev/null +++ b/srcpkgs/imagescan/patches/makefile_in-sane_dll_d.patch @@ -0,0 +1,37 @@ +--- sane/Makefile.in 2018-01-29 07:20:05.000000000 +0100 ++++ sane/Makefile.in 2018-03-10 14:33:27.313350166 +0100 +@@ -1005,28 +1005,12 @@ + @enable_sane_config_TRUE@ echo " skipping component activation"; \ + @enable_sane_config_TRUE@ exit 1; \ + @enable_sane_config_TRUE@ fi +-@enable_sane_config_TRUE@ if test -d "$(SANE_SYSCONFDIR)/dll.d"; then \ +-@enable_sane_config_TRUE@ dirname="$(DESTDIR)$(SANE_SYSCONFDIR)/dll.d"; \ +-@enable_sane_config_TRUE@ file=$$dirname/$(BACKEND_NAME); \ +-@enable_sane_config_TRUE@ test -d $$dirname || $(MKDIR_P) $$dirname; \ +-@enable_sane_config_TRUE@ echo "# $(BACKEND_NAME) -- dll.conf snippet" > $$file; \ +-@enable_sane_config_TRUE@ echo "" >> $$file; \ +-@enable_sane_config_TRUE@ echo "$(BACKEND_NAME)" >> $$file; \ +-@enable_sane_config_TRUE@ else \ +-@enable_sane_config_TRUE@ dirname="$(DESTDIR)$(SANE_SYSCONFDIR)"; \ +-@enable_sane_config_TRUE@ file=$$dirname/dll.conf; \ +-@enable_sane_config_TRUE@ if test -f $$file; then \ +-@enable_sane_config_TRUE@ if test -n "`$(GREP) '^[ \t]*#[ \t#]*$(BACKEND_NAME)' $$file`"; \ +-@enable_sane_config_TRUE@ then \ +-@enable_sane_config_TRUE@ sed -i 's,^[ \t]*#[ \t#]*\($(BACKEND_NAME)\),\1,' $$file; \ +-@enable_sane_config_TRUE@ elif test -z "`$(GREP) $(BACKEND_NAME) $$file`"; then\ +-@enable_sane_config_TRUE@ echo $(BACKEND_NAME) >> $$file; \ +-@enable_sane_config_TRUE@ fi; \ +-@enable_sane_config_TRUE@ else \ +-@enable_sane_config_TRUE@ echo $(ECHO_N) "WARNING: $$file not found,"; \ +-@enable_sane_config_TRUE@ echo " cannot activate SANE component"; \ +-@enable_sane_config_TRUE@ fi; \ +-@enable_sane_config_TRUE@ fi ++@enable_sane_config_TRUE@ dirname="$(DESTDIR)$(SANE_SYSCONFDIR)/dll.d"; \ ++@enable_sane_config_TRUE@ file=$$dirname/$(BACKEND_NAME); \ ++@enable_sane_config_TRUE@ test -d $$dirname || $(MKDIR_P) $$dirname; \ ++@enable_sane_config_TRUE@ echo "# $(BACKEND_NAME) -- dll.conf snippet" > $$file; \ ++@enable_sane_config_TRUE@ echo "" >> $$file; \ ++@enable_sane_config_TRUE@ echo "$(BACKEND_NAME)" >> $$file; + + @enable_sane_config_TRUE@uninstall-hook-data: + @enable_sane_config_TRUE@ @$(NORMAL_UNINSTALL) diff --git a/srcpkgs/imagescan/template b/srcpkgs/imagescan/template new file mode 100644 index 00000000000..bd951bee6a7 --- /dev/null +++ b/srcpkgs/imagescan/template @@ -0,0 +1,32 @@ +# Template file for 'imagescan' +pkgname=imagescan +version=3.35.0 +revision=1 +wrksrc="utsushi-0.35.0" +build_style=gnu-configure +configure_args="--libexecdir=/usr/lib --with-boost-libdir=${XBPS_CROSS_BASE}/usr/lib + --with-gtkmm --enable-sane-config --with-sane-confdir=/etc/sane.d --enable-udev-config + --with-udev-confdir=/usr/lib/udev --with-jpeg --with-magick --with-sane --with-tiff" +conf_files="/etc/utsushi/combo.conf" +mutable_files="/etc/sane.d/dll.d/utsushi" +hostmakedepends="pkg-config ImageMagick sane" +makedepends="boost boost-devel gtkmm2 gtkmm2-devel eudev-libudev-devel libusb-devel + bzip2-devel zlib-devel libjpeg-turbo-devel tiff-devel sane-devel" +depends="ImageMagick" +short_desc="EPSON Image Scan v3 front-end and backend for scanners and all-in-ones" +maintainer="Giuseppe Fierro " +license="GPL-3" +homepage="https://github.com/utsushi/imagescan" +distfiles="http://support.epson.net/linux/src/scanner/imagescanv3/debian/${pkgname}_${version}.orig.tar.gz" +checksum=b1bcd3e0c13d33fc05dceaf65220470347b1c7415da225c909e71916a69cdf25 + +CFLAGS="-Wno-error" +CXXFLAGS="-Wno-error" + +post_install() { + # remove include dir + rm -rf $DESTDIR/usr/include + # rename udev rule + mv $DESTDIR/usr/lib/udev/rules.d/{,60-}utsushi-esci.rules + vinstall $FILESDIR/imagescan.desktop 644 usr/share/applications +}