autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: alloca redefinition on freebsd


From: Ralf Wildenhues
Subject: Re: alloca redefinition on freebsd
Date: Tue, 28 Jul 2009 20:59:31 +0200
User-agent: Mutt/1.5.20 (2009-06-15)

Hello Vincent,

* Vincent Torri wrote on Tue, Jul 28, 2009 at 10:53:42AM CEST:
> if one uses AC_FUNC_ALLOCA, the autoconf documentation gives the way
> to correctly define alloca.
> 
> On FreeBSD, alloca is already defined in stdlib.h. So if stdlib.h is
> included before that piece of code, a warning is displayed by gcc.
> 
> Shouldn't a guard be added in the piece of code of the docmentation
> of AC_FUNC_ALLOCA in order to avoid that warning (like #ifndef
> alloca etc...) ?

Well, there is already a guard, but it is in text not in code:

     Source files that use `alloca' should start with a piece of code
     like the following, to declare it properly.

Or do you also get an error if you move that piece of code before the
stdlib.h include?

Cheers,
Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]