From: Michael Tremer Date: Fri, 1 Oct 2010 14:12:44 +0000 (+0200) Subject: perl: Make this package more in a redhat style. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cdd4579c323672b6d121eb4ff4829f51b8743d6d;p=ipfire-3.x.git perl: Make this package more in a redhat style. --- diff --git a/pkgs/core/perl/patches/perl-5.10.1-libresolv.patch b/pkgs/core/perl/patches/perl-5.10.0-libresolv.patch similarity index 100% rename from pkgs/core/perl/patches/perl-5.10.1-libresolv.patch rename to pkgs/core/perl/patches/perl-5.10.0-libresolv.patch diff --git a/pkgs/core/perl/patches/perl-5.8.0-libdir64.patch b/pkgs/core/perl/patches/perl-5.8.0-libdir64.patch new file mode 100644 index 000000000..0ab67a076 --- /dev/null +++ b/pkgs/core/perl/patches/perl-5.8.0-libdir64.patch @@ -0,0 +1,46 @@ +--- perl-5.8.0/Configure.orig 2002-09-09 11:31:19.000000000 -0400 ++++ perl-5.8.0/Configure 2002-09-09 11:40:37.000000000 -0400 +@@ -6458,8 +6458,8 @@ + : Reproduce behavior of 5.005 and earlier, maybe drop that in 5.7. + case "$installstyle" in + '') case "$prefix" in +- *perl*) dflt='lib';; +- *) dflt='lib/perl5' ;; ++ *perl*) dflt='lib64';; ++ *) dflt='lib64/perl5' ;; + esac + ;; + *) dflt="$installstyle" ;; +@@ -6475,8 +6475,8 @@ + : /opt/perl/lib/perl5... would be redundant. + : The default "style" setting is made in installstyle.U + case "$installstyle" in +-*lib/perl5*) set dflt privlib lib/$package/$version ;; +-*) set dflt privlib lib/$version ;; ++*lib64/perl5*) set dflt privlib lib64/$package/$version ;; ++*) set dflt privlib lib64/$version ;; + esac + eval $prefixit + $cat <_PRINT_PREREQ; +- } ++ } ++ ++ # USE_MM_LD_RUN_PATH - another RedHatism to disable automatic RPATH generation ++ if ( ( ! $self->{USE_MM_LD_RUN_PATH} ) ++ &&( ("@ARGV" =~ /\bUSE_MM_LD_RUN_PATH(=([01]))?\b/) ++ ||( exists( $ENV{USE_MM_LD_RUN_PATH} ) ++ &&( $ENV{USE_MM_LD_RUN_PATH} =~ /([01])?$/ ) ++ ) ++ ) ++ ) ++ { ++ my $v = $1; ++ if( $v ) ++ { ++ $v = ($v=~/=([01])$/)[0]; ++ }else ++ { ++ $v = 1; ++ }; ++ $self->{USE_MM_LD_RUN_PATH}=$v; ++ }; + + print STDOUT "MakeMaker (v$VERSION)\n" if $Verbose; + if (-f "MANIFEST" && ! -f "Makefile"){ +@@ -2320,6 +2340,40 @@ precedence. A typemap in the current di + precedence, even if it isn't listed in TYPEMAPS. The default system + typemap has lowest precedence. + ++=item USE_MM_LD_RUN_PATH ++ ++boolean ++The Fedora perl MakeMaker distribution differs from the standard ++upstream release in that it disables use of the MakeMaker generated ++LD_RUN_PATH by default, UNLESS this attribute is specified , or the ++USE_MM_LD_RUN_PATH environment variable is set during the MakeMaker run. ++ ++The upstream MakeMaker will set the ld(1) environment variable LD_RUN_PATH ++to the concatenation of every -L ld(1) option directory in which a -l ld(1) ++option library is found, which is used as the ld(1) -rpath option if none ++is specified. This means that, if your application builds shared libraries ++and your MakeMaker application links to them, that the absolute paths of the ++libraries in the build tree will be inserted into the RPATH header of all ++MakeMaker generated binaries, and that such binaries will be unable to link ++to these libraries if they do not still reside in the build tree directories ++(unlikely) or in the system library directories (/lib or /usr/lib), regardless ++of any LD_LIBRARY_PATH setting. So if you specified -L../mylib -lmylib , and ++ your 'libmylib.so' gets installed into /some_directory_other_than_usr_lib, ++ your MakeMaker application will be unable to link to it, even if LD_LIBRARY_PATH ++is set to include /some_directory_other_than_usr_lib, because RPATH overrides ++LD_LIBRARY_PATH. ++ ++So for Fedora MakeMaker builds LD_RUN_PATH is NOT generated by default for ++every link. You can still use explicit -rpath ld options or the LD_RUN_PATH ++environment variable during the build to generate an RPATH for the binaries. ++ ++You can set the USE_MM_LD_RUN_PATH attribute to 1 on the MakeMaker command ++line or in the WriteMakefile arguments to enable generation of LD_RUN_PATH ++for every link command. ++ ++USE_MM_LD_RUN_PATH will default to 1 (LD_RUN_PATH will be used) IF the ++$USE_MM_LD_RUN_PATH environment variable is set during a MakeMaker run. ++ + =item VENDORPREFIX + + Like PERLPREFIX, but only for the vendor install locations. +diff -up perl-5.12.0/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm.runpath perl-5.12.0/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm +--- perl-5.12.0/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm.runpath 2010-01-18 19:52:49.000000000 +0100 ++++ perl-5.12.0/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm 2010-04-13 15:56:10.656775285 +0200 +@@ -944,7 +944,7 @@ $(INST_DYNAMIC): $(OBJECT) $(MYEXTLIB) $ + } + + my $ld_run_path_shell = ""; +- if ($self->{LD_RUN_PATH} ne "") { ++ if (($self->{LD_RUN_PATH} ne "") && ($self->{USE_MM_LD_RUN_PATH})) { + $ld_run_path_shell = 'LD_RUN_PATH="$(LD_RUN_PATH)" '; + } + diff --git a/pkgs/core/perl/patches/perl-disable_test_hosts.patch b/pkgs/core/perl/patches/perl-disable_test_hosts.patch new file mode 100644 index 000000000..dc86a3462 --- /dev/null +++ b/pkgs/core/perl/patches/perl-disable_test_hosts.patch @@ -0,0 +1,12 @@ +diff -up perl-5.12.0/cpan/libnet/Net/Config.pm.disable perl-5.12.0/cpan/libnet/Net/Config.pm +--- perl-5.12.0/cpan/libnet/Net/Config.pm.disable 2010-01-18 19:52:49.000000000 +0100 ++++ perl-5.12.0/cpan/libnet/Net/Config.pm 2010-04-13 16:03:50.090770813 +0200 +@@ -29,7 +29,7 @@ eval { local $SIG{__DIE__}; require Net: + ftp_firewall => undef, + ftp_ext_passive => 1, + ftp_int_passive => 1, +- test_hosts => 1, ++ test_hosts => 0, + test_exist => 1, + ); + diff --git a/pkgs/core/perl/patches/perl-perlbug-tag.patch b/pkgs/core/perl/patches/perl-perlbug-tag.patch new file mode 100644 index 000000000..e4b09761f --- /dev/null +++ b/pkgs/core/perl/patches/perl-perlbug-tag.patch @@ -0,0 +1,51 @@ +--- perl-5.10.1/utils/perlbug.PL.fedora 2009-08-12 20:49:24.000000000 +0200 ++++ perl-5.10.1/utils/perlbug.PL 2009-11-18 15:56:15.000000000 +0100 +@@ -27,8 +27,6 @@ open OUT, ">$file" or die "Can't create + open PATCH_LEVEL, "<" . catfile(updir, "patchlevel.h") + or die "Can't open patchlevel.h: $!"; + +-my $patchlevel_date = (stat PATCH_LEVEL)[9]; +- + while () { + last if $_ =~ /^\s*static\s+(?:const\s+)?char.*?local_patches\[\]\s*=\s*{\s*$/; + } +@@ -71,9 +69,8 @@ $Config{startperl} + eval 'exec $Config{perlpath} -S \$0 \${1+"\$@"}' + if \$running_under_some_shell; + +-my \$config_tag1 = '$extract_version - $Config{cf_time}'; ++my \$config_tag1 = '$extract_version'; + +-my \$patchlevel_date = $patchlevel_date; + my \$patch_tags = '$patch_tags'; + my \@patches = ( + $patch_desc +@@ -333,17 +330,6 @@ sub Init { + $ok = ''; + if ($::opt_o) { + if ($::opt_o eq 'k' or $::opt_o eq 'kay') { +- my $age = time - $patchlevel_date; +- if ($::opt_o eq 'k' and $age > 60 * 24 * 60 * 60 ) { +- my $date = localtime $patchlevel_date; +- print <<"EOF"; +-"perlbug -ok" and "perlbug -nok" do not report on Perl versions which +-are more than 60 days old. This Perl version was constructed on +-$date. If you really want to report this, use +-"perlbug -okay" or "perlbug -nokay". +-EOF +- exit(); +- } + # force these options + unless ($::opt_n) { + $::opt_S = 1; # don't prompt for send +@@ -730,8 +716,8 @@ EFF + print OUT <