From ca45d858878d15c721e4566f57d40bcff0d7f543 Mon Sep 17 00:00:00 2001 From: MSVSphere Packaging Team Date: Tue, 26 Nov 2024 17:50:33 +0300 Subject: [PATCH] import perl-Data-Dumper-2.189-511.el10 --- .gitignore | 1 + .perl-Data-Dumper.metadata | 1 + .../Data-Dumper-2.183-Upgrade-to-2.184.patch | 274 +++++++++++++ .../Data-Dumper-2.184-Upgrade-to-2.188.patch | 168 ++++++++ .../Data-Dumper-2.188-Upgrade-to-2.189.patch | 43 ++ SPECS/perl-Data-Dumper.spec | 378 ++++++++++++++++++ 6 files changed, 865 insertions(+) create mode 100644 .gitignore create mode 100644 .perl-Data-Dumper.metadata create mode 100644 SOURCES/Data-Dumper-2.183-Upgrade-to-2.184.patch create mode 100644 SOURCES/Data-Dumper-2.184-Upgrade-to-2.188.patch create mode 100644 SOURCES/Data-Dumper-2.188-Upgrade-to-2.189.patch create mode 100644 SPECS/perl-Data-Dumper.spec diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4298214 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/Data-Dumper-2.183.tar.gz diff --git a/.perl-Data-Dumper.metadata b/.perl-Data-Dumper.metadata new file mode 100644 index 0000000..8944e30 --- /dev/null +++ b/.perl-Data-Dumper.metadata @@ -0,0 +1 @@ +487944cc1200db9b698569c2b122bc7be4e1bceb SOURCES/Data-Dumper-2.183.tar.gz diff --git a/SOURCES/Data-Dumper-2.183-Upgrade-to-2.184.patch b/SOURCES/Data-Dumper-2.183-Upgrade-to-2.184.patch new file mode 100644 index 0000000..8cf5e7b --- /dev/null +++ b/SOURCES/Data-Dumper-2.183-Upgrade-to-2.184.patch @@ -0,0 +1,274 @@ +From d3b09ae0076981fb5ef8a979fa387105278a7234 Mon Sep 17 00:00:00 2001 +From: Jitka Plesnikova +Date: Wed, 11 May 2022 11:01:46 +0200 +Subject: [PATCH] Upgrade to 2.184 + +--- + Dumper.pm | 51 +++++++++++++++++++-------------------------------- + Dumper.xs | 10 ++++------ + t/dumper.t | 52 ++++++++++++++++------------------------------------ + 3 files changed, 39 insertions(+), 74 deletions(-) + +diff --git a/Dumper.pm b/Dumper.pm +index 3b1bb75..ba61ffe 100644 +--- a/Dumper.pm ++++ b/Dumper.pm +@@ -29,7 +29,7 @@ our ( $Indent, $Trailingcomma, $Purity, $Pad, $Varname, $Useqq, $Terse, $Freezer + our ( @ISA, @EXPORT, @EXPORT_OK, $VERSION ); + + BEGIN { +- $VERSION = '2.183'; # Don't forget to set version and release ++ $VERSION = '2.184'; # Don't forget to set version and release + # date in POD below! + + @ISA = qw(Exporter); +@@ -740,15 +740,15 @@ my %esc = ( + "\e" => "\\e", + ); + +-my $low_controls = ($IS_ASCII) +- +- # This includes \177, because traditionally it has been +- # output as octal, even though it isn't really a "low" +- # control +- ? qr/[\0-\x1f\177]/ +- +- # EBCDIC low controls. +- : qr/[\0-\x3f]/; ++# The low controls are considered to be everything below SPACE, plus the ++# outlier \c? control (but that wasn't properly in existence in early perls, ++# so reconstruct its value here. This abandons EBCDIC support for this ++# character for perls below 5.8) ++my $low_controls = join "", map { quotemeta chr $_ } 0.. (ord(" ") - 1); ++$low_controls .= ($] < 5.008 || $IS_ASCII) ++ ? "\x7f" ++ : chr utf8::unicode_to_native(0x9F); ++my $low_controls_re = qr/[$low_controls]/; + + # put a string value in double quotes + sub qquote { +@@ -758,19 +758,10 @@ sub qquote { + # This efficiently changes the high ordinal characters to \x{} if the utf8 + # flag is on. On ASCII platforms, the high ordinals are all the + # non-ASCII's. On EBCDIC platforms, we don't include in these the non-ASCII +- # controls whose ordinals are less than SPACE, excluded below by the range +- # \0-\x3f. On ASCII platforms this range just compiles as part of :ascii:. +- # On EBCDIC platforms, there is just one outlier high ordinal control, and +- # it gets output as \x{}. ++ # controls. + my $bytes; { use bytes; $bytes = length } +- s/([^[:ascii:]\0-\x3f])/sprintf("\\x{%x}",ord($1))/ge +- if $bytes > length +- +- # The above doesn't get the EBCDIC outlier high ordinal control when +- # the string is UTF-8 but there are no UTF-8 variant characters in it. +- # We want that to come out as \x{} anyway. We need is_utf8() to do +- # this. +- || (! $IS_ASCII && utf8::is_utf8($_)); ++ s/([^[:ascii:]$low_controls])/sprintf("\\x{%x}",ord($1))/ge ++ if $bytes > length; + + return qq("$_") unless /[[:^print:]]/; # fast exit if only printables + +@@ -779,21 +770,17 @@ sub qquote { + s/([\a\b\t\n\f\r\e])/$esc{$1}/g; + + # no need for 3 digits in escape for octals not followed by a digit. +- s/($low_controls)(?!\d)/'\\'.sprintf('%o',ord($1))/eg; ++ s/($low_controls_re)(?!\d)/'\\'.sprintf('%o',ord($1))/eg; + + # But otherwise use 3 digits +- s/($low_controls)/'\\'.sprintf('%03o',ord($1))/eg; ++ s/($low_controls_re)/'\\'.sprintf('%03o',ord($1))/eg; + + # all but last branch below not supported --BEHAVIOR SUBJECT TO CHANGE-- + my $high = shift || ""; + if ($high eq "iso8859") { # Doesn't escape the Latin1 printables +- if ($IS_ASCII) { +- s/([\200-\240])/'\\'.sprintf('%o',ord($1))/eg; +- } +- else { +- my $high_control = utf8::unicode_to_native(0x9F); +- s/$high_control/sprintf('\\%o',ord($1))/eg; +- } ++ # Could use /u and [:cntrl:] etc, if khw were confident it worked in ++ # early early perls ++ s/([\200-\240])/'\\'.sprintf('%o',ord($1))/eg if $IS_ASCII; + } elsif ($high eq "utf8") { + # Some discussion of what to do here is in + # https://rt.perl.org/Ticket/Display.html?id=113088 +@@ -1461,7 +1448,7 @@ modify it under the same terms as Perl itself. + + =head1 VERSION + +-Version 2.183 ++Version 2.184 + + =head1 SEE ALSO + +diff --git a/Dumper.xs b/Dumper.xs +index 0eaa6c9..8bd6397 100644 +--- a/Dumper.xs ++++ b/Dumper.xs +@@ -287,14 +287,13 @@ esc_q_utf8(pTHX_ SV* sv, const char *src, STRLEN slen, I32 do_utf8, I32 useqq) + * outputs the raw char */ + normal++; + } +- else { /* Is qq, low ordinal, non-printable. Output escape +- * sequences */ ++ else { /* Is qq, non-printable. Output escape sequences */ + if ( k == '\a' || k == '\b' || k == '\t' || k == '\n' || k == '\r' + || k == '\f' || k == ESC_NATIVE) + { + grow += 2; /* 1 char plus backslash */ + } +- else /* The other low ordinals are output as an octal escape ++ else /* The other non-printable controls are output as an octal escape + * sequence */ + if (s + 1 >= send || isDIGIT(*(s+1))) { + /* When the following character is a digit, use 3 octal digits +@@ -341,9 +340,8 @@ esc_q_utf8(pTHX_ SV* sv, const char *src, STRLEN slen, I32 do_utf8, I32 useqq) + } + + /* Here 1) isn't UTF-8; or +- * 2) the current character is ASCII; or +- * 3) it is an EBCDIC platform and is a low ordinal +- * non-ASCII control. ++ * 2) the current character is represented as the same single ++ * byte regardless of the string's UTF-8ness + * In each case the character occupies just one byte */ + k = *(U8*)s; + increment = 1; +diff --git a/t/dumper.t b/t/dumper.t +index 3cd86a6..80b2c8e 100644 +--- a/t/dumper.t ++++ b/t/dumper.t +@@ -77,8 +77,8 @@ sub convert_to_native { + $index = utf8::unicode_to_native(ord eval "\"$2\""); + + # But low hex numbers are always in octal. These are all +- # controls. +- my $format = ($index < ord(" ")) ++ # controls. The outlier \c? control is also in octal. ++ my $format = ($index < ord(" ") || $index == ord("\c?")) + ? "\\%o" + : "\\x{%x}"; + $replacement = sprintf($format, $index); +@@ -1659,8 +1659,8 @@ EOW + # "\\x{41f}", + # qr/\x{8b80}/, + # qr/\x{41f}/, +-# qr/\x{e4}/, +-# '\xE4' ++# qr/\x{b6}/, ++# '\xb6' + #]; + EOW + if ($] lt '5.010001') { +@@ -1671,9 +1671,9 @@ EOW + $want =~ s{/(,?)$}{/u$1}mg; + } + my $want_xs = $want; +- $want_xs =~ s/'\xE4'/"\\x{e4}"/; +- $want_xs =~ s<([^\0-\177])> ge; +- TEST_BOTH(qq(Data::Dumper->Dumpxs([ [qq/\x{41f}/, qr/\x{8b80}/, qr/\x{41f}/, qr/\x{e4}/, "\xE4"] ])), ++ $want_xs =~ s/'\xb6'/"\\x{b6}"/; ++ $want_xs =~ s<([[:^ascii:]])> ge; ++ TEST_BOTH(qq(Data::Dumper->Dumpxs([ [qq/\x{41f}/, qr/\x{8b80}/, qr/\x{41f}/, qr/\x{b6}/, "\xb6"] ])), + "string with Unicode + regexp with Unicode", + $want, $want_xs); + } +@@ -1715,7 +1715,7 @@ EOW + # qr/ \x{203d}\\/ /, + # qr/ \\\x{203d}\\/ /, + # qr/ \\\x{203d}$bs:\\/ /, +-# '\xA3' ++# '\xB6' + #]; + EOW + if ($] lt '5.010001') { +@@ -1726,9 +1726,9 @@ EOW + $want =~ s{/(,?)$}{/u$1}mg; + } + my $want_xs = $want; +- $want_xs =~ s/'\x{A3}'/"\\x{a3}"/; ++ $want_xs =~ s/'\x{B6}'/"\\x{b6}"/; + $want_xs =~ s/\x{203D}/\\x{203d}/g; +- TEST_BOTH(qq(Data::Dumper->Dumpxs([ [ '\x{2e18}', qr! \x{203d}/ !, qr! \\\x{203d}/ !, qr! \\\x{203d}$bs:/ !, "\xa3"] ])), ++ TEST_BOTH(qq(Data::Dumper->Dumpxs([ [ '\x{2e18}', qr! \x{203d}/ !, qr! \\\x{203d}/ !, qr! \\\x{203d}$bs:/ !, "\xb6"] ])), + "github #18614, github #18764, perl #58608 corner cases", + $want, $want_xs); + } +@@ -1743,13 +1743,13 @@ EOW + # qr/^\$/, + # qr/${dollar}foo/, + # qr/\\\$foo/, +-# qr/$dollar \x{A3} /u, ++# qr/$dollar \x{B6} /u, + # qr/$dollar \x{203d} /u, + # qr/\\\$ \x{203d} /u, + # qr/\\\\$dollar \x{203d} /u, + # qr/ \$| \x{203d} /u, + # qr/ (\$) \x{203d} /u, +-# '\xA3' ++# '\xB6' + #]; + EOW + if ($] lt '5.014') { +@@ -1760,8 +1760,8 @@ EOW + $want =~ s!/,!)/,!g; + } + my $want_xs = $want; +- $want_xs =~ s/'\x{A3}'/"\\x{a3}"/; +- $want_xs =~ s/\x{A3}/\\x{a3}/; ++ $want_xs =~ s/'\x{B6}'/"\\x{b6}"/; ++ $want_xs =~ s/\x{B6}/\\x{b6}/; + $want_xs =~ s/\x{203D}/\\x{203d}/g; + my $have = <<"EOT"; + Data::Dumper->Dumpxs([ [ +@@ -1770,13 +1770,13 @@ Data::Dumper->Dumpxs([ [ + qr'^\$', + qr'\$foo', + qr/\\\$foo/, +- qr'\$ \x{A3} ', ++ qr'\$ \x{B6} ', + qr'\$ \x{203d} ', + qr/\\\$ \x{203d} /, + qr'\\\\\$ \x{203d} ', + qr/ \$| \x{203d} /, + qr/ (\$) \x{203d} /, +- '\xA3' ++ '\xB6' + ] ]); + EOT + TEST_BOTH($have, "CPAN #84569", $want, $want_xs); +@@ -1808,26 +1808,6 @@ EOW + "name of code in *foo", + $want); + } +-############# +- +-{ +- # There is special code to handle the single control that in EBCDIC is +- # not in the block with all the other controls, when it is UTF-8 and +- # there are no variants in it (All controls in EBCDIC are invariant.) +- # This tests that. There is no harm in testing this works on ASCII, +- # and is better to not have split code paths. +- my $outlier = chr utf8::unicode_to_native(0x9F); +- my $outlier_hex = sprintf "%x", ord $outlier; +- my $want = < +Date: Tue, 16 May 2023 12:56:43 +0200 +Subject: [PATCH] Upgrade to 2.188 + +--- + Dumper.pm | 15 +++++++++++---- + Dumper.xs | 25 +++++++++++++++++-------- + Makefile.PL | 1 - + t/dumper.t | 20 ++++++++++++++++++++ + 4 files changed, 48 insertions(+), 13 deletions(-) + +diff --git a/Dumper.pm b/Dumper.pm +index ba61ffe..bb6d3ca 100644 +--- a/Dumper.pm ++++ b/Dumper.pm +@@ -18,6 +18,7 @@ use 5.008_001; + require Exporter; + + use constant IS_PRE_516_PERL => $] < 5.016; ++use constant SUPPORTS_CORE_BOOLS => defined &builtin::is_bool; + + use Carp (); + +@@ -29,7 +30,7 @@ our ( $Indent, $Trailingcomma, $Purity, $Pad, $Varname, $Useqq, $Terse, $Freezer + our ( @ISA, @EXPORT, @EXPORT_OK, $VERSION ); + + BEGIN { +- $VERSION = '2.184'; # Don't forget to set version and release ++ $VERSION = '2.188'; # Don't forget to set version and release + # date in POD below! + + @ISA = qw(Exporter); +@@ -551,6 +552,12 @@ sub _dump { + elsif (!defined($val)) { + $out .= "undef"; + } ++ elsif (SUPPORTS_CORE_BOOLS && do { ++ BEGIN { SUPPORTS_CORE_BOOLS and warnings->unimport("experimental::builtin") } ++ builtin::is_bool($val) ++ }) { ++ $out .= $val ? '!!1' : '!!0'; ++ } + # This calls the XSUB _vstring (if the XS code is loaded). I'm not *sure* if + # if belongs in the "Pure Perl" implementation. It sort of depends on what + # was meant by "Pure Perl", as this subroutine already relies Scalar::Util +@@ -859,7 +866,7 @@ Data::Dumper - stringified perl data structures, suitable for both printing and + } + + # OO usage +- $d = Data::Dumper->new([$foo, $bar], [qw(foo *ary)]); ++ my $d = Data::Dumper->new([$foo, $bar], [qw(foo *ary)]); + ... + print $d->Dump; + ... +@@ -884,7 +891,7 @@ to substructures within C<$VAR>I will be appropriately labeled using arrow + notation. You can specify names for individual values to be dumped if you + use the C method, or you can change the default C<$VAR> prefix to + something else. See C<$Data::Dumper::Varname> and C<$Data::Dumper::Terse> +-below. ++in L below. + + The default output of self-referential structures can be Ced, but the + nested references to C<$VAR>I will be undefined, since a recursive +@@ -1448,7 +1455,7 @@ modify it under the same terms as Perl itself. + + =head1 VERSION + +-Version 2.184 ++Version 2.188 + + =head1 SEE ALSO + +diff --git a/Dumper.xs b/Dumper.xs +index 8bd6397..4d54ba1 100644 +--- a/Dumper.xs ++++ b/Dumper.xs +@@ -2,13 +2,11 @@ + #include "EXTERN.h" + #include "perl.h" + #include "XSUB.h" +-#ifdef USE_PPPORT_H +-# define NEED_my_snprintf +-# define NEED_my_sprintf +-# define NEED_sv_2pv_flags +-# define NEED_utf8_to_uvchr_buf +-# include "ppport.h" +-#endif ++#define NEED_my_snprintf ++#define NEED_my_sprintf ++#define NEED_sv_2pv_flags ++#define NEED_utf8_to_uvchr_buf ++#include "ppport.h" + + #ifndef strlcpy + # ifdef my_strlcpy +@@ -1279,6 +1277,17 @@ DD_dump(pTHX_ SV *val, const char *name, STRLEN namelen, SV *retval, HV *seenhv, + } + } + ++#ifdef SvIsBOOL ++ if (SvIsBOOL(val)) { ++ if (SvTRUE(val)) { ++ sv_catpvs(retval, "!!1"); ++ } ++ else { ++ sv_catpvs(retval, "!!0"); ++ } ++ } ++ else ++#endif + if (DD_is_integer(val)) { + STRLEN len; + if (SvIsUV(val)) +@@ -1315,7 +1324,7 @@ DD_dump(pTHX_ SV *val, const char *name, STRLEN namelen, SV *retval, HV *seenhv, + SvCUR_set(retval, SvCUR(retval)+2); + i = 3 + esc_q_utf8(aTHX_ retval, c, i, + #ifdef GvNAMEUTF8 +- !!GvNAMEUTF8(val), style->useqq ++ cBOOL(GvNAMEUTF8(val)), style->useqq + #else + 0, style->useqq || globname_supra_ascii(c, i) + #endif +diff --git a/Makefile.PL b/Makefile.PL +index afbdba6..2920b46 100644 +--- a/Makefile.PL ++++ b/Makefile.PL +@@ -18,6 +18,5 @@ WriteMakefile( + VERSION_FROM => 'Dumper.pm', + ABSTRACT_FROM => 'Dumper.pm', + $] <= 5.011000 ? ( INSTALLDIRS => 'perl' ) : (), +- ((grep { $_ eq 'PERL_CORE=1' } @ARGV) ? () : ('DEFINE' => '-DUSE_PPPORT_H')), + @extra, + ); +diff --git a/t/dumper.t b/t/dumper.t +index 80b2c8e..55a997c 100644 +--- a/t/dumper.t ++++ b/t/dumper.t +@@ -1522,6 +1522,26 @@ EOT + $want); + } + ++############# ++{ ++ if (!Data::Dumper::SUPPORTS_CORE_BOOLS) { ++ SKIP_BOTH("Core booleans not supported on older perls"); ++ last; ++ } ++ my $want = <<'EOT'; ++#$VAR1 = [ ++# !!1, ++# !!0 ++#]; ++EOT ++ ++ $foo = [ !!1, !!0 ]; ++ TEST_BOTH(q(Data::Dumper::DumperX($foo)), ++ 'Booleans', ++ $want); ++} ++ ++ + ############# + { + # If XS cannot load, the pure-Perl version cannot deparse vstrings with +-- +2.40.1 + diff --git a/SOURCES/Data-Dumper-2.188-Upgrade-to-2.189.patch b/SOURCES/Data-Dumper-2.188-Upgrade-to-2.189.patch new file mode 100644 index 0000000..32e1d78 --- /dev/null +++ b/SOURCES/Data-Dumper-2.188-Upgrade-to-2.189.patch @@ -0,0 +1,43 @@ +From 06f67e3ce7e18b23f325851ba04200e4dc9642e3 Mon Sep 17 00:00:00 2001 +From: Jitka Plesnikova +Date: Tue, 7 May 2024 15:02:41 +0200 +Subject: [PATCH] Upgrade to 2.189 + +--- + Dumper.pm | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/Dumper.pm b/Dumper.pm +index bb6d3ca..ca965eb 100644 +--- a/Dumper.pm ++++ b/Dumper.pm +@@ -30,7 +30,7 @@ our ( $Indent, $Trailingcomma, $Purity, $Pad, $Varname, $Useqq, $Terse, $Freezer + our ( @ISA, @EXPORT, @EXPORT_OK, $VERSION ); + + BEGIN { +- $VERSION = '2.188'; # Don't forget to set version and release ++ $VERSION = '2.189'; # Don't forget to set version and release + # date in POD below! + + @ISA = qw(Exporter); +@@ -924,7 +924,7 @@ for details. + Returns a newly created C object. The first argument is an + anonymous array of values to be dumped. The optional second argument is an + anonymous array of names for the values. The names need not have a leading +-C<$> sign, and must be comprised of alphanumeric characters. You can begin ++C<$> sign, and must be composed of alphanumeric characters. You can begin + a name with a C<*> to specify that the dereferenced type must be dumped + instead of the reference itself, for ARRAY and HASH references. + +@@ -1455,7 +1455,7 @@ modify it under the same terms as Perl itself. + + =head1 VERSION + +-Version 2.188 ++Version 2.189 + + =head1 SEE ALSO + +-- +2.45.0 + diff --git a/SPECS/perl-Data-Dumper.spec b/SPECS/perl-Data-Dumper.spec new file mode 100644 index 0000000..0aa3788 --- /dev/null +++ b/SPECS/perl-Data-Dumper.spec @@ -0,0 +1,378 @@ +%global base_version 2.183 + +Name: perl-Data-Dumper +Version: 2.189 +Release: 511%{?dist} +Summary: Stringify perl data structures, suitable for printing and eval +License: GPL-1.0-or-later OR Artistic-1.0-Perl +URL: https://metacpan.org/release/Data-Dumper +Source0: https://cpan.metacpan.org/authors/id/N/NW/NWCLARK/Data-Dumper-%{base_version}.tar.gz +# Upgrade to 2.184 based on perl-5.35.11 +Patch0: Data-Dumper-2.183-Upgrade-to-2.184.patch +# Upgrade to 2.188 based on perl-5.37.11 +Patch1: Data-Dumper-2.184-Upgrade-to-2.188.patch +# Upgrade to 2.189 based on perl-5.40.0-RC1 +Patch2: Data-Dumper-2.188-Upgrade-to-2.189.patch +BuildRequires: coreutils +BuildRequires: findutils +BuildRequires: gcc +BuildRequires: make +BuildRequires: perl-devel +BuildRequires: perl-generators +BuildRequires: perl-interpreter +BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 +BuildRequires: perl(File::Copy) +BuildRequires: perl(strict) +BuildRequires: perl(warnings) +# perl-Test-Simple is in cycle with perl-Data-Dumper +%if !%{defined perl_bootstrap} +# Run-time: +BuildRequires: perl(B::Deparse) +BuildRequires: perl(bytes) +BuildRequires: perl(Carp) +BuildRequires: perl(constant) +BuildRequires: perl(Exporter) +BuildRequires: perl(Scalar::Util) +BuildRequires: perl(XSLoader) +# Tests only: +BuildRequires: perl(Config) +BuildRequires: perl(if) +BuildRequires: perl(lib) +BuildRequires: perl(overload) +BuildRequires: perl(strict) +BuildRequires: perl(Test::More) >= 0.98 +BuildRequires: perl(vars) +# Optional tests: +BuildRequires: perl(Encode) +%endif +Requires: perl(B::Deparse) +Requires: perl(bytes) +Requires: perl(Scalar::Util) +Requires: perl(XSLoader) + +%{?perl_default_filter} + +# Filter modules bundled for tests +%global __provides_exclude_from %{?__provides_exclude_from:%__provides_exclude_from|}^%{_libexecdir} +%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}perl\\(Testing\\) + +%description +Given a list of scalars or reference variables, writes out their contents +in perl syntax. The references can also be objects. The content of each +variable is output in a single Perl statement. Handles self-referential +structures correctly. + +%package tests +Summary: Tests for %{name} +Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release} +Requires: perl(Encode) +Requires: perl-Test-Harness + +%description tests +Tests from %{name}. Execute them +with "%{_libexecdir}/%{name}/test". + +%prep +%setup -q -n Data-Dumper-%{base_version} +%patch -P0 -p1 +%patch -P1 -p1 +%patch -P2 -p1 + +# Help file to recognise the Perl scripts +for F in t/*.t; do + perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!.*perl\b}{$Config{startperl}}' "$F" + chmod +x "$F" +done + +%build +perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 OPTIMIZE="$RPM_OPT_FLAGS" +%{make_build} + +%install +%{make_install} +find %{buildroot} -type f -name '*.bs' -size 0 -delete +%{_fixperms} %{buildroot}/* + +# Install tests +mkdir -p %{buildroot}%{_libexecdir}/%{name} +cp -a t %{buildroot}%{_libexecdir}/%{name} +cat > %{buildroot}%{_libexecdir}/%{name}/test << 'EOF' +#!/bin/sh +cd %{_libexecdir}/%{name} && exec prove -I . -j "$(getconf _NPROCESSORS_ONLN)" +EOF +chmod +x %{buildroot}%{_libexecdir}/%{name}/test + +%check +%if !%{defined perl_bootstrap} +export HARNESS_OPTIONS=j$(perl -e 'if ($ARGV[0] =~ /.*-j([0-9][0-9]*).*/) {print $1} else {print 1}' -- '%{?_smp_mflags}') +make test +%endif + +%files +%doc Changes Todo +%{perl_vendorarch}/auto/Data* +%{perl_vendorarch}/Data* +%{_mandir}/man3/Data::Dumper* + +%files tests +%{_libexecdir}/%{name} + +%changelog +* Tue Nov 26 2024 MSVSphere Packaging Team - 2.189-511 +- Rebuilt for MSVSphere 10 + +* Fri Aug 09 2024 Jitka Plesnikova - 2.189-511 +- Perl 5.40 re-rebuild of bootstrapped packages + +* Thu Jul 18 2024 Jitka Plesnikova - 2.189-510 +- Increase release to favour standalone package + +* Wed Jul 17 2024 Jitka Plesnikova - 2.189-504 +- Upgrade to 2.189 based on perl-5.40.0-RC1 + +* Mon Jun 24 2024 Troy Dawson - 2.188-504 +- Bump release for June 2024 mass rebuild + +* Thu Jan 25 2024 Fedora Release Engineering - 2.188-503 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Sun Jan 21 2024 Fedora Release Engineering - 2.188-502 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Thu Jul 20 2023 Fedora Release Engineering - 2.188-501 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + +* Wed Jul 12 2023 Jitka Plesnikova - 2.188-500 +- Perl 5.38 re-rebuild of bootstrapped packages + +* Tue Jul 11 2023 Jitka Plesnikova - 2.188-499 +- Increase release to favour standalone package + +* Tue May 16 2023 Jitka Plesnikova - 2.188-1 +- Upgrade to 2.188 based on perl-5.37.11 + +* Fri Jan 20 2023 Fedora Release Engineering - 2.184-491 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Fri Jul 22 2022 Fedora Release Engineering - 2.184-490 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Fri Jun 03 2022 Jitka Plesnikova - 2.184-489 +- Perl 5.36 re-rebuild of bootstrapped packages + +* Mon May 30 2022 Jitka Plesnikova - 2.184-488 +- Increase release to favour standalone package + +* Wed May 11 2022 Jitka Plesnikova - 2.184-1 +- Upgrade to 2.184 based on perl-5.35.11 + +* Fri Jan 21 2022 Fedora Release Engineering - 2.183-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Thu Jul 22 2021 Fedora Release Engineering - 2.183-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Thu Jul 08 2021 Jitka Plesnikova - 2.183-1 +- 2.183 bump + +* Thu Jul 01 2021 Jitka Plesnikova - 2.182-1 +- 2.182 bump + +* Mon May 31 2021 Jitka Plesnikova - 2.181-1 +- 2.181 bump + +* Mon May 24 2021 Jitka Plesnikova - 2.180-4 +- Perl 5.34 re-rebuild of bootstrapped packages + +* Mon May 24 2021 Jitka Plesnikova - 2.180-3 +- Perl 5.34 re-rebuild of bootstrapped packages + +* Fri May 21 2021 Jitka Plesnikova - 2.180-2 +- Perl 5.34 rebuild + +* Mon May 17 2021 Jitka Plesnikova - 2.180-1 +- 2.180 bump +- Package tests + +* Wed Jan 27 2021 Fedora Release Engineering - 2.174-460 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Thu Aug 20 2020 Petr Pisar - 2.174-459 +- Fix a memory leak when a magic throws an exception + +* Tue Jul 28 2020 Fedora Release Engineering - 2.174-458 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Fri Jun 26 2020 Jitka Plesnikova - 2.174-457 +- Perl 5.32 re-rebuild of bootstrapped packages + +* Mon Jun 22 2020 Jitka Plesnikova - 2.174-456 +- Increase release to favour standalone package + +* Tue Feb 04 2020 Petr Pisar - 2.174-443 +- Modernize the spec file + +* Tue Feb 04 2020 Tom Stellard - 2.174-442 +- Use make_build macro +- https://docs.fedoraproject.org/en-US/packaging-guidelines/#_parallel_make + +* Wed Jan 29 2020 Fedora Release Engineering - 2.174-441 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Fri Jul 26 2019 Fedora Release Engineering - 2.174-440 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Sun Jun 02 2019 Jitka Plesnikova - 2.174-439 +- Perl 5.30 re-rebuild of bootstrapped packages + +* Thu May 30 2019 Jitka Plesnikova - 2.174-438 +- Increase release to favour standalone package + +* Fri Apr 26 2019 Jitka Plesnikova - 2.174-1 +- Update version to 2.174 as provided in perl-5.29.10 + +* Wed Apr 03 2019 Petr Pisar - 2.173-3 +- Fix a memory leak when croaking about a too deep recursion + +* Fri Feb 01 2019 Fedora Release Engineering - 2.173-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Mon Nov 12 2018 Petr Pisar - 2.173-1 +- 2.173 bump + +* Thu Sep 20 2018 Jitka Plesnikova - 2.172-1 +- 2.172 bump + +* Fri Jul 13 2018 Fedora Release Engineering - 2.170-418 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Sat Jun 30 2018 Jitka Plesnikova - 2.170-417 +- Perl 5.28 re-rebuild of bootstrapped packages + +* Wed Jun 27 2018 Jitka Plesnikova - 2.170-416 +- Increase release to favour standalone package + +* Wed May 23 2018 Jitka Plesnikova - 2.170-1 +- Upgrade to 2.170 as provided in perl-5.28.0-RC1 + +* Thu Feb 08 2018 Fedora Release Engineering - 2.167-399 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Thu Jan 11 2018 Petr Pisar - 2.167-398 +- Fix postentry for quoted glob (bug #1532524) + +* Tue Dec 05 2017 Petr Pisar - 2.167-397 +- Fix quoting glob names (RT#119831) + +* Thu Aug 03 2017 Fedora Release Engineering - 2.167-396 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + +* Thu Jul 27 2017 Fedora Release Engineering - 2.167-395 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Wed Jun 07 2017 Jitka Plesnikova - 2.167-394 +- Perl 5.26 re-rebuild of bootstrapped packages + +* Sat Jun 03 2017 Jitka Plesnikova - 2.167-393 +- Perl 5.26 rebuild + +* Thu May 11 2017 Petr Pisar - 2.167-1 +- Upgrade to 2.167 as provided in perl-5.25.12 + +* Sat Feb 11 2017 Fedora Release Engineering - 2.161-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + +* Tue Jul 12 2016 Petr Pisar - 2.161-1 +- 1.161 bump + +* Wed May 18 2016 Jitka Plesnikova - 2.160-366 +- Perl 5.24 re-rebuild of bootstrapped packages + +* Sat May 14 2016 Jitka Plesnikova - 2.160-365 +- Increase release to favour standalone package + +* Wed May 11 2016 Jitka Plesnikova - 2.160-1 +- 2.160 bump in order to dual-live with perl 5.24 + +* Thu Feb 04 2016 Fedora Release Engineering - 2.158-348 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Thu Jun 18 2015 Fedora Release Engineering - 2.158-347 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Wed Jun 10 2015 Jitka Plesnikova - 2.158-346 +- Perl 5.22 re-rebuild of bootstrapped packages + +* Thu Jun 04 2015 Jitka Plesnikova - 2.158-345 +- Increase release to favour standalone package + +* Wed Jun 03 2015 Jitka Plesnikova - 2.158-2 +- Perl 5.22 rebuild + +* Wed May 06 2015 Petr Pisar - 2.158-1 +- 2.158 bump in order to dual-live with perl 5.22 + +* Fri Sep 19 2014 Petr Pisar - 2.154-1 +- 2.154 bump (fixes CVE-2014-4330 (limit recursion when dumping deep data + structures)) + +* Sun Sep 07 2014 Jitka Plesnikova - 2.151-311 +- Perl 5.20 re-rebuild of bootstrapped packages + +* Wed Sep 03 2014 Jitka Plesnikova - 2.151-310 +- Increase release to favour standalone package + +* Tue Aug 26 2014 Jitka Plesnikova - 2.151-4 +- Perl 5.20 rebuild + +* Sun Aug 17 2014 Fedora Release Engineering - 2.151-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Sat Jun 07 2014 Fedora Release Engineering - 2.151-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Mon Mar 10 2014 Petr Pisar - 2.151-1 +- 2.151 bump + +* Wed Aug 14 2013 Jitka Plesnikova - 2.145-292 +- Perl 5.18 re-rebuild of bootstrapped packages + +* Sat Aug 03 2013 Fedora Release Engineering - 2.145-291 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Mon Jul 15 2013 Petr Pisar - 2.145-290 +- Increase release to favour standalone package + +* Fri Jul 12 2013 Petr Pisar - 2.145-2 +- Perl 5.18 rebuild + +* Mon Mar 18 2013 Petr Pisar - 2.145-1 +- 2.145 bump + +* Thu Feb 28 2013 Petr Pisar - 2.143-1 +- 2.143 bump + +* Thu Feb 14 2013 Fedora Release Engineering - 2.139-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Wed Dec 12 2012 Petr Pisar - 2.139-1 +- 2.139 bump + +* Fri Oct 05 2012 Petr Pisar - 2.136-1 +- 2.136 bump + +* Fri Aug 24 2012 Petr Pisar - 2.135.07-241 +- Disable tests on bootstrap + +* Mon Aug 13 2012 Marcela Mašláňová - 2.135.07-240 +- update the version to override the module from perl.srpm +- bump release to override sub-package from perl.spec + +* Fri Jul 20 2012 Fedora Release Engineering - 2.131-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Wed Jun 06 2012 Petr Pisar - 2.131-2 +- Perl 5.16 rebuild + +* Tue Apr 10 2012 Petr Pisar 2.131-1 +- Specfile autogenerated by cpanspec 1.78.