Blame SOURCES/CPAN-2.05-Replace-configuration-direcotory-string-with-a-marke.patch

e4adba
From a5c7a3e5118aac73ac2adef676d842392c41cff3 Mon Sep 17 00:00:00 2001
e4adba
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
e4adba
Date: Wed, 28 Jan 2015 13:21:10 +0100
e4adba
Subject: [PATCH] Replace configuration direcotory string with a marker
e4adba
MIME-Version: 1.0
e4adba
Content-Type: text/plain; charset=UTF-8
e4adba
Content-Transfer-Encoding: 8bit
e4adba
e4adba
This allows to redefine the configuration directory name at build
e4adba
time.
e4adba
e4adba
Signed-off-by: Petr Písař <ppisar@redhat.com>
e4adba
e4adba
diff --git a/Makefile.PL b/Makefile.PL
e4adba
index 04d94aa..61c87bf 100644
e4adba
--- a/Makefile.PL
e4adba
+++ b/Makefile.PL
e4adba
@@ -327,21 +327,21 @@ record-session :
e4adba
 	$(PERL) -Ilib -MCPAN -e '$$CPAN::Suppress_readline=$$CPAN::Echo_readline=1;shell' | tee ttt.out
e4adba
 
e4adba
 run-with-sqlite :
e4adba
-	$(PERL) -I$$HOME/.cpan -Ilib -MCPAN::SQLite -MCPAN::MyConfig -MCPAN -e '$$CPAN::Config->{use_sqlite}++; $$CPAN::Config->{sqlite_dbname}="cpandb-sqlite"; shell'
e4adba
+	$(PERL) -I$$HOME/.XCPANCONFIGNAMEX -Ilib -MCPAN::SQLite -MCPAN::MyConfig -MCPAN -e '$$CPAN::Config->{use_sqlite}++; $$CPAN::Config->{sqlite_dbname}="cpandb-sqlite"; shell'
e4adba
 
e4adba
 testrun_very_offline : rm_mirrored_by run_emu_offline
e4adba
 
e4adba
 testrun_emu_offline :
e4adba
-	$(PERL) -I$$HOME/.cpan -Ilib -MCPAN::MyConfig -MCPAN -e '@CPAN::Defaultsites = qw(file:///dev/null); $$CPAN::Config->{urllist} = []; shell'
e4adba
+	$(PERL) -I$$HOME/.XCPANCONFIGNAMEX -Ilib -MCPAN::MyConfig -MCPAN -e '@CPAN::Defaultsites = qw(file:///dev/null); $$CPAN::Config->{urllist} = []; shell'
e4adba
 
e4adba
 rm_mirrored_by :
e4adba
-	rm -f $$HOME/.cpan/sources/MIRRORED.BY*
e4adba
+	rm -f $$HOME/.XCPANCONFIGNAMEX/sources/MIRRORED.BY*
e4adba
 
e4adba
 testrun_http_only :
e4adba
-	$(PERL) -I$$HOME/.cpan -Ilib -MCPAN::MyConfig -MCPAN -e '$$CPAN::Config->{urllist} = [qw(http://www.planet-elektronik.de/CPAN/)]; shell'
e4adba
+	$(PERL) -I$$HOME/.XCPANCONFIGNAMEX -Ilib -MCPAN::MyConfig -MCPAN -e '$$CPAN::Config->{urllist} = [qw(http://www.planet-elektronik.de/CPAN/)]; shell'
e4adba
 
e4adba
 urllist :
e4adba
-	$(PERL) -Ilib -MCPAN -MCPAN::FirstTime -e 'CPAN::FirstTime::init("$$ENV{HOME}/.cpan/CPAN/MyConfig", args => [qw(urllist)])'
e4adba
+	$(PERL) -Ilib -MCPAN -MCPAN::FirstTime -e 'CPAN::FirstTime::init("$$ENV{HOME}/.XCPANCONFIGNAMEX/CPAN/MyConfig", args => [qw(urllist)])'
e4adba
 
e4adba
 runadmin :
e4adba
 	$(PERL) -Ilib -MCPAN::Admin -eshell
e4adba
diff --git a/README b/README
e4adba
index cadff53..7b1a3ae 100644
e4adba
--- a/README
e4adba
+++ b/README
e4adba
@@ -269,7 +269,7 @@ DESCRIPTION
e4adba
       restarting the whole get/make/test/install procedure from scratch.
e4adba
 
e4adba
     Lockfile
e4adba
-      Interactive sessions maintain a lockfile, by default "~/.cpan/.lock".
e4adba
+      Interactive sessions maintain a lockfile, by default "~/.XCPANCONFIGNAMEX/.lock".
e4adba
       Batch jobs can run without a lockfile and not disturb each other.
e4adba
 
e4adba
       The shell offers to run in *downgraded mode* when another process is
e4adba
@@ -329,7 +329,7 @@ DESCRIPTION
e4adba
         "install_tested".
e4adba
 
e4adba
   mkmyconfig
e4adba
-    mkmyconfig() writes your own CPAN::MyConfig file into your "~/.cpan/"
e4adba
+    mkmyconfig() writes your own CPAN::MyConfig file into your "~/.XCPANCONFIGNAMEX/"
e4adba
     directory so that you can save your own preferences instead of the
e4adba
     system-wide ones.
e4adba
 
e4adba
@@ -494,7 +494,7 @@ CONFIGURATION
e4adba
 
e4adba
     Default values defined in the CPAN/Config.pm file can be overridden in a
e4adba
     user specific file: CPAN/MyConfig.pm. Such a file is best placed in
e4adba
-    "$HOME/.cpan/CPAN/MyConfig.pm", because "$HOME/.cpan" is added to the
e4adba
+    "$HOME/.XCPANCONFIGNAMEX/CPAN/MyConfig.pm", because "$HOME/.XCPANCONFIGNAMEX" is added to the
e4adba
     search path of the CPAN module before the use() or require() statements.
e4adba
     The mkmyconfig command writes this file for you.
e4adba
 
e4adba
@@ -1944,8 +1944,8 @@ FAQ
e4adba
 
e4adba
         You may want to configure something like
e4adba
 
e4adba
-          o conf make_arg "| tee -ai /root/.cpan/logs/make.out"
e4adba
-          o conf make_install_arg "| tee -ai /root/.cpan/logs/make_install.out"
e4adba
+          o conf make_arg "| tee -ai /root/.XCPANCONFIGNAMEX/logs/make.out"
e4adba
+          o conf make_install_arg "| tee -ai /root/.XCPANCONFIGNAMEX/logs/make_install.out"
e4adba
 
e4adba
         so that STDOUT is captured in a file for later inspection.
e4adba
 
e4adba
diff --git a/lib/CPAN.pm b/lib/CPAN.pm
e4adba
index 4ed4b6c..e30b9d7 100644
e4adba
--- a/lib/CPAN.pm
e4adba
+++ b/lib/CPAN.pm
e4adba
@@ -1680,7 +1680,7 @@ restarting the whole get/make/test/install procedure from scratch.
e4adba
 
e4adba
 =item Lockfile
e4adba
 
e4adba
-Interactive sessions maintain a lockfile, by default C<~/.cpan/.lock>.
e4adba
+Interactive sessions maintain a lockfile, by default C<~/.XCPANCONFIGNAMEX/.lock>.
e4adba
 Batch jobs can run without a lockfile and not disturb each other.
e4adba
 
e4adba
 The shell offers to run in I<downgraded mode> when another process is
e4adba
@@ -1754,7 +1754,7 @@ C<install_tested>.
e4adba
 
e4adba
 =head2 mkmyconfig
e4adba
 
e4adba
-mkmyconfig() writes your own CPAN::MyConfig file into your C<~/.cpan/>
e4adba
+mkmyconfig() writes your own CPAN::MyConfig file into your C<~/.XCPANCONFIGNAMEX/>
e4adba
 directory so that you can save your own preferences instead of the
e4adba
 system-wide ones.
e4adba
 
e4adba
@@ -1932,7 +1932,7 @@ in a file CPAN/Config.pm.
e4adba
 
e4adba
 Default values defined in the CPAN/Config.pm file can be
e4adba
 overridden in a user specific file: CPAN/MyConfig.pm. Such a file is
e4adba
-best placed in C<$HOME/.cpan/CPAN/MyConfig.pm>, because C<$HOME/.cpan> is
e4adba
+best placed in C<$HOME/.XCPANCONFIGNAMEX/CPAN/MyConfig.pm>, because C<$HOME/.XCPANCONFIGNAMEX> is
e4adba
 added to the search path of the CPAN module before the use() or
e4adba
 require() statements. The mkmyconfig command writes this file for you.
e4adba
 
e4adba
@@ -3608,8 +3608,8 @@ there is too much output to keep track of.
e4adba
 
e4adba
 You may want to configure something like
e4adba
 
e4adba
-  o conf make_arg "| tee -ai /root/.cpan/logs/make.out"
e4adba
-  o conf make_install_arg "| tee -ai /root/.cpan/logs/make_install.out"
e4adba
+  o conf make_arg "| tee -ai /root/.XCPANCONFIGNAMEX/logs/make.out"
e4adba
+  o conf make_install_arg "| tee -ai /root/.XCPANCONFIGNAMEX/logs/make_install.out"
e4adba
 
e4adba
 so that STDOUT is captured in a file for later inspection.
e4adba
 
e4adba
diff --git a/lib/CPAN/HandleConfig.pm b/lib/CPAN/HandleConfig.pm
e4adba
index f114321..a6e596b 100644
e4adba
--- a/lib/CPAN/HandleConfig.pm
e4adba
+++ b/lib/CPAN/HandleConfig.pm
e4adba
@@ -536,7 +536,7 @@ sub cpan_home_dir_candidates {
e4adba
     push @dirs, $ENV{USERPROFILE} if $ENV{USERPROFILE};
e4adba
 
e4adba
     $CPAN::Config->{load_module_verbosity} = $old_v;
e4adba
-    my $dotcpan = $^O eq 'VMS' ? '_cpan' : '.cpan';
e4adba
+    my $dotcpan = $^O eq 'VMS' ? '_XCPANCONFIGNAMEX' : '.XCPANCONFIGNAMEX';
e4adba
     @dirs = map { File::Spec->catdir($_, $dotcpan) } grep { defined } @dirs;
e4adba
     return wantarray ? @dirs : $dirs[0];
e4adba
 }
e4adba
diff --git a/scripts/cpan-mirrors b/scripts/cpan-mirrors
e4adba
index 3c8678b..7a0e756 100755
e4adba
--- a/scripts/cpan-mirrors
e4adba
+++ b/scripts/cpan-mirrors
e4adba
@@ -6,7 +6,7 @@ use warnings;
e4adba
 use CPAN::Mirrors;
e4adba
 use Data::Dumper;
e4adba
 
e4adba
-my $mirrored_by_file = '/Users/brian/.cpan/sources/MIRRORED.BY';
e4adba
+my $mirrored_by_file = '/Users/brian/.XCPANCONFIGNAMEX/sources/MIRRORED.BY';
e4adba
 my $mirrors = CPAN::Mirrors->new( $mirrored_by_file );
e4adba
 
e4adba
 my $seen = {};
e4adba
-- 
e4adba
1.9.3
e4adba