[opus] non-standard alloca.h
lrn1986 at gmail.com
Tue Nov 26 22:58:01 PST 2013
-----BEGIN PGP SIGNED MESSAGE-----
On 27.11.2013 10:40, Gregory Maxwell wrote:
> On Tue, Nov 26, 2013 at 10:35 PM, LRN wrote:
>> AFAIK, alloca.h is not POSIX. Here's a patch that includes
>> alloca.h only when it's really there. It also includes malloc.h,
>> which is where mingw-w64 defines the alloca() macro, mapping it
>> to gcc __builtin_alloca() or to msvcrt _alloca().
> This whole path is only triggered when the compiler is unable to
> use C99 var arrays. Did you actually bump into this with something
> that can use configure? (e.g. do we have a problem with the var
> array test someplace)
I do understand that C99 var-arrays are preferred (and are available).
However, i don't really remember whether alloca.h trips or doesn't
trip the configure process. I came up with this patch some time ago,
but didn't submit it.
I also don't have a non-C99-var-array-compliant toolchain at hand to
test the alloca path (well, i did try to patch configure.ac to pretend
that var-arrays are not available; results were as expected - opus
failed to build since [it thought] it had neither var-arrays, nor
alloca()), and i don't know at which point gcc started to support
var-arrays by default (without a --std=*99).  says it's been there
since 0.9, or maybe 4.5...
O< ascii ribbon - stop html email! - www.asciiribbon.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)
-----END PGP SIGNATURE-----
More information about the opus