summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff')
-rw-r--r--meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff119
1 files changed, 119 insertions, 0 deletions
diff --git a/meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff b/meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff
new file mode 100644
index 0000000..5a1ad99
--- /dev/null
+++ b/meta/recipes-devtools/perl/perl-5.14.3/debian/prefix_changes.diff
@@ -0,0 +1,119 @@
1Upstream-Status:Inappropriate [debian patches]
2From 148e2717682ce8c65475ffdeea84b3cdd1ab1649 Mon Sep 17 00:00:00 2001
3From: Brendan O'Dea <bod@debian.org>
4Date: Tue, 8 Mar 2005 19:30:38 +1100
5Subject: Fiddle with *PREFIX and variables written to the makefile
6
7Fiddle with *PREFIX and variables written to the makefile so that
8install directories may be changed when make is run by passing
9PREFIX= to the "make install" command (used when packaging
10modules).
11
12Patch-Name: debian/prefix_changes.diff
13---
14 cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm | 12 ++++++------
15 cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm | 3 +--
16 cpan/ExtUtils-MakeMaker/t/INST.t | 4 +---
17 cpan/ExtUtils-MakeMaker/t/INST_PREFIX.t | 10 +++++-----
18 4 files changed, 13 insertions(+), 16 deletions(-)
19
20diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm
21index a38f274..93d3fe9 100644
22--- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm
23+++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm
24@@ -701,8 +701,6 @@ all POD files in MAN1PODS and MAN3PODS.
25 sub manifypods_target {
26 my($self) = shift;
27
28- my $man1pods = '';
29- my $man3pods = '';
30 my $dependencies = '';
31
32 # populate manXpods & dependencies:
33@@ -718,7 +716,7 @@ END
34 foreach my $section (qw(1 3)) {
35 my $pods = $self->{"MAN${section}PODS"};
36 push @man_cmds, $self->split_command(<<CMD, %$pods);
37- \$(NOECHO) \$(POD2MAN) --section=$section --perm_rw=\$(PERM_RW)
38+ \$(NOECHO) \$(POD2MAN) --section=\$(MAN${section}EXT) --perm_rw=\$(PERM_RW)
39 CMD
40 }
41
42@@ -1521,9 +1519,11 @@ sub init_INSTALL_from_PREFIX {
43 $self->{SITEPREFIX} ||= $sprefix;
44 $self->{VENDORPREFIX} ||= $vprefix;
45
46- # Lots of MM extension authors like to use $(PREFIX) so we
47- # put something sensible in there no matter what.
48- $self->{PREFIX} = '$('.uc $self->{INSTALLDIRS}.'PREFIX)';
49+ my $p = $self->{PREFIX} = $self->{PERLPREFIX};
50+ for my $t (qw/PERL SITE VENDOR/)
51+ {
52+ $self->{"${t}PREFIX"} =~ s!^\Q$p\E(?=/|$)!\$(PREFIX)!;
53+ }
54 }
55
56 my $arch = $Config{archname};
57diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
58index a16e2d0..c308c49 100644
59--- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
60+++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
61@@ -2981,8 +2981,7 @@ sub prefixify {
62 print STDERR " prefixify $var => $path\n" if $Verbose >= 2;
63 print STDERR " from $sprefix to $rprefix\n" if $Verbose >= 2;
64
65- if( $self->{ARGS}{PREFIX} &&
66- $path !~ s{^\Q$sprefix\E\b}{$rprefix}s )
67+ if( $path !~ s{^\Q$sprefix\E\b}{$rprefix}s && $self->{ARGS}{PREFIX} )
68 {
69
70 print STDERR " cannot prefix, using default.\n" if $Verbose >= 2;
71diff --git a/cpan/ExtUtils-MakeMaker/t/INST.t b/cpan/ExtUtils-MakeMaker/t/INST.t
72index 6aac294..28294f2 100644
73--- a/cpan/ExtUtils-MakeMaker/t/INST.t
74+++ b/cpan/ExtUtils-MakeMaker/t/INST.t
75@@ -61,9 +61,7 @@ isa_ok( $mm, 'ExtUtils::MakeMaker' );
76 is( $mm->{NAME}, 'Big::Dummy', 'NAME' );
77 is( $mm->{VERSION}, 0.01, 'VERSION' );
78
79-my $config_prefix = $Config{installprefixexp} || $Config{installprefix} ||
80- $Config{prefixexp} || $Config{prefix};
81-is( $mm->{PERLPREFIX}, $config_prefix, 'PERLPREFIX' );
82+is( $mm->{PERLPREFIX}, '$(PREFIX)', 'PERLPREFIX' );
83
84 is( !!$mm->{PERL_CORE}, !!$ENV{PERL_CORE}, 'PERL_CORE' );
85
86diff --git a/cpan/ExtUtils-MakeMaker/t/INST_PREFIX.t b/cpan/ExtUtils-MakeMaker/t/INST_PREFIX.t
87index fbb18a3..8987569 100644
88--- a/cpan/ExtUtils-MakeMaker/t/INST_PREFIX.t
89+++ b/cpan/ExtUtils-MakeMaker/t/INST_PREFIX.t
90@@ -10,7 +10,7 @@ BEGIN {
91 }
92
93 use strict;
94-use Test::More tests => 52;
95+use Test::More tests => 47;
96 use MakeMaker::Test::Utils;
97 use MakeMaker::Test::Setup::BFD;
98 use ExtUtils::MakeMaker;
99@@ -58,16 +58,16 @@ like( $stdout->read, qr{
100 Writing\ MYMETA.yml\n
101 }x );
102
103-is( $mm->{PREFIX}, '$(SITEPREFIX)', 'PREFIX set based on INSTALLDIRS' );
104+#is( $mm->{PREFIX}, '$(SITEPREFIX)', 'PREFIX set based on INSTALLDIRS' );
105
106 isa_ok( $mm, 'ExtUtils::MakeMaker' );
107
108 is( $mm->{NAME}, 'Big::Dummy', 'NAME' );
109 is( $mm->{VERSION}, 0.01, 'VERSION' );
110
111-foreach my $prefix (qw(PREFIX PERLPREFIX SITEPREFIX VENDORPREFIX)) {
112- unlike( $mm->{$prefix}, qr/\$\(PREFIX\)/ );
113-}
114+#foreach my $prefix (qw(PREFIX PERLPREFIX SITEPREFIX VENDORPREFIX)) {
115+# unlike( $mm->{$prefix}, qr/\$\(PREFIX\)/ );
116+#}
117
118
119 my $PREFIX = File::Spec->catdir('foo', 'bar');