From: apeiron Date: Mon, 15 Mar 2010 12:46:21 +0000 (+0000) Subject: better error message per sheriff/moses and sane first example per avar X-Git-Tag: 1.006009~37 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2Flocal-lib.git;a=commitdiff_plain;h=359329d3359bfe76ecef3ec4b00ff368a7573356 better error message per sheriff/moses and sane first example per avar git-svn-id: http://dev.catalyst.perl.org/repos/bast/local-lib/1.000/trunk@9004 bd8105ee-0ff8-0310-8827-fb3f25b6796d --- diff --git a/Makefile.PL b/Makefile.PL index 18e25bd..570e362 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -204,13 +204,21 @@ delete $ENV{PERL5_CPAN_IS_RUNNING} if $no_cpan_env; CPAN::HandleConfig->load; for my $eumm_setting ( qw/makepl_arg make_install_arg/ ) { if ($CPAN::Config->{$eumm_setting} =~ /(?:PREFIX|INSTALL_BASE)/) { - die "Possibly invalid config detected in $eumm_setting: " . $CPAN::Config->{$eumm_setting}; + die <<"DEATH"; +WHOA THERE! It looks like you've got $CPAN::Config->{$eumm_setting} set. This is +known to cause problems with local::lib. Please either remove this setting or +clear out your .cpan directory. +DEATH } } for my $mb_setting (qw/mbuild_arg mbuild_install_arg mbuildpl_arg/) { if ($CPAN::Config->{$mb_setting} =~ /(?:--prefix|--install_base)/) { - die "Possibly invalid config detected in $mb_setting: " . $CPAN::Config->{$mb_setting}; + die <<"DEATH"; +WHOA THERE! It looks like you've got $CPAN::Config->{$mb_setting} set. This is +known to cause problems with local::lib. Please either remove this setting or +clear out your .cpan directory. +DEATH } } } diff --git a/lib/local/lib.pm b/lib/local/lib.pm index 0ea978f..5764ce8 100644 --- a/lib/local/lib.pm +++ b/lib/local/lib.pm @@ -397,8 +397,8 @@ In code - From the shell - - # Install LWP and its missing dependencies to the 'my_lwp' directory - perl -MCPAN -Mlocal::lib=my_lwp -e 'CPAN::install(LWP)' + # Install LWP and its missing dependencies to the '~/perl5' directory + perl -MCPAN -Mlocal::lib -e 'CPAN::install(LWP)' # Install LWP and *all non-core* dependencies to the 'my_lwp' directory perl -MCPAN -Mlocal::lib=--self-contained,my_lwp -e 'CPAN::install(LWP)'