diff options
author | 2017-10-08 08:13:18 +1300 | |
---|---|---|
committer | 2017-10-08 08:13:46 +1300 | |
commit | 04fb4184cf25f90f8390454c48ff3cdcd9d71881 (patch) | |
tree | 98d296570b3a96e107e6eaedda8c9e5958f12236 /dev-perl/Devel-NYTProf | |
parent | net-misc/memcached: cleanup (diff) | |
download | gentoo-04fb4184cf25f90f8390454c48ff3cdcd9d71881.tar.gz gentoo-04fb4184cf25f90f8390454c48ff3cdcd9d71881.tar.bz2 gentoo-04fb4184cf25f90f8390454c48ff3cdcd9d71881.zip |
dev-perl/Devel-NYTProf: Fix test failure without '.' in @INC bug #615734
Closes: https://bugs.gentoo.org/615734
Package-Manager: Portage-2.3.8, Repoman-2.3.3
Diffstat (limited to 'dev-perl/Devel-NYTProf')
-rw-r--r-- | dev-perl/Devel-NYTProf/Devel-NYTProf-6.40.0.ebuild | 4 | ||||
-rw-r--r-- | dev-perl/Devel-NYTProf/files/Devel-NYTProf-6.40.0-perl526.patch | 41 |
2 files changed, 43 insertions, 2 deletions
diff --git a/dev-perl/Devel-NYTProf/Devel-NYTProf-6.40.0.ebuild b/dev-perl/Devel-NYTProf/Devel-NYTProf-6.40.0.ebuild index c14b6b0b04c7..ca15e9d531fa 100644 --- a/dev-perl/Devel-NYTProf/Devel-NYTProf-6.40.0.ebuild +++ b/dev-perl/Devel-NYTProf/Devel-NYTProf-6.40.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2016 Gentoo Foundation +# Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -29,7 +29,7 @@ DEPEND="${RDEPEND} >=dev-perl/Test-Differences-0.60.0 ) " - +PATCHES=( "${FILESDIR}/${P}-perl526.patch" ) src_test() { perl_rm_files t/90-pod.t t/91-pod_coverage.t t/92-file_port.t \ t/71-moose.t t/72-autodie.t t/68-hashline.t diff --git a/dev-perl/Devel-NYTProf/files/Devel-NYTProf-6.40.0-perl526.patch b/dev-perl/Devel-NYTProf/files/Devel-NYTProf-6.40.0-perl526.patch new file mode 100644 index 000000000000..cd81f120dddb --- /dev/null +++ b/dev-perl/Devel-NYTProf/files/Devel-NYTProf-6.40.0-perl526.patch @@ -0,0 +1,41 @@ +From 461055d041e0e08f5fe851461db42ea7121fa39f Mon Sep 17 00:00:00 2001 +From: Kent Fredric <kentnl@gentoo.org> +Date: Sun, 8 Oct 2017 07:44:14 +1300 +Subject: Fix test failures on Perl 5.26 w/ PERL_USE_UNSAFE_INC=0 + +Perl 5.26+ removes '.' from the default @INC, and this breaks the +mechanism internally where @INC-prefixes are stripped from fid_fileinfo +names ( in ::FileInfo.pm ). + +This breaks tests due to the sample 'rdt' files expecting single-token +comparators relative to 't/', instead getting a fully qualified path in +the "got" side of the test. + +This remedies this by ensuring a fully-qualified path to "t/" is in +@INC for the aforementioned prefix-stripper to pick-up on. + +Bug: https://github.com/timbunce/devel-nytprof/issues/108 +Bug: https://bugs.gentoo.org/615734 +Bug: https://github.com/timbunce/devel-nytprof/pull/112 +--- + t/lib/NYTProfTest.pm | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/t/lib/NYTProfTest.pm b/t/lib/NYTProfTest.pm +index 9c29627..7fb5381 100644 +--- a/t/lib/NYTProfTest.pm ++++ b/t/lib/NYTProfTest.pm +@@ -69,6 +69,10 @@ my $text_extn_info = { + pf => { order => 50, tests => 2, }, + }; + ++# having t/* in @INC is necessary for prefix-stripping ++# to reduce test-file names down to the single tokens ++# that are used in the comparison-output files. ++unshift @INC, File::Spec->rel2abs('./t') if -d 't'; + chdir('t') if -d 't'; + + if (-d '../blib') { +-- +2.14.1 + |