[packages/perl-DBM-Deep] fix for perl >= 5.38; rel 2
atler
atler at pld-linux.org
Fri Jul 7 14:59:54 CEST 2023
commit 9fa840978571c6b6dfb5eb76cfd5b9b922d9ad6d
Author: Jan Palus <atler at pld-linux.org>
Date: Fri Jul 7 14:11:18 2023 +0200
fix for perl >= 5.38; rel 2
based on: https://github.com/robkinyon/dbm-deep/pull/22
perl-DBM-Deep.spec | 4 +++-
perl5.38.patch | 38 ++++++++++++++++++++++++++++++++++++++
2 files changed, 41 insertions(+), 1 deletion(-)
---
diff --git a/perl-DBM-Deep.spec b/perl-DBM-Deep.spec
index b635bc6..d9c7caa 100644
--- a/perl-DBM-Deep.spec
+++ b/perl-DBM-Deep.spec
@@ -8,12 +8,13 @@ Summary: DBM::Deep - A pure Perl multi-level hash/array DBM
Summary(pl.UTF-8): DBM::Deep - czysto perlowy moduł DBM dla wielopoziomowych haszy/tablic
Name: perl-DBM-Deep
Version: 2.0016
-Release: 1
+Release: 2
# same as perl
License: GPL v1+ or Artistic
Group: Development/Languages/Perl
Source0: http://www.cpan.org/modules/by-module/DBM/%{pdir}-%{pnam}-%{version}.tar.gz
# Source0-md5: cb8817ddd1fecc81ae2d47f812fd1f0e
+Patch0: perl5.38.patch
URL: https://metacpan.org/release/DBM-Deep
BuildRequires: perl-Module-Build >= 0.28
BuildRequires: perl-devel >= 1:5.8.4
@@ -54,6 +55,7 @@ kompatybilny z Uniksami, Mac OS X oraz Windows.
%prep
%setup -q -n %{pdir}-%{pnam}-%{version}
+%patch0 -p1
%build
%{__perl} Makefile.PL \
diff --git a/perl5.38.patch b/perl5.38.patch
new file mode 100644
index 0000000..2c80e06
--- /dev/null
+++ b/perl5.38.patch
@@ -0,0 +1,38 @@
+From f6d5f18703a39be52ee04df5234f6ebd7ba1b9b7 Mon Sep 17 00:00:00 2001
+From: Yves Orton <demerphq at gmail.com>
+Date: Thu, 9 Feb 2023 17:02:35 +0100
+Subject: [PATCH] lib/DBM/Deep.pm - apostrophe as package separator deprecated
+ in 5.37.8
+
+In 5.40.0 we will remove support for apostrophe as a package separator
+entirely, and in 5.37.8 we marked it as deprecated so it will warn.
+
+This patch removes its use from lib/DBM/Deep.pm and bumps the version
+to 2.0017
+---
+ lib/DBM/Deep.pm | 10 +++++-----
+ lib/DBM/Deep.pod | 2 +-
+ 2 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/lib/DBM/Deep.pm b/lib/DBM/Deep.pm
+index 8a8ead7..61ff547 100644
+--- a/lib/DBM/Deep.pm
++++ b/lib/DBM/Deep.pm
+@@ -647,13 +647,13 @@ sub _warnif {
+ # to avoid this hack. warnings.pm did not allow us to specify
+ # exactly the call frame we want, so we have to look at the bitmask
+ # ourselves.
+- if( vec $bitmask, $warnings'Offsets{$_[0]}, 1,
+- || vec $bitmask, $warnings'Offsets{all}, 1,
++ if( vec $bitmask, $warnings::Offsets{$_[0]}, 1,
++ || vec $bitmask, $warnings::Offsets{all}, 1,
+ ) {
+ my $msg = $_[1] =~ /\n\z/ ? $_[1] : "$_[1] at $file line $line.\n";
+ die $msg
+- if vec $bitmask, $warnings'Offsets{$_[0]}+1, 1,
+- || vec $bitmask, $warnings'Offsets{all}+1, 1;
++ if vec $bitmask, $warnings::Offsets{$_[0]}+1, 1,
++ || vec $bitmask, $warnings::Offsets{all}+1, 1;
+ warn $msg;
+ }
+ }
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/perl-DBM-Deep.git/commitdiff/9fa840978571c6b6dfb5eb76cfd5b9b922d9ad6d
More information about the pld-cvs-commit
mailing list