lucy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marvin Humphrey <mar...@rectangular.com>
Subject Re: C90 vs C99
Date Thu, 14 Jan 2010 17:42:51 GMT
On Thu, Jan 14, 2010 at 10:39:20AM -0600, Peter Karman wrote:
>> A web search reveals that this is a GCC error, but it's unexpected because
>> GCC should be tolerant by default.  Do the flags that you're passing to GCC
>> include "-std=c90", "-std=C89", or "-ansi"?
> 
> no.

Hmm.  Does adding "-std=c99" make the problem go away?  Maybe GCC 3.x handled
this differently.

You can hack that flag into Build.pm quickly like so: 

marvin@smokey:~/projects/ks/perl $ svn diff buildlib/
Index: buildlib/KinoSearch/Build.pm
===================================================================
--- buildlib/KinoSearch/Build.pm    (revision 5679)
+++ buildlib/KinoSearch/Build.pm    (working copy)
@@ -48,7 +48,7 @@
 
 sub extra_ccflags {
     my $self          = shift;
-    my $extra_ccflags = "";
+    my $extra_ccflags = "-std=c99 ";
 
     if ( defined $ENV{KINO_DEBUG} ) {
         $extra_ccflags .= "-DKINO_DEBUG ";
marvin@smokey:~/projects/ks/perl $ 


Alternatively, 'export KINO_DEBUG=""' in bash to get the GCC debugging flags,
which include "-std=c99".

Marvin Humphrey


Mime
View raw message