Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Mar 2009 00:44:08 -0400
From:      David Schultz <das@FreeBSD.ORG>
To:        Doug Barton <dougb@FreeBSD.ORG>
Cc:        ports@FreeBSD.ORG, Gustau Perez <gperez@entel.upc.edu>, freebsd-current@FreeBSD.ORG
Subject:   Re: Inline definition problem in current
Message-ID:  <20090325044408.GB17442@zim.MIT.EDU>
In-Reply-To: <49C9A7B4.3080509@FreeBSD.org>
References:  <49C80DBA.80407@entel.upc.edu> <20090325033451.GA17442@zim.MIT.EDU> <49C9A7B4.3080509@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Mar 24, 2009, Doug Barton wrote:
> David Schultz wrote:
> > On Mon, Mar 23, 2009, Gustau Perez wrote:
> >>  a few time ago I switched to current, right now I've it updated to 
> >> yesterday.  While compiling some ports (in fact, building x11/gnome2) I 
> >> found that some of them (written in C) are using  some inline functions 
> >> (I guess it is because the compiler will replace the call to the 
> >> function with the function itself). The problem is that gcc fails with 
> >> the following message :
> >>        
> >>        error: nested function 'XXX' declared but never defined
> >>
> >>   checking the code, the function is declared and then implemented in a 
> >> header file which is included in the offending .c file. The function is 
> >> declared as 'inline'. The only solution I found is to change the 
> >> definition to static.
> >>
> >>   Checking pontyhat shows me that many ports are failing because of 
> >> this problem. What I can understand is why is this happening, because 
> >> the same ports compiles fine in STABLE and the compilers's version in 
> >> base seems to be the same (gcc (GCC) 4.2.1 20070719  [FreeBSD], the same 
> >> in current) 
> > 
> > Which other ports were broken for this reason?
> 
> I am trying to compile gimp on -current right now and x11/babl and
> graphics/gegl both have this problem. Take a look at
> http://pointyhat.freebsd.org/errorlogs/i386-8-failure.html for more
> examples (click on the link on the right under Package to see the
> logs). There are currently over 600 broken ports in -current, all the
> ones I clicked on in a completely bogus sample had this same problem.

My bug; I missed an important line when merging from gcc trunk 122565.
Instead of reporting:

    error: nested function 'foo' declared but never defined

gcc should have been reporting:

    warning: inline function 'foo' declared but never defined

I'll check in a fix as soon as I run a buildworld.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090325044408.GB17442>