2002-Mar-05
Going to try to build my CD!Installed cdrecord package (via pkgsrc) so I could use mkisofs. (This took almost five minutes.)
Set BUILD=1 and UPDATE=1 in /etc/mk.conf. Set DESTDIR and RELEASEDIR in the environment. (Good that I added a hard drive a few weeks ago.)
Under /usr/src/, "make obj" took 4m13s. (This was already done on 14/Feb/2002.) I had to be "root" for "make release", because it needs to chown. Now, I see I could have set "UNPRIVILEGED".
Its been over an hour and still going. I see it has built several kernels.
So it can just do the INSTALL or GENERIC kernel and not all, look at /usr/src/etc/Makefile and etc.${MACHINE}/Makefile.inc for EXTRA_KERNELS. (23/Jul/2002)
147 minutes into "make release" died with:
depend ===> utils/x_sh ... .//usr/src/distrib/utils/x_sh/mkinit: not foundIt shouldn't have had the "./" at the front of it. I did a "make clean" under /usr/src/distrib/utils/x_sh. I probably should have done some "make clean" or "make cleandir" before I started all this.
I did another "make release" and it did a bunch of stuff like:
includes ===> games/factor includes ===> games/fish ... install ===> share/man/man4/man4.mac68k install ===> share/man/man4/man4.macppcIt shouldn't have done all this (because I think it was already done before). And it did the MAKEDEV, but it also had already been done earlier. Then I saw it was building the GENERIC kernel again.
After a while, I killed it. I unset BUILD and UPDATE in the /etc/mk.conf. I tried without BUILD and UPDATE set, and then it really did do installs again.
So I set UPDATE=1 and did a "make release" again. I read in a posting that it is not a good idea unless doing repeated builds or you'll end up with crud in your build tree. Or don't set it when building from a fresh tree. (I wonder how much time it saves?)
The Makefile (but not mk/bsd.README) documents "BUILD_DONE". If it is set, then "make build" doesn't do anything -- so a "make release" can skip that step (if all binaries are already installed to $DESTDIR).
The "make release" is doing strips, makewhatis, installing /etc/ and /var/log files, MAKEDEV all, configuring kernels, and other already-done stuff.
The etc/Makefile documents "INSTALL_DONE". If it's set, then the "make install" into $DESTDIR will be skipped.
Well after about thirty minutes, "make release" died again with same error. I went into "distrib/" and did a "make", but it died with different error:
all ===> utils/sysinst/arch/i386 ... sed "s/@@VERSION@@/1.5.3_ALPHA/" /usr/src/distrib/utils/sysinst/arch/i386/../../msg.mi.en /usr/src/distrib/utils/sysinst/arch/i386/msg.md.en msgtouch > /usr/src/distrib/utils/sysinst/arch/i386/msg.def msgc msg.def msgc: could not open msg.def.
So I did a "make distclean" under /usr/src/distrib and I removed /usr/obj/distrib/. Then I did a "make build" instead of "make release". (Maybe I should have done "make obj" again with UPDATE not set.)
While building I see that the distrib/utils directories contain a lot of object files. I thought "make cleandir" cleaned this up. A "make clean" under distrib/utils did it. (I did this while "make build" was running.)
This "make build" took 18 minutes. Then did a "make release" again. And 41 minutes later, it failed with:
all ===> i386/floppies/fdset ... vnconfig -t floppy3 -v -c /dev/vnd0d boot1.fs.tmp vnconfig: unknown disk type: floppy3 *** Error code 1
This vnconfig -t uses a type from /etc/disktab. My /etc/disktab only had one entry for "mydisk2|NetBSD installation generated". So I used my script to update my /etc (which I should have done when I last updated):
NEW=/backups/netbsd/destdir/etc/ ./update_etc.sh
(I deleted old /usr/src/netbsd/install and release from 31/Jan/2001 and freed up a bunch of space.)
The new /etc/disktab has "floppy3", so trying "make release" again! 46 minutes later it was finished.
Now to build X. First, I updated via cvs in xsrc/: "cvs update -A -d -P". This took 44 minutes. Then I unset UPDATE (so it would do a "cleandir"). Then "make build". It took 76 minutes.