From 5112ed2a1f3d7dbcc1b7b9486f6225d1254c4ae8 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Tue, 17 Jan 2023 17:18:35 +0100 Subject: [PATCH] Port configure script to C99 Related to: --- xsane-configure-c99.patch | 36 ++++++++++++++++++++++++++++++++++++ xsane.spec | 9 ++++++++- 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 xsane-configure-c99.patch diff --git a/xsane-configure-c99.patch b/xsane-configure-c99.patch new file mode 100644 index 0000000..75e6cff --- /dev/null +++ b/xsane-configure-c99.patch @@ -0,0 +1,36 @@ +Avoid implicit function declarations, for improved compatibility with +future compilers. + +Fixed upstream via: + +commit 562008027f343127d70bae44457cf8f06c666428 +Author: Ralph Little +Date: Thu Aug 29 21:49:08 2019 -0700 + + m4/sane.m4: remove m4/sane.m4 and update aclocal.m4 to suit. + + We are now using pkg-config and it is pretty much a one-liner. + No point in a whole file in m4 for just this feature. + +diff -up xsane-0.999/configure.c99 xsane-0.999/configure +--- xsane-0.999/configure.c99 2023-01-17 17:11:53.179785420 +0100 ++++ xsane-0.999/configure 2023-01-17 17:11:58.234735290 +0100 +@@ -6672,6 +6672,7 @@ else + + #include + #include ++#include + + int + main () +diff -up xsane-0.999/m4/sane.m4.c99 xsane-0.999/m4/sane.m4 +--- xsane-0.999/m4/sane.m4.c99 2023-01-17 17:11:08.940224113 +0100 ++++ xsane-0.999/m4/sane.m4 2023-01-17 17:11:11.565198082 +0100 +@@ -44,6 +44,7 @@ dnl + AC_TRY_RUN([ + #include + #include ++#include + + int + main () diff --git a/xsane.spec b/xsane.spec index e9add92..f8706a4 100644 --- a/xsane.spec +++ b/xsane.spec @@ -10,7 +10,7 @@ Name: xsane Summary: X Window System front-end for the SANE scanner interface Version: 0.999 -Release: 43%{?dist} +Release: 44%{?dist} Source0: http://www.xsane.org/download/%{name}-%{version}.tar.gz Source1: xsane-256x256.png # use "xdg-open" instead of "netscape" to launch help browser @@ -69,6 +69,9 @@ Patch15: xsane-0.999-signal-handling.patch # autoconf-generated files Patch100: xsane-0.999-7-autoconf.patch.bz2 + +Patch101: xsane-configure-c99.patch + License: GPLv2+ and LGPLv2+ URL: http://www.xsane.org/ @@ -142,6 +145,7 @@ done %patch15 -p1 -b .signal-handling %patch100 -p1 -b .autoconf +%patch101 -p1 -b .c99 # in-root config.h breaks off-root building rm include/config.h @@ -265,6 +269,9 @@ fi %{_datadir}/sane/xsane %changelog +* Tue Jan 17 2023 Florian Weimer - 0.999-44 +- Port configure script to C99 + * Sat Jul 23 2022 Fedora Release Engineering - 0.999-43 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild