perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nikolay Ananiev" <anan...@thegdb.com>
Subject Add error msg for MP_AP_PREFIX
Date Wed, 04 Oct 2006 10:49:21 GMT
I tried to install mp2 with perl Makefile.PL MP_AP_PREFIX=c:\some\path
but the path was wrong and I got this ugly message:

Use of uninitialized value in concatenation (.) or string at
lib/ModPerl/BuildOp
tions.pm line 138, <DATA> line 23.

This patch adds a nice error message.

Index: BuildOptions.pm
===================================================================
--- BuildOptions.pm (revision 452813)
+++ BuildOptions.pm (working copy)
@@ -121,6 +121,11 @@
                     require Win32;
                     $val = Win32::GetShortPathName($val);
                 }
+
+                if (!$val || !-e $val) {
+                    error "MP_AP_PREFIX must point to a valid directory.";
+                    die "\n";
+                }
             }

             if ($table->{$key}->{append}){




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message