diff --git a/graphics/sane-airscan/Makefile b/graphics/sane-airscan/Makefile new file mode 100644 index 000000000000..c9ffb679beff --- /dev/null +++ b/graphics/sane-airscan/Makefile @@ -0,0 +1,31 @@ +PORTNAME= sane-airscan +DISTVERSION= 0.99.26 +CATEGORIES= graphics + +MAINTAINER= henry.hu.sh@gmail.com +COMMENT= SANE backend for AirScan (eSCL) and WSD document scanners + +LICENSE= GPLv2 +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libavahi-client.so:net/avahi-app \ + libpng.so:graphics/png \ + libgnutls.so:security/gnutls +BUILD_DEPENDS= sane-backends>0:graphics/sane-backends + +USES= gmake gnome jpeg pkgconfig +USE_GNOME= libxml2 +USE_GITHUB= yes +GH_ACCOUNT= alexpevzner + +MAKE_ARGS= CC=${CC} PKG_CONFIG=pkgconf + +MANPAGES= sane-airscan.5 airscan-discover.1 + +post-install: + @${MV} ${STAGEDIR}${PREFIX}/etc/sane.d/airscan.conf \ + ${STAGEDIR}${PREFIX}/etc/sane.d/airscan.conf.sample + ${RLN} ${STAGEDIR}${PREFIX}/lib/sane/libsane-airscan.so.1 \ + ${STAGEDIR}${PREFIX}/lib/sane/libsane-airscan.so + +.include diff --git a/graphics/sane-airscan/distinfo b/graphics/sane-airscan/distinfo new file mode 100644 index 000000000000..4938ddffc27a --- /dev/null +++ b/graphics/sane-airscan/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1630878170 +SHA256 (alexpevzner-sane-airscan-0.99.26_GH0.tar.gz) = f124d51e1510a4950454794eba0ba633e4b58d312cdeb26b80deb192d563ce5e +SIZE (alexpevzner-sane-airscan-0.99.26_GH0.tar.gz) = 196488 diff --git a/graphics/sane-airscan/files/patch-Makefile b/graphics/sane-airscan/files/patch-Makefile new file mode 100644 index 000000000000..2b752b8f48c7 --- /dev/null +++ b/graphics/sane-airscan/files/patch-Makefile @@ -0,0 +1,21 @@ +--- Makefile.orig 2021-04-16 08:52:40 UTC ++++ Makefile +@@ -29,7 +29,8 @@ + + CC = gcc + COMPRESS = gzip -n +-CFLAGS += -O2 -g -W -Wall -Werror -pthread $(CPPFLAGS) ++CFLAGS ?= -O2 -g -W -Wall -Werror ++CFLAGS += -pthread $(CPPFLAGS) + PKG_CONFIG = pkg-config + STRIP = -s + INSTALL = install +@@ -101,7 +102,7 @@ $(OBJDIR)%.o: %.c Makefile airscan.h + + .PHONY: all clean install man + +-all: tags $(BACKEND) $(DISCOVER) test test-decode test-multipart test-zeroconf test-uri ++all: $(BACKEND) $(DISCOVER) test test-decode test-multipart test-zeroconf test-uri + + tags: $(SRC) airscan.h test.c test-decode.c test-multipart.c test-zeroconf.c test-uri.c + -ctags -R . diff --git a/graphics/sane-airscan/pkg-descr b/graphics/sane-airscan/pkg-descr new file mode 100644 index 000000000000..02ff0fce01e9 --- /dev/null +++ b/graphics/sane-airscan/pkg-descr @@ -0,0 +1,17 @@ +SANE backend for AirScan (eSCL) and WSD document scanner + +Similar to how most modern network printers support "driverless" printing, +using the universal vendor-neutral printing protocol, many modern network +scanners and MFPs support "driverless" scanning. + +Driverless scanning comes in two flavors: + +* Apple AirScan or AirPrint scanning (official protocol name is eSCL) +* Microsoft WSD, or WS-Scan (term WSD means "Web Services for Devices) + +This backend implements both protocols, choosing automatically between them. +It was successfully tested with many devices from Brother, Canon, Dell, +Kyocera, Lexmark, Epson, HP, OKI, Panasonic, Pantum, Ricoh, Samsung and +Xerox both in WSD and eSCL modes. + +WWW: https://github.com/alexpevzner/sane-airscan diff --git a/graphics/sane-airscan/pkg-message b/graphics/sane-airscan/pkg-message new file mode 100644 index 000000000000..e3fdc845c2b4 --- /dev/null +++ b/graphics/sane-airscan/pkg-message @@ -0,0 +1,20 @@ +[ +{ type: install + message: <