Index: /lang/perl/Acme-CPANAuthors/trunk/lib/Acme/CPANAuthors/Utils.pm
===================================================================
--- /lang/perl/Acme-CPANAuthors/trunk/lib/Acme/CPANAuthors/Utils.pm (revision 3606)
+++ /lang/perl/Acme-CPANAuthors/trunk/lib/Acme/CPANAuthors/Utils.pm (revision 11297)
@@ -42,7 +42,9 @@
   my ($dir, $basename) = @_;
 
-  _require_cpan_config();
+  _require_myconfig_or_config();
+  croak "You might want to configure CPAN first."
+    unless $CPAN::Config && ref $CPAN::Config eq 'HASH';
 
-  my $source_dir   = $CPAN::Config->{keep_source_where};
+  my $source_dir = $CPAN::Config->{keep_source_where};
   my $file = _catfile( $source_dir, '/', $dir, '/', $basename );
   unless ( -f $file ) {
@@ -54,10 +56,16 @@
 }
 
-sub _require_cpan_config () {
-  if ( $INC{'CPAN/MyConfig.pm'} ) {
-    eval { require CPAN::MyConfig };
-    if ( $@ and $@ !~ m{Can't locate CPAN/MyConfig\.pm} ) {
-      croak "CPAN::MyConfig error: $@";
-    }
+sub _require_myconfig_or_config () { # from CPAN::HandleConfig
+  return if $INC{'CPAN/MyConfig.pm'};
+  local @INC = @INC;
+
+  eval { require File::HomeDir 0.52 };
+  my $home = $@ ? $ENV{HOME} : File::HomeDir->my_data;
+
+  unshift @INC, File::Spec->catdir($home, '.cpan');
+
+  eval { require CPAN::MyConfig };
+  if ( $@ and $@ !~ m{Can't locate CPAN/MyConfig\.pm} ) {
+    croak "CPAN::MyConfig error: $@";
   }
   unless ( $INC{'CPAN/MyConfig.pm'} ) {
Index: /lang/perl/Acme-CPANAuthors/trunk/Changes
===================================================================
--- /lang/perl/Acme-CPANAuthors/trunk/Changes (revision 11294)
+++ /lang/perl/Acme-CPANAuthors/trunk/Changes (revision 11297)
@@ -3,4 +3,5 @@
 0.02 2008/05/**
   - made Acme::CPANAuthors::(Specific)->authors context sensitive.
+  - better cpan config loading
 
 0.01 2007/12/26
