[packages/perl-Text-Unaccent] correct types and align with new defines in perl's config.h
atler
atler at pld-linux.org
Sat Aug 2 02:26:11 CEST 2025
commit 7a4c1faad967c0db7a20ac6d5181ee5812b558be
Author: Jan Palus <atler at pld-linux.org>
Date: Sat Aug 2 02:25:23 2025 +0200
correct types and align with new defines in perl's config.h
build.patch | 22 ++++++++++++++++++++++
perl-Text-Unaccent.spec | 4 ++++
types.patch | 25 +++++++++++++++++++++++++
3 files changed, 51 insertions(+)
---
diff --git a/perl-Text-Unaccent.spec b/perl-Text-Unaccent.spec
index e5bdc67..b5a1261 100644
--- a/perl-Text-Unaccent.spec
+++ b/perl-Text-Unaccent.spec
@@ -13,6 +13,8 @@ License: GPL v2+
Group: Development/Languages/Perl
Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
# Source0-md5: 9ac9b28cbb66f4829a50d563ace79cb5
+Patch0: types.patch
+Patch1: build.patch
URL: http://search.cpan.org/dist/Text-Unaccent/
BuildRequires: perl-devel >= 1:5.8.0
BuildRequires: rpm-perlprov >= 4.1-13
@@ -40,6 +42,8 @@ Text-Unaccent-1.01 ma te same pliki unac.[ch] co unac-1.1.0.
%prep
%setup -q -n %{pdir}-%{pnam}-%{version}
+%patch -P0 -p1
+%patch -P1 -p1
%build
%{__perl} Makefile.PL \
diff --git a/build.patch b/build.patch
new file mode 100644
index 0000000..89baa22
--- /dev/null
+++ b/build.patch
@@ -0,0 +1,22 @@
+--- Text-Unaccent-1.08/unac.h.orig 2004-10-17 21:00:36.000000000 +0200
++++ Text-Unaccent-1.08/unac.h 2025-08-02 02:15:27.392522843 +0200
+@@ -104,7 +104,7 @@
+ #define UNAC_DEBUG_LOW 0x01
+ #define UNAC_DEBUG_HIGH 0x02
+
+-#ifdef HAVE_VSNPRINTF
++#if defined(HAVE_VSNPRINTF) || defined(HAS_VSNPRINTF)
+ #define UNAC_DEBUG_AVAILABLE 1
+ /*
+ * Set the unac debug level. <l> is one of:
+--- Text-Unaccent-1.08/unac.c.orig 2004-10-17 21:00:36.000000000 +0200
++++ Text-Unaccent-1.08/unac.c 2025-08-02 02:18:53.364247120 +0200
+@@ -40,7 +40,7 @@
+ #include <string.h>
+ #include <iconv.h>
+ #include <errno.h>
+-#ifdef HAVE_VSNPRINTF
++#if defined(HAVE_VSNPRINTF) || defined(HAS_VSNPRINTF)
+ #include <stdio.h>
+ #include <stdarg.h>
+ #endif /* HAVE_VSNPRINTF */
diff --git a/types.patch b/types.patch
new file mode 100644
index 0000000..2e89cf6
--- /dev/null
+++ b/types.patch
@@ -0,0 +1,25 @@
+--- Text-Unaccent-1.08/unac.c.orig 2004-10-17 21:00:36.000000000 +0200
++++ Text-Unaccent-1.08/unac.c 2025-08-02 02:18:53.364247120 +0200
+@@ -13881,9 +13881,9 @@
+ *out_lengthp = 0;
+ } else {
+ char* utf16 = 0;
+- int utf16_length = 0;
++ size_t utf16_length = 0;
+ char* utf16_unaccented = 0;
+- int utf16_unaccented_length = 0;
++ size_t utf16_unaccented_length = 0;
+
+ if(convert(charset, utf16be(), in, in_length, &utf16, &utf16_length) < 0) {
+ return -1;
+--- Text-Unaccent-1.08/Unaccent.xs.orig 2004-12-29 12:45:18.000000000 +0100
++++ Text-Unaccent-1.08/Unaccent.xs 2025-08-02 02:01:10.095728956 +0200
+@@ -35,7 +35,7 @@
+ #include "unac.h"
+
+ static char* buffer;
+-static int buffer_length;
++static size_t buffer_length;
+
+ static void unac_debug_print(const char* message, void* data)
+ {
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/perl-Text-Unaccent.git/commitdiff/7a4c1faad967c0db7a20ac6d5181ee5812b558be
More information about the pld-cvs-commit
mailing list