Subject: Re: compiling -std=c99 on cobalt fails with alloca
To: None <>
From: Izumi Tsutsui <>
List: port-cobalt
Date: 08/30/2006 04:41:11 wrote:

> If NetBSD/cobalt (same with pmax - maybe all mipsel?) doesn't compile
> $ gcc -std=c99 foo.c
> (with the aforementioned alloca() call in foo.c)
> ...while NetBSD/i386 (and OpenBSD/i386, etc) does, then somebody has an 
> error. I see that you've commented on this in the past; would you call 
> this a bug on the other systems viz. conformance to c99?

Not all archs have alloca(3) in libc:
% find /usr/src/lib/libc -name alloca\* -print
and alloca(3) says:
>>     The alloca() function is machine dependent; its use is discouraged.

> On a related note, shouldn't this bail on compilation, and not on linking?

You could still prepare your own alloca() (like gcc's builtin) for mips.
Izumi Tsutsui