Add www-apache/mod_perl from ::gentoo.
[mjo-overlay.git] / www-apache / mod_perl / files / mod_perl-2.0.8-bundled-Apache-Test.patch
1 --- a/Makefile.PL
2 +++ b/Makefile.PL
3 @@ -24,7 +24,7 @@ BEGIN {
4
5 }
6
7 -use lib qw(lib Apache-Test/lib);
8 +use lib qw(lib);
9
10 use Config;
11 use File::Spec::Functions;
12 @@ -117,16 +117,6 @@ sub get_DEFINE {
13 }
14
15 sub configure {
16 -
17 - # mod_perl test suite relies on having Apache-Test bundled with
18 - # the mod_perl source, since any pre-installed version may not do
19 - # the right thing
20 - unless (-d "Apache-Test") {
21 - error "Can't find a sub-directory Apache-Test. " .
22 - "Make sure that you are using a complete source distribution";
23 - exit 1;
24 - }
25 -
26 set_modperl_version();
27
28 if ($old_modperl_version) {
29 @@ -798,14 +788,9 @@ run_tests : test_clean
30 run_subtests ::
31 cd ModPerl-Registry && $(MAKE) test
32
33 -run_subtests ::
34 - cd Apache-Reload && $(MAKE) test
35 -
36 EOF
37
38 $preamble .= <<'EOF' unless $build->mpm_is_threaded();
39 -run_subtests ::
40 - cd Apache-SizeLimit && $(MAKE) test
41
42 EOF
43
44 @@ -816,37 +801,6 @@ EOF
45 return $preamble;
46 }
47
48 -sub MY::postamble {
49 - my $self = shift;
50 -
51 - my $string = $self->ModPerl::BuildMM::MY::postamble;
52 -
53 - $string .= <<'EOF';
54 -mydist : Apache-Test/META.yml mod_perl.spec manifest tardist
55 -
56 -rpm: dist
57 - @[ -d $(PWD)/rpm ] || mkdir $(PWD)/rpm
58 - rpmbuild -ta --define "_rpmdir $(PWD)/rpm" \
59 - --define "_srcrpmdir $(PWD)/rpm" \
60 - $(DISTVNAME).tar.gz
61 - @mv $(PWD)/rpm/*/*.rpm $(PWD)/rpm/
62 - @rm -rf $(PWD)/rpm/*/
63 -
64 -mod_perl.spec: build/make_rpm_spec
65 - $(PERL) build/make_rpm_spec
66 -
67 -Apache-Test/META.yml:
68 - cd Apache-Test && make metafile
69 -
70 -tag :
71 - svn copy https://svn.apache.org/repos/asf/perl/modperl/trunk https://svn.apache.org/repos/asf/perl/modperl/branches/release/$(VERSION_SYM)
72 - svn copy https://svn.apache.org/repos/asf/perl/modperl/branches/release/$(VERSION_SYM) https://svn.apache.org/repos/asf/perl/modperl/tags/$(VERSION_SYM)
73 - svn copy https://svn.apache.org/repos/asf/perl/modperl/docs/trunk https://svn.apache.org/repos/asf/perl/modperl/docs/tags/$(VERSION_SYM)
74 -EOF
75 -
76 - return $string;
77 -}
78 -
79 # this is a workaround so that ModPerl::MM will move MY::constants
80 # away, and Apache-Test/Makefile.PL which has its own MY::constants
81 # won't get complaints on MY::constants redefined
82 --- a/ModPerl-Registry/Makefile.PL
83 +++ b/ModPerl-Registry/Makefile.PL
84 @@ -14,7 +14,7 @@ use Apache::TestMM qw(test clean);
85
86 # prerequisites
87 my %require = (
88 - "Apache::Test" => "", # any version will do?
89 + "Apache::Test" => 0, # any version will do?
90 );
91
92 my @scripts = qw(t/TEST t/SMOKE);
93 --- a/lib/ModPerl/BuildMM.pm
94 +++ b/lib/ModPerl/BuildMM.pm
95 @@ -38,12 +38,10 @@ my @methods = grep *{$stash->{$_}}{CODE}
96 ModPerl::MM::override_eu_mm_mv_all_methods(@methods);
97 use strict 'refs';
98
99 -my $apache_test_dir = catdir Cwd::getcwd(), "Apache-Test", "lib";
100 -
101 #to override MakeMaker MOD_INSTALL macro
102 sub mod_install {
103 q{$(PERL) -I$(INST_LIB) -I$(PERL_LIB) \\}."\n" .
104 - qq{-I$apache_test_dir -MModPerl::BuildMM \\}."\n" .
105 + qq{-MModPerl::BuildMM \\}."\n" .
106 q{-e "ExtUtils::Install::install({@ARGV},'$(VERBINST)',0,'$(UNINST)');"}."\n";
107 }
108
109 @@ -269,7 +267,7 @@ sub ModPerl::BuildMM::MY::postamble {
110
111 push @target,
112 '$(FULLPERL) -I$(INST_LIB) ' .
113 - "-I$apache_test_dir -MModPerl::BuildMM " .
114 + "-MModPerl::BuildMM " .
115 "-e ModPerl::BuildMM::glue_pod $pm $podpath $blib";
116
117 # Win32 doesn't normally install man pages
118 --- a/lib/ModPerl/Manifest.pm
119 +++ b/lib/ModPerl/Manifest.pm
120 @@ -33,7 +33,6 @@ our @EXPORT_OK = qw(mkmanifest);
121 my @add_files = qw{
122 MANIFEST
123 mod_perl.spec
124 - Apache-Test/META.yml
125 };
126
127 sub get_svn_files {