diff options
author | 2008-04-13 03:25:58 +0000 | |
---|---|---|
committer | 2008-04-13 03:25:58 +0000 | |
commit | 70ce4673db7bee716fb8d4595fee070117b6f086 (patch) | |
tree | 20454e0c8f39e1c852f31c168ef4e2e5c9f53b7b | |
parent | Bug 428569 â The CGI module's package name is CGI.pm. (diff) | |
download | bugzilla-70ce4673db7bee716fb8d4595fee070117b6f086.tar.gz bugzilla-70ce4673db7bee716fb8d4595fee070117b6f086.tar.bz2 bugzilla-70ce4673db7bee716fb8d4595fee070117b6f086.zip |
Bug 428637 â Documentation doesn't build (and even less on Perl 5.10).
Patch by Marc Schumann <wurblzap@gmail.com>;
r=LpSolit; a=mkanat
-rw-r--r-- | docs/makedocs.pl | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/docs/makedocs.pl b/docs/makedocs.pl index b636a2f37..cf77b3eba 100644 --- a/docs/makedocs.pl +++ b/docs/makedocs.pl @@ -72,9 +72,11 @@ foreach my $module (@$modules, @$opt_modules) print ENTITIES '<!ENTITY min-' . $name . '-ver "'.$version.'">' . "\n"; } -# CGI is a special case, because it has an optional version *and* a required -# version. -my ($cgi_opt) = grep($_->{package} eq 'CGI', @$opt_modules); +# CGI is a special case, because for Perl versions below 5.10, it has an +# optional version *and* a required version. +# We check @opt_modules first, then @modules, and pick the first we get. +# We'll get the optional one then, if it is given, otherwise the required one. +my ($cgi_opt) = grep($_->{module} eq 'CGI', @$opt_modules, @$modules); print ENTITIES '<!ENTITY min-mp-cgi-ver "' . $cgi_opt->{version} . '">' . "\n"; print ENTITIES "\n <!-- Database Versions --> \n"; @@ -82,7 +84,8 @@ print ENTITIES "\n <!-- Database Versions --> \n"; my $db_modules = DB_MODULE; foreach my $db (keys %$db_modules) { my $dbd = $db_modules->{$db}->{dbd}; - my $name = $dbd->{package}; + my $name = $dbd->{module}; + $name =~ s/::/-/g; $name = lc($name); my $version = $dbd->{version} || 'any'; my $db_version = $db_modules->{$db}->{'db_version'}; |