Naopic Tastalian | 18 Jun 2005 18:21
Picon
Favicon

Kernel compilation for -current

Hello everyone,

I moved to -current in order to solve my problem with mfs and /dev partition.
/sbin/init source looked ok, so I built tools and tried to crosscompile the
kernel with build.sh, but now it fails to make depend :

[...]

cc1: Invalid option '-Wreturn-type'

*** Failed target:  assym.h
*** Failed command: cat /usr/src/sys/arch/mips/mips/genassym.cf |
/usr/src/tooldir.NetBSD-2.0.2-i386/bin/nbgenassym --
/usr/pkg/cross-ps2/bin/mipsEEel-netbsd-gcc -mcpu=r5900 -mips1 -fno-pic
-D__NetBSD__ -Ulinux -U__linux__ -U__linux -G 48 -mno-abicalls -msoft-float
-ffreestanding -Os -mmemcpy -Werror -Wall -Wno-mail -Wno-format-zero-lenght
-Wpointer-arith -Wmissing-prorotypes -Wstrict-prototypes -Wreturn-type -Wswitch
-Wshadow -Wcast-qual -Wwrite-strings -Wno-sign-compare -Wno-uninitialized
-Dplaystation2 -I. -I/usr/src/sys/arch -I/usr/src/sys -nostdinc -DMIPS3
-DMIPS3_5900 -DIPL_ICU_MASK -DSOFTFLOAT -D__NO_LEADING_UNDERSCORES__
-D__GP_SUPPORT__ -DALTQ_PRIQ -DMAXUSERS=16 -D_KERNEL -D_KERNEL_OPT
-I/usr/src/sys/dist/ipf > assym.h.tmp && mv -f assym.h.tmp assym.h
*** Error code 1

[...]

The same error occurs with any kernel configuration.

tastalian

(Continue reading)

Martin Husemann | 19 Jun 2005 00:57
Picon

Re: Kernel compilation for -current

On Sat, Jun 18, 2005 at 06:21:39PM +0200, Naopic Tastalian wrote:
> cc1: Invalid option '-Wreturn-type'

I think I just fixed that in revision 1.68 of sys/conf/Makefile.kern.inc.

Martin

Ed Schouten | 18 Jun 2005 19:50
Picon

Re: Kernel compilation for -current

Hello Naopic,

* Naopic Tastalian <tastalian <at> free.fr> wrote:
> cc1: Invalid option '-Wreturn-type'

After some Googling, I found the following quote on a Linux From Scratch
mailing list:

| As most of you know, the -Wreturn-type (and -Wno-return-type) options
| do not work for GCC 2.95.3 when it's compiled with just the C backend.
| Because of this we build the C++ backend as well in the book.

(see http://linuxfromscratch.org/pipermail/lfs-dev/2003-May/035076.html)

This site also has a patch for GCC 2.95, so good luck :)

Yours,
--

-- 
 Ed Schouten <ed <at> fxq.nl>

Gmane