Subject: -current kernel build failure
To: None <port-pmax@netbsd.org>
From: Terry R. Friedrichsen <terry@venus.sunquest.com>
List: port-pmax
Date: 12/08/1999 06:44:07
I dunno if I should bother reporting this, or to whom, so if I'm doing
this wrong, please flame.
I've been tracking the -current kernel for a few weeks now, doing a sup
and building from scratch overnight. For the last few days, the build
has been crapping out with:
==========
cc -O2 -Wall -Werror -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno-main -G 0 -mno-abicalls -mno-half-pic -I. -I../../../../arch -I../../../.. -nostdinc -I../../../../../gnu/sys -DMIPS1 -DLKM -DNKMEMCLUSTERS=1024 -DHZ=256 -DMAXUSERS=64 -D_KERNEL -Dpmax -c ../../../../arch/pmax/dev/rcons.c
cc1: warnings being treated as errors
../../../../arch/pmax/dev/rcons.c: In function `rcons_connect':
../../../../arch/pmax/dev/rcons.c:147: warning: passing arg 2 discards `const' from pointer target type
*** Error code 1
Stop.
==========
This is happening on the line:
if (ri.ri_depth == 8 && info->fi_type.fb_boardtype != PMAX_FBTYPE_MFB)
info->fi_driver->fbd_putcmap(info, rasops_cmap, 0, 256);
because "rasops_cmap" is "extern const u_char", and because the function
pointed to by fbd_putcmap is
int (*fbd_putcmap) __P ((struct fbinfo *, caddr_t, int, int));
in arch/pmax/include/fbvar.h.
(By the way, as one of the tiniest nits you'll ever see picked, fbvar.h does
not end with a newline ...).
I fixed this by casting rasops_cmap to caddr_t ...
The resultant kernel, built from sources supped at 0800 UTC on 12/08, fails
to load with an undefined reference to ibus_pmax_ca, so I'm going to go find
that next ...
FWIW, I'm running a stock 1.4.1 userland with an updated config(8) and new
configuration files based on GENERIC 1.56.
Terry R. Friedrichsen
terry@venus.sunquest.com