diff --git a/units-configure-c99.patch b/units-configure-c99.patch new file mode 100644 index 0000000..69ce068 --- /dev/null +++ b/units-configure-c99.patch @@ -0,0 +1,26 @@ +diff --git a/configure b/configure +index 22c75a6222b06f68..43461d54e59f1568 100755 +--- a/configure ++++ b/configure +@@ -3881,7 +3881,7 @@ else + int + main () + { +-wchar_t *out;char *in;char *res; ++wchar_t *out;char *in;const char *res; + res=setlocale(LC_CTYPE,"");res=in; + mbsrtowcs(out, &res, 2, NULL); + wcswidth(out,2); +diff --git a/configure.ac b/configure.ac +index c728d5c15d16ab2e..cd39f96e39f7d587 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -121,7 +121,7 @@ AC_CACHE_CHECK([for locale and UTF-8 support], am_cv_utf8, + #include + #include + #include +-], [wchar_t *out;char *in;char *res; ++], [wchar_t *out;char *in;const char *res; + res=setlocale(LC_CTYPE,"");res=in; + mbsrtowcs(out, &res, 2, NULL); + wcswidth(out,2);], diff --git a/units.spec b/units.spec index 5f486a7..74f3a40 100644 --- a/units.spec +++ b/units.spec @@ -1,7 +1,7 @@ Summary: A utility for converting amounts from one unit to another Name: units Version: 2.22 -Release: 6%{?dist} +Release: 7%{?dist} Source: https://ftp.gnu.org/gnu/units/%{name}-%{version}.tar.gz URL: https://www.gnu.org/software/units/units.html License: GPL-3.0-or-later @@ -14,6 +14,7 @@ BuildRequires: readline-devel # do not update currency.units from network during build Patch1: 0001-units-2.22-no-network.patch +Patch2: units-configure-c99.patch %description Units converts an amount from one unit to another, or tells you what @@ -52,6 +53,9 @@ make check %{_mandir}/man1/* %changelog +* Thu Nov 30 2023 Florian Weimer - 2.22-7 +- C compatibility fix for the configure script (#2252276) + * Sat Jul 22 2023 Fedora Release Engineering - 2.22-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild