GCC 3.3.2 kernel

Joerg Sonnenberger joerg at britannica.bec.de
Wed Oct 29 10:22:45 PST 2003


On Tue, Oct 28, 2003 at 11:32:49PM -0500, Craig Dooley wrote:
> Heres a patch that gets the kernel closer to being built with gcc 3.3.2 from 
> ports.  The kernel compiles and runs with gcc 2.95 also as of now, but there 
> are changes to drivers I cannot test (if_ray and if_wx that i can think of) 
> but I think all the changes deal with either string tokenization or multiline 
> strings, so I dont think there should be any problems.  The kernel still 
> cannot be built with gcc 3.3.2 though.  When using buildkernel, it gets to 
> linking kernel.debug and dies with MANY undefined references to puts and 
> putchar.  When using config; make depend; make it dies in make depend.  The 
> first pass in aic7xxx/aicasm goes fine, but the second pass dies with missing 
> headers and sure enough the headers it wants are not in compile/TRAGEDY/usr/
> src/sys/...  I'm looking into those.

puts and putchar results from optimizations of printf and alike.
Try adding -ffreestanding to CFLAGS. Another important flag is
-fno-strict-aliasing, the strict aliasing is not active with -O1,
but it should be there just in case.

Joerg

> 
> -Craig
> -- 
> Craig Dooley											cd5697 at xxxxxxxxxx









More information about the Submit mailing list