Subject: Re: cpuconf.c undefined vlaues in kernel build (warning long details)
To: Chris G. Demetriou <cgd@cs.cmu.edu>
From: John C. Hayward <John.C.Hayward@wheaton.edu>
List: port-alpha
Date: 02/04/1997 22:28:04
On Tue, 4 Feb 1997, Chris G. Demetriou wrote:

> > > [ ... definitions in headers ... ]
> > > 
> > > (for a GENERIC kernel)
> > This is exactly what I get with a GENERIC kernel
> 
> That is, you have all of those definitions in all of those headers?
Here is what I get with the head of the dec*.h headers

docalpha:GENERIC {105} head dec*.h
==> dec_21000.h <==
#define NDEC_21000      0

==> dec_2100_a50.h <==
#define NDEC_2100_A50   1

==> dec_3000_300.h <==
#define NDEC_3000_300   1

==> dec_3000_500.h <==
#define NDEC_3000_500   1

==> dec_axppci_33.h <==
#define NDEC_AXPPCI_33  1

==> dec_eb164.h <==
#define NDEC_EB164      1

==> dec_kn20aa.h <==
#define NDEC_KN20AA     1
docalpha:GENERIC {106}

> 
> > > how are you trying to build the kernel?  i.e. what commands, exactly,
> > > are you trying to run?  it sounds like _something_ is going wrong.
> > in compile:
> > rm -rf GENERIC
> 
> shouldn't be necessary, but not unreasonable if you think something is
> being hokey.
> 
> > in config directory:
> > /usr/sbin/config GENERIC
> 
> That looks fine, assuming config is up today.
> 
> 
> > in compile/GENERIC:
> > make depend
> > make
> 
> since you're building from scratch, the 'make depend' isn't strictly
> necessary, but can't hurt.
> 
> 
> > Notes:
> > 1) the /usr/src is on a NFS directory running on NetBSD i386.
> > 2) Did a rdate just before make depend
> > 3) path variable does not inlcude /usr/sbin or /sbin
> 
> None of these should cause any problems, as far as i know.
> 
> 
> > Nothing pressing right now - I just wondered what I might be missing.
> 
> What errors do you see?  (I suppose i should have asked for these
> before...)
Here is what I get when I make the second time (first time generates
lots of stuff then failes here -- the second make starts off where
it failed last time)


docalpha:GENERIC {106} make
cc -g -O2 -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes
-Wno-format -mno-fp-regs -I. -I../../../../arch -I../../.../.. -nostdinc
-DEXEC_ECOFF -DEXEC_ELF64 -DEXEC_SCRIPT -DSWAPPAGER -DVNODEPAGER
-DDEVPAGER -DDEC_3000_500 -DDEC_3000_300 -DDEC_2100_A50 -DDEC_KN20AA
-DDEC_AXPPCI_33 -DDEC_EB164 -DTIMEZONE="5*60" -DDST="1" -DDEBUG
-DDIAGNOSTIC -DKTRACE -DFIFO -DFFS -DMFS -DNFSSERVER -DNFSCLIENT -DINET
-DCOMPAT_43 -DCOMPAT_10 -DCOMPAT_11 -DCOMPAT_12 -DLKM -DEISAVERBOSE
-DPCIVERBOSE -DTCVERBOSE -DUCONSOLE -DMAXUSERS=8 -D_KERNEL  -Dalpha  -c
../../../../arch/alpha/alpha/cpuconf.c
../../../../arch/alpha/alpha/cpuconf.c:81: `NDEC_3000_500' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:81: initializer element for
`cpusw[4].present' is not constant
../../../../arch/alpha/alpha/cpuconf.c:81: `NDEC_3000_500' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:81: initializer element for
`cpusw[4].model_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:81: `NDEC_3000_500' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:81: initializer element for
`cpusw[4].cons_init' is not constant
../../../../arch/alpha/alpha/cpuconf.c:81: `NDEC_3000_500' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:81: initializer element for
`cpusw[4].iobus_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:81: `NDEC_3000_500' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:81: initializer element for
`cpusw[4].device_register' is not constant
../../../../arch/alpha/alpha/cpuconf.c:91: `NDEC_3000_300' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:91: initializer element for
`cpusw[7].present' is not constant
../../../../arch/alpha/alpha/cpuconf.c:91: `NDEC_3000_300' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:91: initializer element for
`cpusw[7].model_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:91: `NDEC_3000_300' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:91: initializer element for
`cpusw[7].cons_init' is not constant
../../../../arch/alpha/alpha/cpuconf.c:91: `NDEC_3000_300' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:91: initializer element for
`cpusw[7].iobus_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:91: `NDEC_3000_300' undeclared here
(not in a function)
../../../../arch/alpha/alpha/cpuconf.c:91: initializer element for
`cpusw[7].device_register' is not constant
../../../../arch/alpha/alpha/cpuconf.c:105: `NDEC_2100_A50' undeclared
here (not in a function)
../../../../arch/alpha/alpha/cpuconf.c:105: initializer element for
`cpusw[13].present' is not constant
../../../../arch/alpha/alpha/cpuconf.c:105: `NDEC_2100_A50' undeclared
here (not in a function)
../../../../arch/alpha/alpha/cpuconf.c:105: initializer element for
`cpusw[13].model_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:105: `NDEC_2100_A50' undeclared
here (not in a function)
../../../../arch/alpha/alpha/cpuconf.c:105: initializer element for
`cpusw[13].cons_init' is not constant
../../../../arch/alpha/alpha/cpuconf.c:105: `NDEC_2100_A50' undeclared
here (not in a function)
../../../../arch/alpha/alpha/cpuconf.c:105: initializer element for
`cpusw[13].iobus_name' is not constant
../../../../arch/alpha/alpha/cpuconf.c:105: `NDEC_2100_A50' undeclared
here (not in a function)
../../../../arch/alpha/alpha/cpuconf.c:105: initializer element for
`cpusw[13].device_register' is not constant
*** Error code 1

Stop.
docalpha:GENERIC {116}  


> > > you might make sure your 'make' binary is up to date, as well. it
> couldn't be causing these problems, but it could cause you other
> problems later.
The make and config are pretty much uptodate.

What are the files which normally contain these defines?
johnh...
> 
> 
> 
> 
> cgd
>