[svn:PHP-Sandwich] r12058 - PHP-Sandwich/trunk

[email protected] Sun, 9 Nov 2008 10:08:11 -0800 (PST)
Newsgroups perl.php.sandwich.dev
Message-ID <[email protected]>
Author: aff
Date: Sun Nov  9 10:08:03 2008
New Revision: 12058

Modified:
   PHP-Sandwich/trunk/Makefile.PL

Log:
sub check_header:  Consider as directories only those args 
starting with '-I'. 


Modified: PHP-Sandwich/trunk/Makefile.PL
==============================================================================
--- PHP-Sandwich/trunk/Makefile.PL	(original)
+++ PHP-Sandwich/trunk/Makefile.PL	Sun Nov  9 10:08:03 2008
@@ -22,8 +22,9 @@
   die "Need an argument" if !$inc;
   print "Checking header files...\n";
 
-  # Replace -I at beginning of string and chop of newline character
-  my @incdirs = map { s/^-I//g; chomp; $_ } split(/ /, $inc);
+  # Consider as directories only those args starting with '-I' 
+  my @incdirs = grep(/^-I/, split(/ /, $inc));
+  @incdirs = map { s/^-I//g; chomp; $_ } @incdirs;
 
   for (@incdirs) {
     die "No such directory: '$_'" if (!-d);