CPAN-Search-Lite

 view release on metacpan or  search on metacpan

Makefile.PL  view on Meta::CPAN

               'Pod::Select' => 0,
               'DBD::mysql' => 0,
               'CPAN::DistnameInfo' => 0,
               'Lingua::Stem' => 0,
               'AI::Categorizer' => 0,
               'Lingua::StopWords' => 0,
               'Perl::Tidy' => 0,
               'SOAP::Lite' => 0,
	       'XML::SAX::ExpatXS' => 0,
	       'Pod::Xhtml' => 0,
	       'Apache2::SOAP' => 0,
	       );

eval {require Apache2;};
eval {require Apache::Test; die "too old" if $Apache::Test::VERSION < 1.32 };
if ($@) {
    print <<'END';

Apache::Test 1.32 is required to run the part of the test suite.
I can add this to the list of prerequisites, if you like.

END
    my $ans = prompt("Add Apache::Test to prerequisites?", 'yes');
    $prereqs{'Apache::Test'} = 1.32 if ($ans =~ /^y/i);
}

eval {require SOAP::Lite;};
if ($@) {
    print <<'END';

SOAP::Lite is required to run the part of the test suite,
and also to provide SOAP-based web services. I can add this
to the list of prerequisites, if you like.

END
    my $ans = prompt("Add SOAP::Lite to prerequisites?", 'yes');
    $prereqs{'SOAP::Lite'} = 0 if ($ans =~ /^y/i);
}

eval {require mod_perl2;};
if ($@) {
    print <<'END';

mod_perl is required to run the part of the test suite,
and also to use the included Apache handlers. You will
need at least mod_perl 1.999022 (which is RC5 of mod_perl 2
on CPAN, used for Apache 2.0). See
   http://perl.apache.org/
for details on mod_perl, including links on how to install it.

I can add this to the list of prerequisites, if you like.
END
    my $ans = prompt("Add mod_perl2 to prerequsites?", 'yes');
    $prereqs{'mod_perl2'} = 1.999022 if ($ans =~ /^y/i);
}

eval {require APR::Request;};
if ($@) {
    print <<'END';

Apache2::Request and Apache2::Cookie from the latest libapreq2
distribution (based on Apache 2.0) is required to run part
of the test suite and to use the included Apache handlers
(this is not compatible with Apache::Request and
Apache::Cookie from the libapreq distribution, which is
based on Apache 1.3). See
   http://httpd.apache.org/apreq/
for details on the libapreq2 library, including links
on how to install it.

I can add this to the list of prerequisites, if you like.
END
    my $ans = prompt("Add Apache2::Request to prerequisites?", 'yes');
    $prereqs{'Apache2::Request'} = 0 if ($ans =~ /^y/i);
}

eval {require Template;};
if ($@ or $Template::VERSION < 2.14) {
    print <<'END';

The template toolkit (version 2.14 or later) is required to 
run part of the test suite and to use the included Apache 
handlers. See
   http://www.template-toolkit.org/
for details on using this, including links
on how to install it.

I can add this to the list of prerequisites, if you like.
END
    my $ans = prompt("Add Template to prerequisites?", 'yes');
    $prereqs{'Template'} = 2.14 if ($ans =~ /^y/i);
}

WriteMakefile( %opts, PREREQ_PM => \%prereqs);
my $make = $Config{make};
my $config = catfile 'build', 'gen_conf.pl';

print <<"END";

***************************************************************
You can now execute
   $make
   $make test
   $make install
After this, you can optionally run
   $^X $config
to set up some basic configuration details for your system.

If you are running an older version of CPAN::Search::Lite,
you should, after installation, run
   csl_index --config /path/to/config.cfg --rebuild-info
to rebuild a couple of the database tables.

Please read the INSTALL file for further installation instructions.
***************************************************************

END

eval {require CPAN::Search::Lite};
unless ($@) {
    my $version = $CPAN::Search::Lite::VERSION;
    if ($version < 0.64) {
  print <<"END";

***************************************************************



( run in 1.056 second using v1.01-cache-2.11-cpan-f56aa216473 )