Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
69fca5ee
You need to sign in or sign up before continuing.
Commit
69fca5ee
authored
Apr 20, 2010
by
Max Kanat-Alexander
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 560691: Make sure that install-module.pl never prompts the user while
installing modules r=mkanat, a=mkanat (module owner)
parent
98820141
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
5 deletions
+13
-5
CPAN.pm
Bugzilla/Install/CPAN.pm
+10
-3
Requirements.pm
Bugzilla/Install/Requirements.pm
+3
-2
No files found.
Bugzilla/Install/CPAN.pm
View file @
69fca5ee
...
@@ -127,6 +127,12 @@ sub install_module {
...
@@ -127,6 +127,12 @@ sub install_module {
my
(
$name
,
$test
)
=
@_
;
my
(
$name
,
$test
)
=
@_
;
my
$bzlib
=
BZ_LIB
;
my
$bzlib
=
BZ_LIB
;
# Make Module::AutoInstall install all dependencies and never prompt.
local
$ENV
{
PERL_AUTOINSTALL
}
=
'--alldeps'
;
# This makes Net::SSLeay not prompt the user, if it gets installed.
# It also makes any other MakeMaker prompts accept their defaults.
local
$ENV
{
PERL_MM_USE_DEFAULT
}
=
1
;
# Certain modules require special stuff in order to not prompt us.
# Certain modules require special stuff in order to not prompt us.
my
$original_makepl
=
$
CPAN::
Config
->
{
makepl_arg
};
my
$original_makepl
=
$
CPAN::
Config
->
{
makepl_arg
};
# This one's a regex in case we're doing Template::Plugin::GD and it
# This one's a regex in case we're doing Template::Plugin::GD and it
...
@@ -137,12 +143,13 @@ sub install_module {
...
@@ -137,12 +143,13 @@ sub install_module {
elsif
(
$name
eq
'XML::Twig'
)
{
elsif
(
$name
eq
'XML::Twig'
)
{
$
CPAN::
Config
->
{
makepl_arg
}
=
"-n $original_makepl"
;
$
CPAN::
Config
->
{
makepl_arg
}
=
"-n $original_makepl"
;
}
}
elsif
(
$name
eq
'Net::LDAP'
)
{
$
CPAN::
Config
->
{
makepl_arg
}
.=
" --skipdeps"
;
}
elsif
(
$name
eq
'SOAP::Lite'
)
{
elsif
(
$name
eq
'SOAP::Lite'
)
{
$
CPAN::
Config
->
{
makepl_arg
}
.=
" --noprompt"
;
$
CPAN::
Config
->
{
makepl_arg
}
.=
" --noprompt"
;
}
}
# MIME-tools has a Module::Install that's too old to understand alldeps.
elsif
(
$name
=~
/^MIME::/
)
{
$ENV
{
PERL_AUTOINSTALL
}
=
'--defaultdeps'
;
}
my
$module
=
CPAN::
Shell
->
expand
(
'Module'
,
$name
);
my
$module
=
CPAN::
Shell
->
expand
(
'Module'
,
$name
);
print
install_string
(
'install_module'
,
print
install_string
(
'install_module'
,
...
...
Bugzilla/Install/Requirements.pm
View file @
69fca5ee
...
@@ -533,8 +533,9 @@ sub have_vers {
...
@@ -533,8 +533,9 @@ sub have_vers {
eval
"require $module;"
;
eval
"require $module;"
;
# VERSION is provided by UNIVERSAL::
# VERSION is provided by UNIVERSAL::, and can be called even if
my
$vnum
=
eval
{
$module
->
VERSION
}
||
-
1
;
# the module isn't loaded.
my
$vnum
=
$module
->
VERSION
||
-
1
;
# CGI's versioning scheme went 2.75, 2.751, 2.752, 2.753, 2.76
# CGI's versioning scheme went 2.75, 2.751, 2.752, 2.753, 2.76
# That breaks the standard version tests, so we need to manually correct
# That breaks the standard version tests, so we need to manually correct
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment