develooper Front page | perl.perl5.porters | Postings from April 2000

[PATCH 5.6.0] perldoc fails with "use blib"

From:
Hugo
Date:
April 23, 2000 08:55
Subject:
[PATCH 5.6.0] perldoc fails with "use blib"
Message ID:
200004231603.RAA30002@crypt.compulink.co.uk
If the current directory contains a file 'Makefile.PL', perldoc attempts
to "use blib" and dies if that fails. The patch below changes this to
ignore such failure, but warn with the failure message if run with -v.

Hugo
--- utils/perldoc.PL.old	Tue Mar 14 03:51:54 2000
+++ utils/perldoc.PL	Sun Apr 23 16:57:27 2000
@@ -202,7 +202,8 @@
 
     # don't add if superuser
     if ($< && $>) {   # don't be looking too hard now!
-	eval q{ use blib; 1 } or die;
+	eval q{ use blib; 1 };
+	warn $@ if $@ && $opt_v;
     }
 }
 
@@ -790,7 +791,7 @@
 
 =head1 VERSION
 
-This is perldoc v2.01.
+This is perldoc v2.03.
 
 =head1 AUTHOR
 
@@ -802,6 +803,9 @@
 =cut
 
 #
+# Version 2.03: Sun Apr 23 16:56:34 BST 2000
+#	Hugo van der Sanden <hv@crypt0.demon.co.uk>
+#	don't die when 'use blib' fails
 # Version 2.02: Mon Mar 13 18:03:04 MST 2000
 #       Tom Christiansen <tchrist@perl.com>
 #	Added -U insecurity option



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About