summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Install
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla/Install')
-rw-r--r--Bugzilla/Install/CPAN.pm17
-rw-r--r--Bugzilla/Install/Requirements.pm32
2 files changed, 19 insertions, 30 deletions
diff --git a/Bugzilla/Install/CPAN.pm b/Bugzilla/Install/CPAN.pm
index a3f913702..31bd7f88f 100644
--- a/Bugzilla/Install/CPAN.pm
+++ b/Bugzilla/Install/CPAN.pm
@@ -71,13 +71,6 @@ use constant REQUIREMENTS => (
# we make it a constant.
use constant BZ_LIB => abs_path(bz_locations()->{ext_libpath});
-# These modules are problematic to install with "notest" (sometimes they
-# get installed when they shouldn't). So we always test their installation
-# and never ignore test failures.
-use constant ALWAYS_TEST => qw(
- Math::Random::Secure
-);
-
# CPAN requires nearly all of its parameters to be set, or it will start
# asking questions to the user. We want to avoid that, so we have
# defaults here for most of the required parameters we know about, in case
@@ -202,10 +195,7 @@ sub install_module {
print install_string('install_module',
{ module => $module_name, version => $version }) . "\n";
- if (_always_test($name)) {
- CPAN::Shell->install($name);
- }
- elsif ($test) {
+ if ($test) {
CPAN::Shell->force('install', $name);
}
else {
@@ -220,11 +210,6 @@ sub install_module {
$CPAN::Config->{makepl_arg} = $original_makepl;
}
-sub _always_test {
- my ($name) = @_;
- return grep(lc($_) eq lc($name), ALWAYS_TEST) ? 1 : 0;
-}
-
sub set_cpan_config {
my $do_global = shift;
my $bzlib = BZ_LIB;
diff --git a/Bugzilla/Install/Requirements.pm b/Bugzilla/Install/Requirements.pm
index c22c2de34..8825eb3a7 100644
--- a/Bugzilla/Install/Requirements.pm
+++ b/Bugzilla/Install/Requirements.pm
@@ -160,13 +160,27 @@ sub REQUIRED_MODULES {
version => 0.22,
},
{
- package => 'Math-Random-Secure',
- module => 'Math::Random::Secure',
- # This is the first version that installs properly on Windows.
- version => '0.05',
+ package => 'Math-Random-ISAAC',
+ module => 'Math::Random::ISAAC',
+ version => '1.0.1',
},
);
+ if (ON_WINDOWS) {
+ push(@modules, {
+ package => 'Win32',
+ module => 'Win32',
+ # 0.35 fixes a memory leak in GetOSVersion, which we use.
+ version => 0.35,
+ },
+ {
+ package => 'Win32-API',
+ module => 'Win32::API',
+ # 0.55 fixes a bug with char* that might affect Bugzilla::RNG.
+ version => '0.55',
+ });
+ }
+
my $extra_modules = _get_extension_requirements('REQUIRED_MODULES');
push(@modules, @$extra_modules);
return \@modules;
@@ -351,16 +365,6 @@ sub OPTIONAL_MODULES {
},
);
- if (ON_WINDOWS) {
- # SizeLimit needs Win32::API to work on Windows.
- push(@modules, {
- package => 'Win32-API',
- module => 'Win32::API',
- version => 0,
- feature => ['mod_perl'],
- });
- }
-
my $extra_modules = _get_extension_requirements('OPTIONAL_MODULES');
push(@modules, @$extra_modules);
return \@modules;