$| = 1;
my
$recommend_versions
=
{
'Math::BigInt::FastCalc'
=>
'0.5006'
,
'Math::BigInt::GMP'
=>
'1.6000'
,
'Math::BigInt::Pari'
=>
'1.3000'
,
'Math::BigInt::BitVect'
=>
'1.13'
,
'Math::BigInt::GMPz'
=>
'0.0005'
,
};
my
$recommend_update
= [];
while
(
my
(
$module
,
$recommend_version
) =
each
%$recommend_versions
) {
next
unless
eval
"require $module"
;
my
$version
=
$module
-> VERSION();
next
if
$version
>=
$recommend_version
;
push
@$recommend_update
, [
$module
,
$recommend_version
,
$version
];
}
if
(
@$recommend_update
) {
print
<<"EOF";
##########################################################################
#
# Some of the new methods will not work unless the following installed
# modules are updated. It is therefore recommended that the modules listed
# below are upgraded after installing this distribution.
#
# Module Recommended Installed
# ------ ----------- ---------
EOF
for
my
$entry
(
@$recommend_update
) {
printf
"# %-30s %-14s %s\n"
,
@$entry
;
}
print
<<"EOF";
#
##########################################################################
EOF
printf
"Sleeping for a few seconds ..."
;
sleep
5;
printf
" done.\n"
;
}
my
%WriteMakefileArgs
=
(
'NAME'
=>
'Math::BigInt'
,
'VERSION_FROM'
=>
'lib/Math/BigInt.pm'
,
'AUTHOR'
=>
'Peter John Acklam <pjacklam@gmail.com>'
,
'MIN_PERL_VERSION'
=> 5.006001,
'CONFIGURE_REQUIRES'
=> {
'ExtUtils::MakeMaker'
=> 6.58,
},
'BUILD_REQUIRES'
=> {},
'PREREQ_PM'
=> {
'Math::Complex'
=> 1.36,
'Carp'
=> 1.22,
'Scalar::Util'
=> 0,
},
'TEST_REQUIRES'
=> {
'Test::More'
=> 0.94,
},
'LICENSE'
=>
'perl_5'
,
'LIBS'
=> [
''
],
'DEFINE'
=>
''
,
'INC'
=>
''
,
'SIGN'
=> 1,
'META_MERGE'
=> {
'meta-spec'
=> {
version
=> 2 },
resources
=> {
repository
=> {
type
=>
'git'
,
},
},
},
);
$WriteMakefileArgs
{INSTALLDIRS} =
'perl'
if
$] < 5.012;
WriteMakefile(
%WriteMakefileArgs
);