[gentoo-commits] repo/gentoo:master commit in: dev-perl/Unicode-UTF8/files/

2025-01-23 Thread Sam James
commit: 006f7231973f49059e9340f4a13c4b893c35d048
Author: Sam James  gentoo  org>
AuthorDate: Thu Jan 23 08:41:57 2025 +
Commit: Sam James  gentoo  org>
CommitDate: Thu Jan 23 08:41:57 2025 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=006f7231

dev-perl/Unicode-UTF8: adjust test count for 32-bit

Closes: https://bugs.gentoo.org/927591
Bug: https://bugs.gentoo.org/925365
Signed-off-by: Sam James  gentoo.org>

 .../files/Unicode-UTF8-0.620.0-32-bit.patch | 21 +
 1 file changed, 21 insertions(+)

diff --git a/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch 
b/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch
index 9c243c9d106a..9eb0702c6abc 100644
--- a/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch
+++ b/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch
@@ -50,3 +50,24 @@ Subject: [PATCH 2/2] fixup! Fix 080_super.t for 32-bit
  push @SUPER, $i;
  }
 
+--- a/t/080_super.t
 b/t/080_super.t
+@@ -5,10 +5,17 @@ use strict;
+ use warnings;
+ use lib 't';
+ 
+-use Test::More tests => 1537;
++use Test::More;
+ use Util   qw[throws_ok];
+ 
+ BEGIN {
++if ($Config{ivsize} > 4) {
++plan tests => 1537;
++}
++else {
++plan tests => 1025;
++}
++
+ use_ok('Unicode::UTF8', qw[ encode_utf8 ]);
+ }
+ 



[gentoo-commits] repo/gentoo:master commit in: dev-perl/Unicode-UTF8/files/, dev-perl/Unicode-UTF8/

2024-03-11 Thread Sam James
commit: d9a4c4a5bce7bb45f75c5552adf4e799b6bcb829
Author: Sam James  gentoo  org>
AuthorDate: Tue Mar 12 05:52:32 2024 +
Commit: Sam James  gentoo  org>
CommitDate: Tue Mar 12 05:52:32 2024 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d9a4c4a5

dev-perl/Unicode-UTF8: fix 32-bit tests

Closes: https://bugs.gentoo.org/925365
Signed-off-by: Sam James  gentoo.org>

 .../Unicode-UTF8/Unicode-UTF8-0.620.0-r1.ebuild|  6 ++-
 .../files/Unicode-UTF8-0.620.0-32-bit.patch| 52 ++
 2 files changed, 57 insertions(+), 1 deletion(-)

diff --git a/dev-perl/Unicode-UTF8/Unicode-UTF8-0.620.0-r1.ebuild 
b/dev-perl/Unicode-UTF8/Unicode-UTF8-0.620.0-r1.ebuild
index efe2e84c7e4d..9bf3e2d925c5 100644
--- a/dev-perl/Unicode-UTF8/Unicode-UTF8-0.620.0-r1.ebuild
+++ b/dev-perl/Unicode-UTF8/Unicode-UTF8-0.620.0-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -30,6 +30,10 @@ BDEPEND="${RDEPEND}
)
 "
 
+PATCHES=(
+   "${FILESDIR}"/${PN}-0.620.0-32-bit.patch
+)
+
 src_test() {
perl_rm_files t/999_pod.t
perl-module_src_test

diff --git a/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch 
b/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch
new file mode 100644
index ..9c243c9d106a
--- /dev/null
+++ b/dev-perl/Unicode-UTF8/files/Unicode-UTF8-0.620.0-32-bit.patch
@@ -0,0 +1,52 @@
+https://bugs.gentoo.org/925365
+https://rt.cpan.org/Public/Bug/Display.html?id=127007
+https://github.com/chansen/p5-unicode-utf8/pull/3
+
+From cb30ee19c31a27254c709b78451159d89c377beb Mon Sep 17 00:00:00 2001
+From: "E. Choroba" 
+Date: Thu, 6 Dec 2018 14:42:09 +0100
+Subject: [PATCH 1/2] Fix 080_super.t for 32-bit
+
+Copied from https://rt.cpan.org/Public/Bug/Display.html?id=127007.
+--- a/t/080_super.t
 b/t/080_super.t
+@@ -1,5 +1,6 @@
+ #!perl
+ 
++use Config;
+ use strict;
+ use warnings;
+ use lib 't';
+@@ -16,8 +17,12 @@ my @SUPER = ();
+ for (my $i = 0x0011_; $i < 0x7FFF_; $i += 0x20) {
+ push @SUPER, $i;
+ }
+-for (my $i = 0x8000_; $i < 0x_; $i += 0x40) {
+-push @SUPER, $i;
++
++# Doesn't work on 32 bit.
++if ($Config{ptrsize} == 8) {
++for (my $i = 0x8000_; $i < 0x_; $i += 0x40) {
++push @SUPER, $i;
++}
+ }
+ }
+ 
+
+From f989eaedfe83639c7be35fd429af36452ebaf1d2 Mon Sep 17 00:00:00 2001
+From: "E. Choroba" 
+Date: Tue, 11 Dec 2018 17:30:13 +0100
+Subject: [PATCH 2/2] fixup! Fix 080_super.t for 32-bit
+
+--- a/t/080_super.t
 b/t/080_super.t
+@@ -19,7 +19,7 @@ my @SUPER = ();
+ }
+ 
+ # Doesn't work on 32 bit.
+-if ($Config{ptrsize} == 8) {
++if ($Config{ivsize} > 4) {
+ for (my $i = 0x8000_; $i < 0x_; $i += 0x40) {
+ push @SUPER, $i;
+ }
+