develooper Front page | perl.perl5.porters | Postings from July 2001

[PATCH 5.7.2] Allow for GNU-isms in h2xs

From:
Ilya Zakharevich
Date:
July 31, 2001 02:34
Subject:
[PATCH 5.7.2] Allow for GNU-isms in h2xs
Message ID:
20010731053438.A1754@math.ohio-state.edu
Enjoy,
Ilya

--- ./utils/h2xs.PL.orig	Thu Feb 22 18:57:58 2001
+++ ./utils/h2xs.PL	Tue Jul 31 02:28:24 2001
@@ -697,8 +697,9 @@ if( ! $opt_X ){  # use XS, unless it was
 	$filter = $';
       }
       warn "Scanning $filename for functions...\n";
+      my @styles = $Config{gccversion} ? qw(C++ C9X GNU) : qw(C++ C9X);
       $c = new C::Scan 'filename' => $filename, 'filename_filter' => $filter,
-	'add_cppflags' => $addflags, 'c_styles' => [qw(C++ C9X)];
+	'add_cppflags' => $addflags, 'c_styles' => \@styles;
       $c->set('includeDirs' => ["$Config::Config{archlib}/CORE"]);
 
       push @$fdecls_parsed, @{ $c->get('parsed_fdecls') };



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