From 0bb8253b38dc8638a46b66ba909c1bfd1054e1ef Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 4 Nov 2022 09:13:50 +0000 Subject: gentoo auto-resync : 04:11:2022 - 09:13:50 --- media-gfx/sane-backends/files/66-saned.rules-r1 | 2 + .../sane-backends-1.1.1-configure-clang16.patch | 43 ++++++++++++ .../files/sane-backends-1.1.1-gcc12-tests.patch | 78 ++++++++++++++++++++++ .../files/sane-backends-1.1.1-musl.patch | 34 ++++++++++ media-gfx/sane-backends/files/saned_at.service-r1 | 18 +++++ 5 files changed, 175 insertions(+) create mode 100644 media-gfx/sane-backends/files/66-saned.rules-r1 create mode 100644 media-gfx/sane-backends/files/sane-backends-1.1.1-configure-clang16.patch create mode 100644 media-gfx/sane-backends/files/sane-backends-1.1.1-gcc12-tests.patch create mode 100644 media-gfx/sane-backends/files/sane-backends-1.1.1-musl.patch create mode 100644 media-gfx/sane-backends/files/saned_at.service-r1 (limited to 'media-gfx/sane-backends/files') diff --git a/media-gfx/sane-backends/files/66-saned.rules-r1 b/media-gfx/sane-backends/files/66-saned.rules-r1 new file mode 100644 index 000000000000..4e1fe9507eae --- /dev/null +++ b/media-gfx/sane-backends/files/66-saned.rules-r1 @@ -0,0 +1,2 @@ +# udev rule for saned (SANE scanning daemon) to be able to write on usb port +ENV{libsane_matched}=="yes", ENV{DEVNAME}!="", RUN+="/bin/setfacl -m g:scanner:rw $env{DEVNAME}" diff --git a/media-gfx/sane-backends/files/sane-backends-1.1.1-configure-clang16.patch b/media-gfx/sane-backends/files/sane-backends-1.1.1-configure-clang16.patch new file mode 100644 index 000000000000..cc8a48b18b67 --- /dev/null +++ b/media-gfx/sane-backends/files/sane-backends-1.1.1-configure-clang16.patch @@ -0,0 +1,43 @@ +https://gitlab.com/sane-project/backends/-/merge_requests/763 + +From 300b460970f538ab515835f14650785e88808a8f Mon Sep 17 00:00:00 2001 +From: Sam James +Date: Fri, 4 Nov 2022 04:04:46 +0000 +Subject: [PATCH] acinclude.m4: fix -Wimplicit-function-declaration + +-Wimplicit-function-declaration will become an error by default +in Clang 16. + +Fixes errors like: +``` +error: call to undeclared library function 'exit' with type 'void (int) __attribute__((noreturn))'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] +``` + +Signed-off-by: Sam James +--- a/acinclude.m4 ++++ b/acinclude.m4 +@@ -471,6 +471,7 @@ AC_DEFUN([SANE_CHECK_IPV6], + if test "$ipv6" != "no" ; then + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #define INET6 ++ #include + #include + #include ]], [[ + /* AF_INET6 available check */ +@@ -492,6 +493,7 @@ AC_DEFUN([SANE_CHECK_IPV6], + AC_MSG_CHECKING([whether struct sockaddr_storage has an ss_family member]) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #define INET6 ++ #include + #include + #include ]], [[ + /* test if the ss_family member exists in struct sockaddr_storage */ +@@ -504,6 +506,7 @@ AC_DEFUN([SANE_CHECK_IPV6], + ], [ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #define INET6 ++ #include + #include + #include ]], [[ + /* test if the __ss_family member exists in struct sockaddr_storage */ +GitLab diff --git a/media-gfx/sane-backends/files/sane-backends-1.1.1-gcc12-tests.patch b/media-gfx/sane-backends/files/sane-backends-1.1.1-gcc12-tests.patch new file mode 100644 index 000000000000..25a1e4db265e --- /dev/null +++ b/media-gfx/sane-backends/files/sane-backends-1.1.1-gcc12-tests.patch @@ -0,0 +1,78 @@ +https://bugs.gentoo.org/840137 +https://gitlab.com/sane-project/backends/-/commit/6b99447f5b12758ff015b5c360a6dcbcf9b0a72d +https://gitlab.com/sane-project/backends/-/issues/597 +https://gitlab.com/sane-project/backends/-/issues/557 + +From edfc90450ee06149537fadb3095ba4b215c5c4fa Mon Sep 17 00:00:00 2001 +From: Ralph Little +Date: Sun, 2 Oct 2022 18:14:25 -0700 +Subject: [PATCH] genesys: corrections to include file order. + +minigtest.h has items that require the definitions in tests_printers.h. +Pre-GCC-12, this didn't seem to matter but GCC12 seems to have a +problem with this and requires the template definitions to have already +appeared. +--- a/testsuite/backend/genesys/minigtest.cpp ++++ b/testsuite/backend/genesys/minigtest.cpp +@@ -18,10 +18,10 @@ + along with this program. If not, see . + */ + +-#include "minigtest.h" +- + #define DEBUG_DECLARE_ONLY + ++#include "minigtest.h" ++ + size_t s_num_successes = 0; + size_t s_num_failures = 0; + +--- a/testsuite/backend/genesys/tests_image.cpp ++++ b/testsuite/backend/genesys/tests_image.cpp +@@ -21,8 +21,8 @@ + #define DEBUG_DECLARE_ONLY + + #include "tests.h" +-#include "minigtest.h" + #include "tests_printers.h" ++#include "minigtest.h" + + #include "../../../backend/genesys/image.h" + #include "../../../backend/genesys/image_pipeline.h" +--- a/testsuite/backend/genesys/tests_image_pipeline.cpp ++++ b/testsuite/backend/genesys/tests_image_pipeline.cpp +@@ -21,8 +21,8 @@ + #define DEBUG_DECLARE_ONLY + + #include "tests.h" +-#include "minigtest.h" + #include "tests_printers.h" ++#include "minigtest.h" + + #include "../../../backend/genesys/image_pipeline.h" + +--- a/testsuite/backend/genesys/tests_motor.cpp ++++ b/testsuite/backend/genesys/tests_motor.cpp +@@ -21,8 +21,8 @@ + #define DEBUG_DECLARE_ONLY + + #include "tests.h" +-#include "minigtest.h" + #include "tests_printers.h" ++#include "minigtest.h" + + #include "../../../backend/genesys/low.h" + #include "../../../backend/genesys/enums.h" +--- a/testsuite/backend/genesys/tests_utilities.cpp ++++ b/testsuite/backend/genesys/tests_utilities.cpp +@@ -21,8 +21,8 @@ + #define DEBUG_DECLARE_ONLY + + #include "tests.h" +-#include "minigtest.h" + #include "tests_printers.h" ++#include "minigtest.h" + + #include "../../../backend/genesys/utilities.h" + +GitLab diff --git a/media-gfx/sane-backends/files/sane-backends-1.1.1-musl.patch b/media-gfx/sane-backends/files/sane-backends-1.1.1-musl.patch new file mode 100644 index 000000000000..8aebb50672a1 --- /dev/null +++ b/media-gfx/sane-backends/files/sane-backends-1.1.1-musl.patch @@ -0,0 +1,34 @@ +https://gitlab.com/sane-project/backends/-/commit/12560890a6e298091bd63b8093a35604416eb92a + +From 12560890a6e298091bd63b8093a35604416eb92a Mon Sep 17 00:00:00 2001 +From: David Ward +Date: Thu, 21 Apr 2022 23:37:33 -0400 +Subject: [PATCH] Fix header file used for poll() + +POSIX specifies the header to include is , not . +This results in a compiler warning with musl libc (on Alpine Linux). +--- a/configure.ac ++++ b/configure.ac +@@ -202,7 +202,7 @@ AC_HEADER_STDC + AC_CHECK_HEADERS(fcntl.h unistd.h libc.h sys/dsreq.h sys/select.h \ + sys/time.h sys/shm.h sys/ipc.h sys/scanio.h os2.h \ + sys/socket.h sys/io.h sys/hw.h sys/types.h linux/ppdev.h \ +- dev/ppbus/ppi.h machine/cpufunc.h sys/sem.h sys/poll.h \ ++ dev/ppbus/ppi.h machine/cpufunc.h sys/sem.h poll.h \ + windows.h be/kernel/OS.h limits.h sys/ioctl.h asm/types.h\ + netinet/in.h tiffio.h ifaddrs.h pwd.h getopt.h) + AC_CHECK_HEADERS([asm/io.h],,,[#include ]) +--- a/frontend/saned.c ++++ b/frontend/saned.c +@@ -84,8 +84,8 @@ + + #include "lgetopt.h" + +-#if defined(HAVE_SYS_POLL_H) && defined(HAVE_POLL) +-# include ++#if defined(HAVE_POLL_H) && defined(HAVE_POLL) ++# include + #else + /* + * This replacement poll() using select() is only designed to cover +GitLab diff --git a/media-gfx/sane-backends/files/saned_at.service-r1 b/media-gfx/sane-backends/files/saned_at.service-r1 new file mode 100644 index 000000000000..b7d6179bba71 --- /dev/null +++ b/media-gfx/sane-backends/files/saned_at.service-r1 @@ -0,0 +1,18 @@ +[Unit] +Description=Scanner Service +Requires=saned.socket + +[Service] +ExecStart=/usr/sbin/saned +User=saned +Group=scanner +StandardInput=null +StandardOutput=syslog +StandardError=syslog +Environment=SANE_CONFIG_DIR=/etc/sane.d +# If you need to debug your configuration uncomment the next line and +# change it as appropriate to set the desired debug options +# Environment=SANE_DEBUG_DLL=255 SANE_DEBUG_NET=255 + +[Install] +Also=saned.socket -- cgit v1.2.3