Date: Tue, 20 Dec 2005 12:19:11 -0500 From: Craig Rodrigues <rodrigc@crodrigues.org> To: delphij@delphij.net Cc: freebsd-current@FreeBSD.org Subject: Re: gcc4 Message-ID: <20051220171911.GA32051@crodrigues.org> In-Reply-To: <a78074950512200128p354ff67bnc2e7f83c27fb445a@mail.gmail.com> References: <43A7BF25.6040901@freebsd.org> <a78074950512200128p354ff67bnc2e7f83c27fb445a@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Dec 20, 2005 at 05:28:48PM +0800, Xin LI wrote: > Is our tree gcc4-safe already? I have not checked for this for a long time... Not really. The kernel mostly compiles with gcc40 from ports (I used gcc 4.0.2) if you compile with these flags set: WERROR= NO_WERROR=1 CC=/usr/local/bin/gcc40 and if you apply this patch: http://people.freebsd.org/~rodrigc/gcc40_makefiles_diff.txt You get lots of compilation warnings, mostly about comparing signed/unsigned pointers, such as the ones here: http://people.freebsd.org/~rodrigc/gcc40_warnings.txt There is at least one compilation error: In file included from /usr/src/sys/kern/sched_4bsd.c:56: ./machine/smp.h:36: error: array type has incomplete element type cc1: warnings being treated as errors In file included from /usr/src/sys/kern/subr_smp.c:50: ./machine/smp.h:36: error: array type has incomplete element type In file included from /usr/src/sys/i386/i386/local_apic.c:59: ./machine/smp.h:36: error: array type has incomplete element type In file included from /usr/src/sys/i386/i386/mp_watchdog.c:46: ./machine/smp.h:36: error: array type has incomplete element type The line causing the problem I think is this one in smp.h: extern struct pcb stoppcbs[]; I think the way things are inclu I did not try a buildworld with gcc4.0. -- Craig Rodrigues rodrigc@crodrigues.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051220171911.GA32051>