Subject: Re: Kernel Make Problem
To: None <current-users@NetBSD.ORG>
From: Christos Zoulas <>
List: current-users
Date: 05/14/1995 18:03:07
In article <> (Dave Burgess) writes:
>>    Has anyone else had trouble linking kernels since the last sup or
>> two? On an i386 (it may be similar on other platforms, but I'm not
>> sure, hence the choice of list) make makes all the object files, but
>> on the link, or specifically on "${SYSTEM_LD} swapnetbsd.o", make
>> complains: "*** Error code 1". "make -i" appears to link a correct
>> kernel, but I haven't tested it yet. My suspicion is that this is a
>> side-effect of the sh changes, but that is just a guess.
>That supposition would dove-tail nicely something I have noticed over
>the past week or so that 'sh' seems to be dumping core about once or
>twice a day.  There is no consistent pattern, but my nightly news
>'daily' job seems to cause the dumps most often. 

Yup, this is my fault [not the core dumps, but the exit status problem].
I tried to fix the

$ x=`false`
$ echo $?

problem but unfortunately my one-line-fix broke

$ if [ "x" = "y" ]
> then
> 	x=1
> fi
$ echo $?


$ false
$ x=1
$ echo $?

There is no easy way to fix the exit status so that it behaves
correctly in all cases. I think I have a fix now, but I'll test it
some more before I claim success.

I have not seen any core-dumps, but it would be useful to compile the
shell with -g and see where it dies when it does.