From d83f2cccb3befbb9789a60c4aff984f5229c72a0 Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Tue, 28 May 2024 18:15:43 -0500 Subject: user/sane: Update to 1.3.1 for GCC + other fixes Also, they have dropped the SANE Exception from the genesys backend's license. Everything is GPL-2.0+ or Public-Domain now. Closes: #1186 --- user/sane/APKBUILD | 19 +++++++++---------- user/sane/BTS-304.patch | 6 +++--- user/sane/endian.patch | 26 -------------------------- user/sane/network.patch | 6 +++--- user/sane/pidfile.patch | 2 +- 5 files changed, 16 insertions(+), 43 deletions(-) delete mode 100644 user/sane/endian.patch diff --git a/user/sane/APKBUILD b/user/sane/APKBUILD index d9f618013..2eade25c0 100644 --- a/user/sane/APKBUILD +++ b/user/sane/APKBUILD @@ -3,16 +3,17 @@ # Maintainer: A. Wilcox pkgname=sane _pkgname=sane-backends -pkgver=1.0.30 +pkgver=1.3.1 +_hash=83bdbb6c9a115184c2d48f1fdc6847db pkgrel=0 pkgdesc="Scanner access library" url="http://www.sane-project.org/" arch="all" -license="GPL-2.0+ AND GPL-2.0+-with-sane-exception AND Public-Domain" +license="GPL-2.0+ AND Public-Domain" depends="" makedepends="diffutils file libtool libusb-dev v4l-utils-dev net-snmp-dev libpng-dev libjpeg-turbo-dev tiff-dev libgphoto2-dev libieee1284-dev - linux-headers ncurses-dev" + libxml2-dev linux-headers ncurses-dev python3-dev" install="saned.pre-install $pkgname.pre-install" pkgusers="saned" pkggroups="scanner" @@ -37,9 +38,8 @@ done subpackages="$pkgname-doc $pkgname-dev $subpackages $pkgname-utils saned saned-openrc:openrc:noarch $pkgname-udev::noarch $_pkgname::noarch $pkgname-lang" -source="https://gitlab.com/sane-project/backends/uploads/c3dd60c9e054b5dee1e7b01a7edc98b0/sane-backends-1.0.30.tar.gz +source="https://gitlab.com/sane-project/backends/uploads/$_hash/$_pkgname-$pkgver.tar.gz saned.initd - endian.patch include.patch network.patch pidfile.patch @@ -139,11 +139,10 @@ _backend() { fi } -sha512sums="e9f4ab1f21d5ab0e09b101389c325947824945af968f08b307485f79d4dc4c134b8a1979fb0cf0cfa72435abffe70d0060748a2c2ec46514eb15a0442ee181a5 sane-backends-1.0.30.tar.gz +sha512sums="c6c12bce5242fcdf208f034cc544605cad36fad60316cb51f0e1f6fe23d1566823778c7af4b0fc94ca4154e2cd3e38a9202073e4a4af05f641c3da081722a535 sane-backends-1.3.1.tar.gz 0a06eaa28b345202f2bdf8361e06f843bb7a010b7d8f80132f742672c94249c43f64031cefa161e415e2e2ab3a53b23070fb63854283f9e040f5ff79394ac7d1 saned.initd -c7523b2684726cf35c0b251fe2e1863120284ff6ea3f93b53feb5dfa020c1e383910ecdd1a0c77a2289912ac4fd355cb3c743ea3706dab1bcf0a3412e1d0fbcc endian.patch 1779ff8beb1ba5f9238c25d819a7f0045f7e257c19b511315feb85650e445ca86450a9e1d7ff8650499d3dae808589a6c2e358d5f3f39a3f40ce4999179b86d6 include.patch -dfeaef3c94c3e66b1cfb27348b8e1f3620143fd9a41e3c0b33d9c16f9bc4af2b20e40c83fec385c5765e8c3a812a00508bccdf8f27d571cfc0d8fac9dee41205 network.patch -8f0a1529a5793bc78422419b674963b543527c932476c9ea2d92ea0ad0a286691da306020824c1aaa0b35929f571480d21d7fc464a9f652e15664854c75a4cea pidfile.patch +ef5d572bd29463e0690f6b45ddc609045ba6e40ab7c6bdab065b9480eef38884604650fd390d2a3c46b1f13b228e700392a6f635b4d7372130de6b2106208405 network.patch +30ef4a151e896ad415bab5e6a2963611321ff39d4b91d591d2678a5f73b1cd809f90855f970edec3d944aa0f48fb2902c20184794f941312b849e7ab44967030 pidfile.patch 4de6f60452c0451769f5ce41e41ca4c2867a723e0d2bf22796dc8a266359bdc8a9e9542f4ba2dc42b15bd25b1c83d2c339177796043fdbcbc9d73ad4957f723c check.patch -de2bd02d02e9a2d061d7c5783d3e4e64e9a68e83b15adc122946efff369ad5e382bd918a9585f5fe99ede546f002bb3db0f1b54306f4409fde38b2e26c008162 BTS-304.patch" +9c4877335531415df4aa37d797927765076f2e98d7301e057b24d5e45a696b75e86140eec403a599508c270ff63faf29b07ced6591a647ff48d280edcab70208 BTS-304.patch" diff --git a/user/sane/BTS-304.patch b/user/sane/BTS-304.patch index 64b7dca02..6d36589e9 100644 --- a/user/sane/BTS-304.patch +++ b/user/sane/BTS-304.patch @@ -2,7 +2,7 @@ diff --git a/backend/genesys/image_pixel.cpp b/backend/genesys/image_pixel.cpp index 1b83e127d..1ebba7fe0 100644 --- a/backend/genesys/image_pixel.cpp +++ b/backend/genesys/image_pixel.cpp -@@ -46,6 +46,7 @@ +@@ -23,6 +23,7 @@ #include "image.h" #include @@ -10,7 +10,7 @@ index 1b83e127d..1ebba7fe0 100644 namespace genesys { -@@ -207,7 +208,7 @@ void set_pixel_to_row(std::uint8_t* data, std::size_t x, Pixel pixel, PixelForma +@@ -184,7 +185,7 @@ void set_pixel_to_row(std::uint8_t* data, std::size_t x, Pixel pixel, PixelForma float val = (pixel.r >> 8) * 0.3f; val += (pixel.g >> 8) * 0.59f; val += (pixel.b >> 8) * 0.11f; @@ -19,7 +19,7 @@ index 1b83e127d..1ebba7fe0 100644 return; } case PixelFormat::I16: { -@@ -215,7 +216,7 @@ void set_pixel_to_row(std::uint8_t* data, std::size_t x, Pixel pixel, PixelForma +@@ -192,7 +193,7 @@ void set_pixel_to_row(std::uint8_t* data, std::size_t x, Pixel pixel, PixelForma float val = pixel.r * 0.3f; val += pixel.g * 0.59f; val += pixel.b * 0.11f; diff --git a/user/sane/endian.patch b/user/sane/endian.patch deleted file mode 100644 index f55f01ecc..000000000 --- a/user/sane/endian.patch +++ /dev/null @@ -1,26 +0,0 @@ -From e1934720c687ed8c6125c75ac658f55b4e1513ce Mon Sep 17 00:00:00 2001 -From: Luiz Angelo Daros de Luca -Date: Sun, 2 Feb 2020 21:19:15 -0300 -Subject: [PATCH] genesys: fix bigendian build - -Signed-off-by: Luiz Angelo Daros de Luca ---- - backend/genesys/low.cpp | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/backend/genesys/low.cpp b/backend/genesys/low.cpp -index 1e1b632bf..cbb43b045 100644 ---- a/backend/genesys/low.cpp -+++ b/backend/genesys/low.cpp -@@ -546,7 +546,7 @@ Image read_unshuffled_image_from_scanner(Genesys_Device* dev, const ScanSession& - } - - #ifdef WORDS_BIGENDIAN -- if (depth == 16) { -+ if (session.params.depth == 16) { - dev->pipeline.push_node(); - } - #endif --- -2.24.1 - diff --git a/user/sane/network.patch b/user/sane/network.patch index 845bf9913..a8f53cfce 100644 --- a/user/sane/network.patch +++ b/user/sane/network.patch @@ -1,6 +1,6 @@ --- sane-backends-1.0.30/sanei/sanei_tcp.c 2020-05-17 06:54:18.000000000 -0500 +++ sane-backends-1.0.30/sanei/sanei_tcp.c 2020-06-10 14:10:06.980398975 -0500 -@@ -46,6 +46,7 @@ +@@ -44,6 +44,7 @@ #include #include #include @@ -8,7 +8,7 @@ #ifndef SSIZE_MAX #define SSIZE_MAX LONG_MAX -@@ -130,6 +131,7 @@ sanei_tcp_read(int fd, u_char * buf, siz +@@ -128,6 +130,7 @@ sanei_tcp_read(int fd, u_char * buf, siz { size_t bytes_recv = 0; ssize_t rc = 1; @@ -16,7 +16,7 @@ if (count > SSIZE_MAX) { errno = EINVAL; -@@ -139,9 +141,21 @@ sanei_tcp_read(int fd, u_char * buf, siz +@@ -137,9 +139,21 @@ sanei_tcp_read(int fd, u_char * buf, siz while (bytes_recv < count && rc > 0) { rc = recv(fd, buf+bytes_recv, count-bytes_recv, 0); diff --git a/user/sane/pidfile.patch b/user/sane/pidfile.patch index 32989f651..579c99939 100644 --- a/user/sane/pidfile.patch +++ b/user/sane/pidfile.patch @@ -1,6 +1,6 @@ --- a/frontend/saned.c +++ b/frontend/saned.c -@@ -229,7 +229,7 @@ +@@ -230,7 +230,7 @@ int numchildren; #define SANED_CONFIG_FILE "saned.conf" -- cgit v1.2.3-70-g09d2