UPDATING revision 1.384
1$NetBSD: UPDATING,v 1.384 2025/10/20 10:14:07 martin Exp $
2
3This file (UPDATING) is intended to be a brief reference to recent
4changes that might cause problems in the build process, and a guide for
5what to do if something doesn't work.
6
7For a more detailed description of the recommended way to build NetBSD
8using build.sh, see the BUILDING file.
9
10Note that much of the advice in this UPDATING file was written before
11build.sh existed.  Nevertheless, the advice here may be useful for
12working around specific problems with build.sh.
13
14Sections are marked with "^^^^^".  After the section on "Recent changes"
15are several sections containing more general information.
16
17See also: BUILDING, build.sh, Makefile.
18
19Recent changes:
20^^^^^^^^^^^^^^^
21
2220251019:
23	Changes to how libcrypto got linked (libpthread not required
24	any more) cause failures in update builds. To fix, run
25	(as your build user) a "make cleandir" in the following
26	subdirectories:
27
28	crypto/external/apache2/openssl
29	crypto/external/bsd/heimdal
30	crypto/external/bsd/netpgp
31	crypto/external/bsd/openssh
32	external/bsd/libfido2
33	external/bsd/nsd
34	external/bsd/ntp
35	external/bsd/pam-u2f
36	external/bsd/ppp
37	external/bsd/tcpdump
38	external/bsd/wpa
39	games/factor
40	libexec/httpd
41	tests/crypto/libcrypto
42	tests/lib/libc/hash
43	usr.bin/dc
44	usr.bin/ftp
45	usr.bin/moduli
46	usr.bin/nbsvtool
47	usr.sbin/plainrsa-gen
48	usr.sbin/syslogd
49
5020250721:
51	GCC 12.5 was imported and there may be weird build issues.
52	Clean any GCC build dirs if you encounter weird things.
53
5420250720:
55	New openssl and old objects for tests for libcrypto may
56	cause spurious test failure, clean the src/tests/crypto/libcrypto
57	object dirs.
58
5920250528:
60	Changes in the tools build require removing all config.cache
61	files in the object tools directories.
62
6320250427:
64	The KERNEL_DIR option to build.sh is now functional.  Set it
65	with ``-V KERNEL_DIR=yes'' on your build.sh command.
66	With this, you can now colocate kernel and associated modules
67	in /netbsd/{kernel,kernel.dbg,modules} instead of having the
68	kernel in / but modules in /stand.
69
70	Note that you'll need new bootstrap code to use this feature.
71
72	This completes work begun many years ago by christos@ :-)
73
7420250413:
75	A change to bsd.lib.mk requires a clean build of all libraries.
76
7720250131:
78	The switch to the new jemalloc requires cleaning in libc.
79
8020241122:
81	Changes to various libraries' build options require cleaning
82	their objdirs in update builds:
83
84	cd external/bsd/file/lib && $TOOLDIR/bin/nbmake-$ARCH clean
85	cd external/bsd/libarchive/lib && $TOOLDIR/bin/nbmake-$ARCH clean
86	cd external/public-domain/xz/lib && $TOOLDIR/bin/nbmake-$ARCH clean
87
88	Also, for architectures with MKCOMPAT, it is necessary to clean
89	the compat objdirs too.  The easiest way is:
90
91	rm -rf OBJDIR/compat/*/*/external/bsd/file/lib
92	rm -rf OBJDIR/compat/*/*/external/bsd/libarchive/lib
93	rm -rf OBJDIR/compat/*/*/external/public-domain/xz/lib
94
95	Changes to bsd.lib.mk to improve detecting differences in
96	shared library symbol exports may cause some .actsym files in
97	the objdir to become stale in update builds.
98
99	To work around this, delete all files matching `*.actsym' in
100	the objdir.  For example:
101
102	find OBJDIR -name '*.actsym' -type f -print0 | xargs -0 rm
103
10420241104:
105	Changes around the integration of the zstd compression
106	library may require manual deletion of some object directories
107	if you update from a build from a few days ago:
108	rm -rf DESTDIR/usr/lib/*/libarchive*
109	rm -rf DESTDIR/usr/lib/*/libmagic*
110	rm -rf DESTDIR/usr/lib/*/libzstd*
111	rm -rf DESTDIR/usr/lib/libarchive*
112	rm -rf DESTDIR/usr/lib/libmagic*
113	rm -rf DESTDIR/usr/lib/libzstd*
114	rm -rf OBJDIR/compat/*/*/external/bsd/file/
115	rm -rf OBJDIR/compat/*/*/external/bsd/libarchive/
116	rm -rf OBJDIR/compat/*/*/external/bsd/zstd/
117	rm -rf OBJDIR/external/bsd/file/
118	rm -rf OBJDIR/external/bsd/libarchive/
119	rm -rf OBJDIR/external/bsd/zstd/
120	rm -rf OBJDIR/external/gpl3/gcc/
121	rm -rf OBJDIR/tools/gcc/
122
12320240926:
124	Building -current when running on amd64 from about 20240924
125	to about 20240926 will not work due to a "malloc_np.h"
126	error. Please downgrade to a version from 20240924 or older,
127	or upgrade to a newer version e.g. using a binary release from
128	the NetBSD build servers.
129
13020240923:
131	Update builds will require cleaning the object directories for
132	jemalloc (like: "rm -rf $OBJ/external/bsd/jemalloc*") and the
133	libc dependency files (like: "rm $OBJ/lib/libc/jemalloc.*").
134	On architectures with COMPAT libs, those also have to be cleaned,
135	e.g. on sparc64: "rm -rf $OBJ/compat/sparc64/sparc/external/bsd/jemalloc*"
136	and "rm $OBJ/compat/sparc64/sparc/lib/libc/jemalloc.*".
137
13820240920:
139	Update builds will require cleaning in src/external/historical/nawk/bin
140	in order to remove the awk subdirectory since there is now a binary
141	called awk.
142
14320240817:
144	Update builds will require cleaning in src/external/historical/nawk/bin
145	in order to remove the awk binary since now there is a subdirectory
146	called awk.
147
14820240812:
149	Update builds will require removing the tools objdir for gdb
150	if building with MKCROSSGDB=yes. All architectures use gdb.old
151	now.
152
15320240630:
154	Update builds will require removing the tools objdir for binutils
155	(as most architectures should use binutils.old now).
156
15720240610:
158	Update builds are likely to require removing the objdir for
159	distrib/<arch>/cdroms - or at least references to libarchive
160	from within there after the recent libarchive update.
161
16220240504:
163	Update builds on x86 require making the `cleandir' target in
164	lib/libm, or deleting the objdir for lib/libm.
165
16620240423:
167	Update builds with x11 may fail after switching to Mesa 21.
168
16920240410:
170	Update builds may require manually deleting
171	$DESTDIR/var/run/named (and, potentially,
172	$DESTDIR/var/run/lwresd) in order to avoid checkflist failure.
173
17420240409:
175	32-bit compatibility libraries were moved into the base32
176	and debug32 sets.  HTML man pages were moved into the manhtml set.
177
17820230828:
179	If:
180        - you updated to current and ran postinstall between 20230826
181	  and 20230828 inclusive, and
182        - you are not using anything outside the base system to
183	  populate /etc/openssl/certs (e.g., manually adding
184	  certificates or using ca-certificates or mozilla-rootcerts or
185	  mozilla-rootcerts-openssl from pkgsrc),
186	delete /etc/openssl/certs and rerun postinstall or just
187	`certctl rehash'.
188
189	Otherwise, certctl(8) will think someone else has left
190	/etc/openssl/certs in the way and will avoid clobbering it on
191	upgrade from older NetBSD.
192
19320230718:
194	build.sh will use mk.conf in the same directory as build.sh instead
195	of /etc/mk.conf, unless MAKECONF is already defined in the environment.
196
19720230714:
198	Import of gcc 10.5 requires a clean build of at least tools/gcc
199	and external/gpl3/gcc* object directories. An update build
200	without cleaning will result in obscure failures in rare corner
201	cases.
202
20320230604:
204	Building native kernels with the installed make(1) instead of
205	the $TOOLDIR/bin/nbmake-${arch} wrapper will fail if userland
206	has not been updated. Note that this is an unsupported build
207	configuration (but usually works if userland is -current enough).
208
20920230523:
210	ctfmerge was fixed as macOS host tool. This may require a clean tools
211	rebuild to detect the update to tools/compat/configure.
212
21320230515:
214	New openssl build requires removal of the crypto/external/bsd/openssl
215	and tests/crypto/libcrypto subdirectories in the ${OBJDIR} hierarchy.
216	Otherwise test results may be wrong due to wrong "golden" output
217	files being installed.
218
21920230322:
220	Fixes for moved /lib/libisns* mean that builds will complain about
221	./usr/lib/libisns* being missing until src/lib/libisns is forced
222	to (re)install the files, including the symlinks.  The simplest
223	way is to clean this subdir before building.
224
22520230112:
226	New binutils require an updated ld.elf_so. If you are doing
227	(unsupported) in-place self builds (with the -E flag to build.sh),
228	make sure to have installed latest ld.elf_so before you rebuild
229	userland.
230
23120221116:
232	The addition to NetBSD's version of UFS2 of support for extended
233	attributes broke backward compatibility with previous releases
234	of NetBSD, so UFS2 has been restored to being compatible with
235	previous NetBSD releases by disabling extended attributes.
236	(Note that ACLs are implemented as extended attributes, so
237	this changes disables ACLs as well.)
238
239	Support for UFS2 with extended attributes is now available in a new
240	UFS variant called UFS2ea.  If you have created extended attributes
241	in an original UFS2 file system then "fsck -p" will now fail due to
242	the unexpected presence of extended attributes and "fsck -y" will
243	remove all extended attributes.  If you wish to preserve extended
244	attributes rather than delete them, there is a utility to convert
245	a UFS2 file system to UFS2ea and leave extended attributes in place,
246	but this should be used with caution since it will preserve any
247	extended attributes that have been corrupted by the backward
248	incompatibility too.
249
250	If you wish to use a UFS2ea file system as your root file system,
251	then you will need to update your boot loader to a version that
252	supports UFS2ea.
253
254	For more information, see:
255	https://wiki.netbsd.org/features/UFS2ea
256
25720221111:
258	The new libdrm import worsened the conflict issues for the
259	kdump/ktruss ioctl, and i915 now conflicts with base, and has
260	been turned off.  This will cause update build issues like:
261
262		kdump-ioctl.c:12175:143: error: 'DRM_IOCTL_I915_DESTROY_HEAP'
263		   undeclared here (not in a function);
264		   did you mean 'DRM_IOCTL_MODE_DESTROY_DUMB'?
265
266	You'll need to clean usr.bin/ktruss, usr.bin/kdump, and rescue.
267
26820220921:
269	Since the kernel version was bumped to 9.99.100, the bootloader
270	must be updated on x86 or EFI boot platforms in order to load
271	modules from boot.cfg(5) or interactively at the bootloader
272	prompt.
273
274	The kernel can still load modules at runtime, with modload(8)
275	or modules.conf(5), with no bootloader update.  This will not
276	affect release branches because it only applies to patch
277	numbers >=100.
278
279	On x86 (i386 or amd64) with BIOS boot, this requires copying a
280	new /usr/mdec/boot to /boot.  You can build this in the destdir
281	by running `$TOOLDIR/bin/nbmake-$ARCH dependall install' in
282	sys/arch/i386/stand.
283
284	On platforms with EFI boot (including x86 with EFI boot), this
285	requires copying a new /usr/mdec/boot*.efi to the EFI/BOOT/
286	directory on the EFI system partition.  The boot*.efi file is:
287
288	aarch64	bootaa64.efi
289	amd64	bootx64.efi
290	arm	bootarm.efi	(32-bit arm)
291	i386	bootx32.efi
292
293	You can build this in the destdir by running
294	`$TOOLDIR/bin/nbmake-$ARCH dependall install' in
295	sys/stand/efiboot/boot*.
296
29720220821:
298	Support for building extsrc/ has been deprecated.
299	EXTSRCSRCDIR and MKEXTSRC have been deprecated.
300
30120220714:
302	Updates to xorg-server and associated drivers may cause builds to
303	fail.  Cleaning both DESTDIR and the xorg build tree may be needed.
304
30520220628:
306	Changes in the build of src/games/robots require a clean build
307	of that program.
308
30920211116:
310	Changes in the xorg build require clean obj dirs for external/mit/xorg
311	(or a full clean/non-update build).
312
31320211112:
314	Device tree sources were updated for evbarm.  Some device nodes
315	(in particular, ld(4) devices on the ROCKPro64) will be renumbered.
316
31720211014:
318	MKPIE default for aarch64 has changed, a clean build is required.
319
32020210917:
321	Changed MNT_ACLS to default to POSIX1e ACLs instead of NFSv4
322	ACLs, to be compatible with FreeBSD. If you are using NFSv4 ACLs
323	and have "acls" in /etc/fstab you'll need to change it to "nfs4acls".
324
32520210711:
326	Updated GMP sources may require cleaning in tools/gmp and/or in
327	external/lgpl3/gmp/lib, particularly if GCC itself does not build.
328
32920210417:
330	GCC 10 was enabled for several platforms.  If builds fail in either
331	tools/gcc or external/gpl3/gcc, first try cleaning those objects and
332	removing the $DESTDIR/usr/include/g++ subdirectory.
333
33420201016:
335	MIPS kernel modules have been disabled until they work.  This will
336	turn up in extra files in the DESTDIR, which should be cleaned.
337
33820200925:
339	GNU MPC and MPFR have been updated.  At least MPFR needs cleaning
340	in both the tools and external dirs.
341
34220200912:
343	GCC 9 has arrived for Arm and x86 platforms, and will be coming
344	for several more, as will binutils 2.34.  Clean as required.
345
34620200907:
347	GCC 9 is coming, and binutils has been updated for MIPS.  This
348	probably requires cleaning the tools/binutils.
349
35020200811:
351	GCC updates may require cleaning the objdir.  This may occur
352	due to GCC 7.5 update, GCC 8.4 move to gcc.old, or the upcoming
353	GCC 9 upgrade.
354
35520200614:
356	blacklist* has been renamed to blocklist*. postinstall(8)
357	should handle the migration.
358
35920200601:
360	Due to a mistake in LIBISPRIVATE handling, .so libraries were
361	created in the build directories and need cleaning.
362
36320200311:
364	GCC 8 ports will need cleaning in src/tools/gcc and
365	src/external/gpl3/gcc due to GCC 8.4 update.
366
36720191118:
368	More architectures were switched to gcc8:
369	    i386, ia64 powerpc64, sparc, sparc64, arm
370	The same comments as in 20191022 apply.
371
37220191112:
373	The LLVM update requires a clean rebuild for all architectures using
374	LLVM during the tools build phase (i386, amd64, aarch64).
375
37620191022:
377	Ports amd64 and aarch64 switched to GCC 8.3 by default.
378	In-place ("expert mode", build.sh -E) builds are not supported
379	when going from a GCC 7 userland to GCC 8. Do a regular
380	build to a different DESTDIR (or preferably: build.sh -U) at least
381	once and install sets, or download comp.{tar.xz,tgz} from the
382	daily builds and install that before doing the next in-place build.
383
38420191001:
385	GCC 8.3 was imported.  Builds of src/tools/gcc may fail if
386	old builds with GCC 7 output now uses GCC 8.  Clean this
387	directory, and also clean src/external/gpl3/gcc.
388
38920190903:
390	Files with names that coincide with existing files' names on
391	case-insensitive file systems were inadvertently committed, for
392	radeon GPU firmware.  We cannot mark these as obsolete for
393	postinstall to fix, so if you updated src since 2019-08-26, and
394	ran build.sh distribution or ran build.sh release, you must
395	manually delete the following files in your DESTDIR (which is
396	usually $OBJDIR/destir.$ARCH), or from / if you have installed
397	them:
398
399		/libdata/firmware/radeon/bonaire_ce.bin
400		/libdata/firmware/radeon/bonaire_mc.bin
401		/libdata/firmware/radeon/bonaire_me.bin
402		/libdata/firmware/radeon/bonaire_mec.bin
403		/libdata/firmware/radeon/bonaire_pfp.bin
404		/libdata/firmware/radeon/bonaire_rlc.bin
405		/libdata/firmware/radeon/bonaire_sdma.bin
406		/libdata/firmware/radeon/bonaire_smc.bin
407		/libdata/firmware/radeon/bonaire_uvd.bin
408		/libdata/firmware/radeon/hainan_ce.bin
409		/libdata/firmware/radeon/hainan_mc.bin
410		/libdata/firmware/radeon/hainan_me.bin
411		/libdata/firmware/radeon/hainan_pfp.bin
412		/libdata/firmware/radeon/hainan_rlc.bin
413		/libdata/firmware/radeon/hainan_smc.bin
414		/libdata/firmware/radeon/hawaii_ce.bin
415		/libdata/firmware/radeon/hawaii_mc.bin
416		/libdata/firmware/radeon/hawaii_me.bin
417		/libdata/firmware/radeon/hawaii_mec.bin
418		/libdata/firmware/radeon/hawaii_pfp.bin
419		/libdata/firmware/radeon/hawaii_rlc.bin
420		/libdata/firmware/radeon/hawaii_sdma.bin
421		/libdata/firmware/radeon/hawaii_smc.bin
422		/libdata/firmware/radeon/kabini_ce.bin
423		/libdata/firmware/radeon/kabini_me.bin
424		/libdata/firmware/radeon/kabini_mec.bin
425		/libdata/firmware/radeon/kabini_pfp.bin
426		/libdata/firmware/radeon/kabini_rlc.bin
427		/libdata/firmware/radeon/kabini_sdma.bin
428		/libdata/firmware/radeon/kaveri_ce.bin
429		/libdata/firmware/radeon/kaveri_me.bin
430		/libdata/firmware/radeon/kaveri_mec.bin
431		/libdata/firmware/radeon/kaveri_mec2.bin
432		/libdata/firmware/radeon/kaveri_pfp.bin
433		/libdata/firmware/radeon/kaveri_rlc.bin
434		/libdata/firmware/radeon/kaveri_sdma.bin
435		/libdata/firmware/radeon/mullins_ce.bin
436		/libdata/firmware/radeon/mullins_me.bin
437		/libdata/firmware/radeon/mullins_mec.bin
438		/libdata/firmware/radeon/mullins_pfp.bin
439		/libdata/firmware/radeon/mullins_rlc.bin
440		/libdata/firmware/radeon/mullins_sdma.bin
441		/libdata/firmware/radeon/oland_ce.bin
442		/libdata/firmware/radeon/oland_mc.bin
443		/libdata/firmware/radeon/oland_me.bin
444		/libdata/firmware/radeon/oland_pfp.bin
445		/libdata/firmware/radeon/oland_rlc.bin
446		/libdata/firmware/radeon/oland_smc.bin
447		/libdata/firmware/radeon/pitcairn_ce.bin
448		/libdata/firmware/radeon/pitcairn_mc.bin
449		/libdata/firmware/radeon/pitcairn_me.bin
450		/libdata/firmware/radeon/pitcairn_pfp.bin
451		/libdata/firmware/radeon/pitcairn_rlc.bin
452		/libdata/firmware/radeon/pitcairn_smc.bin
453		/libdata/firmware/radeon/tahiti_ce.bin
454		/libdata/firmware/radeon/tahiti_mc.bin
455		/libdata/firmware/radeon/tahiti_me.bin
456		/libdata/firmware/radeon/tahiti_pfp.bin
457		/libdata/firmware/radeon/tahiti_rlc.bin
458		/libdata/firmware/radeon/tahiti_smc.bin
459		/libdata/firmware/radeon/verde_ce.bin
460		/libdata/firmware/radeon/verde_mc.bin
461		/libdata/firmware/radeon/verde_me.bin
462		/libdata/firmware/radeon/verde_pfp.bin
463		/libdata/firmware/radeon/verde_rlc.bin
464		/libdata/firmware/radeon/verde_smc.bin
465
466	We will re-import these radeon firmware images another way
467	later.
468
46920190727:
470	The uefi bootloader has gained tftp support and needs a clean
471	build. If you do update builds, manually clean its object
472	directory by something like:
473	cd sys/arch/i386/stand/efiboot && make clean
474
47520190723:
476	The jemalloc allocator in libc is now built without extended
477	debugging (for performance reasons). In update builds make sure
478	to rebuild it completely, by removing all affected object files,
479	including compat builds, something like:
480	cd /usr/obj && find . -type d -name jemalloc|xargs rm -rf
481
48220190207:
483	GCC 7 switched for many ports.  Update builds are likely to fail.
484
485Hints for a more successful build:
486^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
487    Use build.sh, but do not use its "expert mode":
488	This will automatically build the tools in the
489	   correct order, and it will keep the tools and the
490	   new build products from interfering with the running
491	   system.  This will allow you to ignore most of the
492	   other advice in this file.
493    Build a new kernel first:
494	This makes sure that any new system calls or features
495	   expected by the new userland will be present.  This
496	   helps to avoid critical errors when upgrading.
497    Use object directories:
498	This helps to keep stale object
499	   files from polluting the build if a Makefile "forgets"
500	   about one.  It also makes it easier to clean up after
501	   a build.  It's also necessary if you want to use the
502	   same source tree for multiple machines.
503	   To use object directories with build.sh:
504	    a) invoke build.sh with the "-M" or "-O" options.
505	   To use object directories without using build.sh:
506	    a) cd /usr/src ; make cleandir
507	    b) Add "OBJMACHINE=yes" to /etc/mk.conf
508	    c) Add "MKOBJDIRS=yes" to /etc/mk.conf
509	    d) cd /usr/src ; make build
510	   Note that running "make obj" in a directory will create
511	   in obj.$MACHINE directory.
512    Build to a DESTDIR:
513	This helps to keep old installed files (especially libraries)
514	   from interfering with the new build.
515	   To build to a DESTDIR with build.sh, use the "-D" option.
516	   To build to a DESTDIR without using build.sh, set the DESTDIR
517	   environment variable before running make build.  It should be
518	   set to the pathname of an initially empty directory.
519	   Problems: if you do not use build.sh, you might need to
520		update critical utilities without using DESTDIR since
521		nothing is executed from what is installed in DESTDIR.
522		(See critical utils, below.)
523    Build often:
524	This keeps critical utilities current enough to not choke
525	on any other part of the source tree that depends on up to
526	date functionality.  If you use build.sh, you should not have
527	this problem.
528
529What to do if things don't work:
530^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
531When things don't work there are usually a few things that commonly
532should be done.
533    1)	make includes
534	This should be done automatically by make build.
535    2)  cd share/mk && make install
536	Again, automatically done by make build.
537
538Failsafe rebuild of a small part of the tree:
539^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
540To make sure you rebuild something correctly you want to do
541something like the following:
542    1)  Make sure the includes and .mk files are up to date.
543    2)  Make sure any program used to build the particular
544	utility is up to date.  (yacc, lex, etc...)
545    3)  cd ...path/to/util...
546	make cleandir
547	rm ...all obj directories...
548	make cleandir			# yes, again
549	make obj
550	make depend && make
551
552Failsafe rebuild of the entire tree:
553^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
554If you really want to make sure the source tree is clean and
555ready for a build try the following.  Note that sourcing /etc/mk.conf
556(a make(1) Makefile) in this manner is not right, and will not work
557for anyone who uses any make(1) features in /etc/mk.conf.
558
559---cut here---
560#!/bin/sh
561. /etc/mk.conf
562
563if [ -z $NETBSDSRCDIR ] ; then
564    NETBSDSRCDIR=/usr/src
565fi
566if [ \! -d $NETBSDSRCDIR ] ; then
567    echo Unable to find sources
568    exit 1
569fi
570find $NETBSDSRCDIR -name \*.o -o -name obj.\* -o -name obj -exec rm \{\} \;
571
572if [ -z $BSDOBJDIR ] ; then
573    BSDOBJDIR=/usr/obj
574fi
575if [ -d $BSDOBJDIR ] ; then
576    rm -rf $BSDOBJDIR
577fi
578
579cd $NETBSDSRCDIR && make cleandir
580
581---cut here---
582
583Critical utilities:
584^^^^^^^^^^^^^^^^^^^
585	usr.bin/make
586	usr.bin/yacc
587	usr.bin/lex
588	usr.bin/xlint
589	usr.bin/config
590
591Other problems and possible solutions:
592^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
593Symptom:Complaints involving a Makefile.
594Fix:	Rebuild usr.bin/make:
595	cd usr.bin/make && make && make install
596	Or, a failsafe method if that doesn't work:
597	cd usr.bin/make && cc -DMAKE_NATIVE *.c -I. -o make \
598	&& install make /usr/bin
599
600Fix:	Make sure .mk files are up to date.
601	cd share/mk && make install
602
603Symptom:Kernel `config' fails to configure any kernel, including GENERIC.
604Fix:	Rebuild usr.bin/config
605
606Symptom:Obsolete intermediate files are used during compilation
607Fix:	Try the following sequence of commands in the directory in question.
608	make cleandir; rm `make print-objdir`; make cleandir; make obj
609	(If you built the tree without "make obj" in the past, obsolete files
610	may remain.  The command tries to clean everything up)
611
612Symptom:.../sysinst/run.c:xx: warning: initialization from incompatible
613	pointer type
614Fix:	Rebuild and install usr.bin/menuc
615
616Symptom:mklocale not found during build in share/locale/ctype
617Fix:	Build and install usr.bin/mklocale
618
619Symptom:undefined reference to `__assert13' or `__unsetenv13'
620Fix:    Rebuild and install lib/libc
621
622Symptom:usr.bin/config fails to build.
623Fix:	Try building with -DMAKE_BOOTSTRAP added to CFLAGS in Makefile.
624
625Symptom:undefined reference to `getprogname' or `setprogname'
626Fix:    Rebuild and install lib/libc
627
628Symptom:Update build fails in src/tools/gcc complaining that a variable
629	(e.g. CPPFLAGS) has changed since the previous run.
630Fix:    Run "nbmake-${ARCH} clean" in src/tools/gcc or do a clean build.
631
632Symptom:cvs [update aborted]: cannot open directory /cvsroot/src/...:
633	No such file or directory.
634Cause:	If a directory is created by mistake, then it is sometimes
635	deleted from the CVS repository using administrative commands
636	that bypass the normal cvs access controls.  If your cvs working tree
637	contains references to a directory that has been deleted on the
638	server in this way, then "cvs update" reports this error.
639Fix:	Recursively delete the affected directory from your working tree
640	and try the update again.
641