---- Changes since 1.440 ----
Sped up the fetching of Perl modules installed from RPM and Debian packages.
Switched the install and current modules tabs.
+---- Changes since 1.530 ----
+When upgrading multiple Perl modules from CPAN, don't give up because just one could not be found.
}
}
close(LIST);
+
+ # Fail if any modules are missing from CPAN
for($i=0; $i<@cpan; $i++) {
push(@missing, "<tt>$cpan[$i]</tt>") if (!$source[$i]);
}
- &install_error(&text('download_ecpan', join(" ", @missing)))
- if (@missing);
+
+ if ($in{'missingok'}) {
+ # If missing modules are OK, exclude them from the sources list
+ for($i=0; $i<@cpan; $i++) {
+ if (!$source[$i]) {
+ splice(@source, $i, 1);
+ splice(@cpan, $i, 1);
+ $i--;
+ }
+ }
+ @cpan || &install_error(&text('download_ecpan',
+ join(" ", @missing)));
+ }
+ elsif (@missing) {
+ # Fail due to missing modules
+ &install_error(&text('download_ecpan', join(" ", @missing)));
+ }
$source = join("<br>", @source);
# Download the actual modules
print &ui_table_row(@mods > 1 ? $text{'download_mods'} : $text{'download_mod'},
$modmsg);
+# Missing modules
+if (@missing) {
+ print &ui_table_row($text{'download_missingok'},
+ join(" ", @missing));
+ }
+
# Source
print &ui_table_row($text{'download_src'}, $source);
download_nomissing=All installed
download_ebuild=One or more of the Perl modules needs $1 to be built, but this Perl module is not installed.
download_yum=Installing Perl module $1 from package $2 ..
+download_missingok=Modules missing from CPAN
install_title=Install Module
install_untar=Untarring module file