UPDATING revision 1.348
11.348Srillig$NetBSD: UPDATING,v 1.348 2024/04/20 14:06:47 rillig Exp $ 21.1Sabs 31.123SjmcThis file (UPDATING) is intended to be a brief reference to recent 41.123Sjmcchanges that might cause problems in the build process, and a guide for 51.123Sjmcwhat to do if something doesn't work. 61.1Sabs 71.123SjmcFor a more detailed description of the recommended way to build NetBSD 81.123Sjmcusing build.sh, see the BUILDING file. 91.123Sjmc 101.123SjmcNote that much of the advice in this UPDATING file was written before 111.123Sjmcbuild.sh existed. Nevertheless, the advice here may be useful for 121.123Sjmcworking around specific problems with build.sh. 131.123Sjmc 141.257SapbSections are marked with "^^^^^". After the section on "Recent changes" 151.257Sapbare several sections containing more general information. 161.257Sapb 171.123SjmcSee also: BUILDING, build.sh, Makefile. 181.1Sabs 191.1SabsRecent changes: 201.1Sabs^^^^^^^^^^^^^^^ 211.230Stls 221.346Sriastrad20240410: 231.346Sriastrad Update builds may require manually deleting 241.346Sriastrad $DESTDIR/var/run/named (and, potentially, 251.346Sriastrad $DESTDIR/var/run/lwresd) in order to avoid checkflist failure. 261.346Sriastrad 271.347Snia20240409: 281.347Snia 32-bit compatibility libraries were moved into the base32 291.347Snia and debug32 sets. HTML man pages were moved into the manhtml set. 301.347Snia 311.343Sriastrad20230828: 321.343Sriastrad If: 331.343Sriastrad - you updated to current and ran postinstall between 20230826 341.343Sriastrad and 20230828 inclusive, and 351.343Sriastrad - you are not using anything outside the base system to 361.343Sriastrad populate /etc/openssl/certs (e.g., manually adding 371.343Sriastrad certificates or using ca-certificates or mozilla-rootcerts or 381.343Sriastrad mozilla-rootcerts-openssl from pkgsrc), 391.343Sriastrad delete /etc/openssl/certs and rerun postinstall or just 401.343Sriastrad `certctl rehash'. 411.343Sriastrad 421.343Sriastrad Otherwise, certctl(8) will think someone else has left 431.343Sriastrad /etc/openssl/certs in the way and will avoid clobbering it on 441.343Sriastrad upgrade from older NetBSD. 451.343Sriastrad 461.341Slukem20230718: 471.341Slukem build.sh will use mk.conf in the same directory as build.sh instead 481.341Slukem of /etc/mk.conf, unless MAKECONF is already defined in the environment. 491.341Slukem 501.342Smartin20230714: 511.342Smartin Import of gcc 10.5 requires a clean build of at least tools/gcc 521.342Smartin and external/gpl3/gcc* object directories. An update build 531.342Smartin without cleaning will result in obscure failures in rare corner 541.342Smartin cases. 551.342Smartin 561.339Smartin20230604: 571.339Smartin Building native kernels with the installed make(1) instead of 581.339Smartin the $TOOLDIR/bin/nbmake-${arch} wrapper will fail if userland 591.339Smartin has not been updated. Note that this is an unsupported build 601.339Smartin configuration (but usually works if userland is -current enough). 611.338Slukem 621.338Slukem20230523: 631.338Slukem ctfmerge was fixed as macOS host tool. This may require a clean tools 641.338Slukem rebuild to detect the update to tools/compat/configure. 651.338Slukem 661.340Smartin20230515: 671.340Smartin New openssl build requires removal of the crypto/external/bsd/openssl 681.345Sandvar and tests/crypto/libcrypto subdirectories in the ${OBJDIR} hierarchy. 691.340Smartin Otherwise test results may be wrong due to wrong "golden" output 701.340Smartin files being installed. 711.340Smartin 721.337Smrg20230322: 731.337Smrg Fixes for moved /lib/libisns* mean that builds will complain about 741.337Smrg ./usr/lib/libisns* being missing until src/lib/libisns is forced 751.337Smrg to (re)install the files, including the symlinks. The simplest 761.337Smrg way is to clean this subdir before building. 771.337Smrg 781.336Smartin20230112: 791.336Smartin New binutils require an updated ld.elf_so. If you are doing 801.336Smartin (unsupported) in-place self builds (with the -E flag to build.sh), 811.336Smartin make sure to have installed latest ld.elf_so before you rebuild 821.336Smartin userland. 831.336Smartin 841.335Schs20221116: 851.335Schs The addition to NetBSD's version of UFS2 of support for extended 861.335Schs attributes broke backward compatibility with previous releases 871.335Schs of NetBSD, so UFS2 has been restored to being compatible with 881.335Schs previous NetBSD releases by disabling extended attributes. 891.335Schs (Note that ACLs are implemented as extended attributes, so 901.335Schs this changes disables ACLs as well.) 911.335Schs 921.335Schs Support for UFS2 with extended attributes is now available in a new 931.335Schs UFS variant called UFS2ea. If you have created extended attributes 941.335Schs in an original UFS2 file system then "fsck -p" will now fail due to 951.335Schs the unexpected presence of extended attributes and "fsck -y" will 961.335Schs remove all extended attributes. If you wish to preserve extended 971.335Schs attributes rather than delete them, there is a utility to convert 981.335Schs a UFS2 file system to UFS2ea and leave extended attributes in place, 991.335Schs but this should be used with caution since it will preserve any 1001.335Schs extended attributes that have been corrupted by the backward 1011.335Schs incompatibility too. 1021.335Schs 1031.335Schs If you wish to use a UFS2ea file system as your root file system, 1041.335Schs then you will need to update your boot loader to a version that 1051.335Schs supports UFS2ea. 1061.335Schs 1071.335Schs For more information, see: 1081.335Schs https://wiki.netbsd.org/features/UFS2ea 1091.335Schs 1101.334Smrg20221111: 1111.334Smrg The new libdrm import worsened the conflict issues for the 1121.334Smrg kdump/ktruss ioctl, and i915 now conflicts with base, and has 1131.334Smrg been turned off. This will cause update build issues like: 1141.334Smrg 1151.334Smrg kdump-ioctl.c:12175:143: error: 'DRM_IOCTL_I915_DESTROY_HEAP' 1161.334Smrg undeclared here (not in a function); 1171.334Smrg did you mean 'DRM_IOCTL_MODE_DESTROY_DUMB'? 1181.334Smrg 1191.334Smrg You'll need to clean usr.bin/ktruss, usr.bin/kdump, and rescue. 1201.334Smrg 1211.331Sriastrad20220921: 1221.331Sriastrad Since the kernel version was bumped to 9.99.100, the bootloader 1231.333Sriastrad must be updated on x86 or EFI boot platforms in order to load 1241.333Sriastrad modules from boot.cfg(5) or interactively at the bootloader 1251.333Sriastrad prompt. 1261.333Sriastrad 1271.333Sriastrad The kernel can still load modules at runtime, with modload(8) 1281.333Sriastrad or modules.conf(5), with no bootloader update. This will not 1291.333Sriastrad affect release branches because it only applies to patch 1301.333Sriastrad numbers >=100. 1311.333Sriastrad 1321.333Sriastrad On x86 (i386 or amd64) with BIOS boot, this requires copying a 1331.333Sriastrad new /usr/mdec/boot to /boot. You can build this in the destdir 1341.333Sriastrad by running `$TOOLDIR/bin/nbmake-$ARCH dependall install' in 1351.333Sriastrad sys/arch/i386/stand. 1361.333Sriastrad 1371.333Sriastrad On platforms with EFI boot (including x86 with EFI boot), this 1381.333Sriastrad requires copying a new /usr/mdec/boot*.efi to the EFI/BOOT/ 1391.333Sriastrad directory on the EFI system partition. The boot*.efi file is: 1401.333Sriastrad 1411.333Sriastrad aarch64 bootaa64.efi 1421.333Sriastrad amd64 bootx64.efi 1431.333Sriastrad arm bootarm.efi (32-bit arm) 1441.333Sriastrad i386 bootx32.efi 1451.333Sriastrad 1461.333Sriastrad You can build this in the destdir by running 1471.333Sriastrad `$TOOLDIR/bin/nbmake-$ARCH dependall install' in 1481.333Sriastrad sys/stand/efiboot/boot*. 1491.331Sriastrad 1501.330Slukem20220821: 1511.330Slukem Support for building extsrc/ has been deprecated. 1521.330Slukem EXTSRCSRCDIR and MKEXTSRC have been deprecated. 1531.330Slukem 1541.329Smrg20220714: 1551.329Smrg Updates to xorg-server and associated drivers may cause builds to 1561.329Smrg fail. Cleaning both DESTDIR and the xorg build tree may be needed. 1571.329Smrg 1581.328Smartin20220628: 1591.328Smartin Changes in the build of src/games/robots require a clean build 1601.328Smartin of that program. 1611.328Smartin 1621.324Smartin20211116: 1631.324Smartin Changes in the xorg build require clean obj dirs for external/mit/xorg 1641.325Smartin (or a full clean/non-update build). 1651.324Smartin 1661.323Snia20211112: 1671.323Snia Device tree sources were updated for evbarm. Some device nodes 1681.323Snia (in particular, ld(4) devices on the ROCKPro64) will be renumbered. 1691.323Snia 1701.322Smartin20211014: 1711.323Snia MKPIE default for aarch64 has changed, a clean build is required. 1721.322Smartin 1731.321Schristos20210917: 1741.321Schristos Changed MNT_ACLS to default to POSIX1e ACLs instead of NFSv4 1751.321Schristos ACLs, to be compatible with FreeBSD. If you are using NFSv4 ACLs 1761.321Schristos and have "acls" in /etc/fstab you'll need to change it to "nfs4acls". 1771.321Schristos 1781.319Smrg20210711: 1791.319Smrg Updated GMP sources may require cleaning in tools/gmp and/or in 1801.319Smrg external/lgpl3/gmp/lib, particularly if GCC itself does not build. 1811.319Smrg 1821.318Smrg20210417: 1831.318Smrg GCC 10 was enabled for several platforms. If builds fail in either 1841.318Smrg tools/gcc or external/gpl/gcc, first try cleaning those objects and 1851.318Smrg removing the $DESTDIR/usr/include/g++ subdirectory. 1861.318Smrg 1871.316Smrg20201016: 1881.316Smrg MIPS kernel modules have been disabled until they work. This will 1891.316Smrg turn up in extra files in the DESTDIR, which should be cleaned. 1901.316Smrg 1911.315Smrg20200925: 1921.315Smrg GNU MPC and MPFR have been updated. At least MPFR needs cleaning 1931.315Smrg in both the tools and external dirs. 1941.315Smrg 1951.314Smrg20200912: 1961.314Smrg GCC 9 has arrived for Arm and x86 platforms, and will be coming 1971.314Smrg for several more, as will binutils 2.34. Clean as required. 1981.314Smrg 1991.313Smrg20200907: 2001.313Smrg GCC 9 is coming, and binutils has been updated for MIPS. This 2011.313Smrg probably requires cleaning the tools/binutils. 2021.313Smrg 2031.311Smrg20200811: 2041.312Smrg GCC updates may require cleaning the objdir. This may occur 2051.312Smrg due to GCC 7.5 update, GCC 8.4 move to gcc.old, or the upcoming 2061.312Smrg GCC 9 upgrade. 2071.311Smrg 2081.309Schristos20200614: 2091.310Schristos blacklist* has been renamed to blocklist*. postinstall(8) 2101.332Sgutterid should handle the migration. 2111.309Schristos 2121.308Schristos20200601: 2131.308Schristos Due to a mistake in LIBISPRIVATE handling, .so libraries were 2141.308Schristos created in the build directories and need cleaning. 2151.308Schristos 2161.307Smrg20200311: 2171.307Smrg GCC 8 ports will need cleaning in src/tools/gcc and 2181.307Smrg src/external/gpl3/gcc due to GCC 8.4 update. 2191.307Smrg 2201.306Schristos20191118: 2211.306Schristos More architectures were switched to gcc8: 2221.306Schristos i386, ia64 powerpc64, sparc, sparc64, arm 2231.306Schristos The same comments as in 20191022 apply. 2241.306Schristos 2251.305Smartin20191112: 2261.305Smartin The LLVM update requires a clean rebuild for all architectures using 2271.305Smartin LLVM during the tools build phase (i386, amd64, aarch64). 2281.305Smartin 2291.304Smartin20191022: 2301.304Smartin Ports amd64 and aarch64 switched to GCC 8.3 by default. 2311.304Smartin In-place ("expert mode", build.sh -E) builds are not supported 2321.304Smartin when going from a GCC 7 userland to GCC 8. Do a regular 2331.304Smartin build to a different DESTDIR (or preferably: build.sh -U) at least 2341.306Schristos once and install sets, or download comp.{tar.xz,tgz} from the 2351.304Smartin daily builds and install that before doing the next in-place build. 2361.304Smartin 2371.303Smrg20191001: 2381.303Smrg GCC 8.3 was imported. Builds of src/tools/gcc may fail if 2391.303Smrg old builds with GCC 7 output now uses GCC 8. Clean this 2401.303Smrg directory, and also clean src/external/gpl3/gcc. 2411.303Smrg 2421.302Sriastrad20190903: 2431.306Schristos Files with names that coincide with existing files' names on 2441.302Sriastrad case-insensitive file systems were inadvertently committed, for 2451.302Sriastrad radeon GPU firmware. We cannot mark these as obsolete for 2461.302Sriastrad postinstall to fix, so if you updated src since 2019-08-26, and 2471.302Sriastrad ran build.sh distribution or ran build.sh release, you must 2481.302Sriastrad manually delete the following files in your DESTDIR (which is 2491.302Sriastrad usually $OBJDIR/destir.$ARCH), or from / if you have installed 2501.302Sriastrad them: 2511.302Sriastrad 2521.302Sriastrad /libdata/firmware/radeon/bonaire_ce.bin 2531.302Sriastrad /libdata/firmware/radeon/bonaire_mc.bin 2541.302Sriastrad /libdata/firmware/radeon/bonaire_me.bin 2551.302Sriastrad /libdata/firmware/radeon/bonaire_mec.bin 2561.302Sriastrad /libdata/firmware/radeon/bonaire_pfp.bin 2571.302Sriastrad /libdata/firmware/radeon/bonaire_rlc.bin 2581.302Sriastrad /libdata/firmware/radeon/bonaire_sdma.bin 2591.302Sriastrad /libdata/firmware/radeon/bonaire_smc.bin 2601.302Sriastrad /libdata/firmware/radeon/bonaire_uvd.bin 2611.302Sriastrad /libdata/firmware/radeon/hainan_ce.bin 2621.302Sriastrad /libdata/firmware/radeon/hainan_mc.bin 2631.302Sriastrad /libdata/firmware/radeon/hainan_me.bin 2641.302Sriastrad /libdata/firmware/radeon/hainan_pfp.bin 2651.302Sriastrad /libdata/firmware/radeon/hainan_rlc.bin 2661.302Sriastrad /libdata/firmware/radeon/hainan_smc.bin 2671.302Sriastrad /libdata/firmware/radeon/hawaii_ce.bin 2681.302Sriastrad /libdata/firmware/radeon/hawaii_mc.bin 2691.302Sriastrad /libdata/firmware/radeon/hawaii_me.bin 2701.302Sriastrad /libdata/firmware/radeon/hawaii_mec.bin 2711.302Sriastrad /libdata/firmware/radeon/hawaii_pfp.bin 2721.302Sriastrad /libdata/firmware/radeon/hawaii_rlc.bin 2731.302Sriastrad /libdata/firmware/radeon/hawaii_sdma.bin 2741.302Sriastrad /libdata/firmware/radeon/hawaii_smc.bin 2751.302Sriastrad /libdata/firmware/radeon/kabini_ce.bin 2761.302Sriastrad /libdata/firmware/radeon/kabini_me.bin 2771.302Sriastrad /libdata/firmware/radeon/kabini_mec.bin 2781.302Sriastrad /libdata/firmware/radeon/kabini_pfp.bin 2791.302Sriastrad /libdata/firmware/radeon/kabini_rlc.bin 2801.302Sriastrad /libdata/firmware/radeon/kabini_sdma.bin 2811.302Sriastrad /libdata/firmware/radeon/kaveri_ce.bin 2821.302Sriastrad /libdata/firmware/radeon/kaveri_me.bin 2831.302Sriastrad /libdata/firmware/radeon/kaveri_mec.bin 2841.302Sriastrad /libdata/firmware/radeon/kaveri_mec2.bin 2851.302Sriastrad /libdata/firmware/radeon/kaveri_pfp.bin 2861.302Sriastrad /libdata/firmware/radeon/kaveri_rlc.bin 2871.302Sriastrad /libdata/firmware/radeon/kaveri_sdma.bin 2881.302Sriastrad /libdata/firmware/radeon/mullins_ce.bin 2891.302Sriastrad /libdata/firmware/radeon/mullins_me.bin 2901.302Sriastrad /libdata/firmware/radeon/mullins_mec.bin 2911.302Sriastrad /libdata/firmware/radeon/mullins_pfp.bin 2921.302Sriastrad /libdata/firmware/radeon/mullins_rlc.bin 2931.302Sriastrad /libdata/firmware/radeon/mullins_sdma.bin 2941.302Sriastrad /libdata/firmware/radeon/oland_ce.bin 2951.302Sriastrad /libdata/firmware/radeon/oland_mc.bin 2961.302Sriastrad /libdata/firmware/radeon/oland_me.bin 2971.302Sriastrad /libdata/firmware/radeon/oland_pfp.bin 2981.302Sriastrad /libdata/firmware/radeon/oland_rlc.bin 2991.302Sriastrad /libdata/firmware/radeon/oland_smc.bin 3001.302Sriastrad /libdata/firmware/radeon/pitcairn_ce.bin 3011.302Sriastrad /libdata/firmware/radeon/pitcairn_mc.bin 3021.302Sriastrad /libdata/firmware/radeon/pitcairn_me.bin 3031.302Sriastrad /libdata/firmware/radeon/pitcairn_pfp.bin 3041.302Sriastrad /libdata/firmware/radeon/pitcairn_rlc.bin 3051.302Sriastrad /libdata/firmware/radeon/pitcairn_smc.bin 3061.302Sriastrad /libdata/firmware/radeon/tahiti_ce.bin 3071.302Sriastrad /libdata/firmware/radeon/tahiti_mc.bin 3081.302Sriastrad /libdata/firmware/radeon/tahiti_me.bin 3091.302Sriastrad /libdata/firmware/radeon/tahiti_pfp.bin 3101.302Sriastrad /libdata/firmware/radeon/tahiti_rlc.bin 3111.302Sriastrad /libdata/firmware/radeon/tahiti_smc.bin 3121.302Sriastrad /libdata/firmware/radeon/verde_ce.bin 3131.302Sriastrad /libdata/firmware/radeon/verde_mc.bin 3141.302Sriastrad /libdata/firmware/radeon/verde_me.bin 3151.302Sriastrad /libdata/firmware/radeon/verde_pfp.bin 3161.302Sriastrad /libdata/firmware/radeon/verde_rlc.bin 3171.302Sriastrad /libdata/firmware/radeon/verde_smc.bin 3181.302Sriastrad 3191.302Sriastrad We will re-import these radeon firmware images another way 3201.302Sriastrad later. 3211.302Sriastrad 3221.301Smartin20190727: 3231.301Smartin The uefi bootloader has gained tftp support and needs a clean 3241.301Smartin build. If you do update builds, manually clean its object 3251.301Smartin directory by something like: 3261.301Smartin cd sys/arch/i386/stand/efiboot && make clean 3271.301Smartin 3281.300Smartin20190723: 3291.344Sgutterid The jemalloc allocator in libc is now built without extended 3301.300Smartin debugging (for performance reasons). In update builds make sure 3311.326Sandvar to rebuild it completely, by removing all affected object files, 3321.300Smartin including compat builds, something like: 3331.300Smartin cd /usr/obj && find . -type d -name jemalloc|xargs rm -rf 3341.300Smartin 3351.299Smrg20190207: 3361.299Smrg GCC 7 switched for many ports. Update builds are likely to fail. 3371.299Smrg 3381.1SabsHints for a more successful build: 3391.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3401.123Sjmc Use build.sh, but do not use its "expert mode": 3411.132Sjmmv This will automatically build the tools in the 3421.123Sjmc correct order, and it will keep the tools and the 3431.123Sjmc new build products from interfering with the running 3441.123Sjmc system. This will allow you to ignore most of the 3451.123Sjmc other advice in this file. 3461.2Smrg Build a new kernel first: 3471.2Smrg This makes sure that any new system calls or features 3481.2Smrg expected by the new userland will be present. This 3491.2Smrg helps to avoid critical errors when upgrading. 3501.1Sabs Use object directories: 3511.1Sabs This helps to keep stale object 3521.1Sabs files from polluting the build if a Makefile "forgets" 3531.1Sabs about one. It also makes it easier to clean up after 3541.1Sabs a build. It's also necessary if you want to use the 3551.1Sabs same source tree for multiple machines. 3561.123Sjmc To use object directories with build.sh: 3571.123Sjmc a) invoke build.sh with the "-M" or "-O" options. 3581.123Sjmc To use object directories without using build.sh: 3591.1Sabs a) cd /usr/src ; make cleandir 3601.2Smrg b) Add "OBJMACHINE=yes" to /etc/mk.conf 3611.2Smrg c) Add "MKOBJDIRS=yes" to /etc/mk.conf 3621.1Sabs d) cd /usr/src ; make build 3631.2Smrg Note that running "make obj" in a directory will create 3641.2Smrg in obj.$MACHINE directory. 3651.1Sabs Build to a DESTDIR: 3661.123Sjmc This helps to keep old installed files (especially libraries) 3671.123Sjmc from interfering with the new build. 3681.123Sjmc To build to a DESTDIR with build.sh, use the "-D" option. 3691.123Sjmc To build to a DESTDIR without using build.sh, set the DESTDIR 3701.123Sjmc environment variable before running make build. It should be 3711.123Sjmc set to the pathname of an initially empty directory. 3721.123Sjmc Problems: if you do not use build.sh, you might need to 3731.123Sjmc update critical utilities without using DESTDIR since 3741.123Sjmc nothing is executed from what is installed in DESTDIR. 3751.123Sjmc (See critical utils, below.) 3761.1Sabs Build often: 3771.1Sabs This keeps critical utilities current enough to not choke 3781.1Sabs on any other part of the source tree that depends on up to 3791.123Sjmc date functionality. If you use build.sh, you should not have 3801.123Sjmc this problem. 3811.241Swiz 3821.1SabsWhat to do if things don't work: 3831.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3841.230StlsWhen things don't work there are usually a few things that commonly 3851.1Sabsshould be done. 3861.1Sabs 1) make includes 3871.1Sabs This should be done automatically by make build. 3881.1Sabs 2) cd share/mk && make install 3891.1Sabs Again, automatically done by make build. 3901.1Sabs 3911.1SabsFailsafe rebuild of a small part of the tree: 3921.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3931.1SabsTo make sure you rebuild something correctly you want to do 3941.1Sabssomething like the following: 3951.1Sabs 1) Make sure the includes and .mk files are up to date. 3961.1Sabs 2) Make sure any program used to build the particular 3971.1Sabs utility is up to date. (yacc, lex, etc...) 3981.1Sabs 3) cd ...path/to/util... 3991.1Sabs make cleandir 4001.1Sabs rm ...all obj directories... 4011.1Sabs make cleandir # yes, again 4021.1Sabs make obj 4031.1Sabs make depend && make 4041.1Sabs 4051.1SabsFailsafe rebuild of the entire tree: 4061.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 4071.1SabsIf you really want to make sure the source tree is clean and 4081.2Smrgready for a build try the following. Note that sourcing /etc/mk.conf 4091.2Smrg(a make(1) Makefile) in this manner is not right, and will not work 4101.2Smrgfor anyone who uses any make(1) features in /etc/mk.conf. 4111.1Sabs 4121.1Sabs---cut here--- 4131.1Sabs#!/bin/sh 4141.1Sabs. /etc/mk.conf 4151.1Sabs 4161.58Slukemif [ -z $NETBSDSRCDIR ] ; then 4171.58Slukem NETBSDSRCDIR=/usr/src 4181.1Sabsfi 4191.58Slukemif [ \! -d $NETBSDSRCDIR ] ; then 4201.1Sabs echo Unable to find sources 4211.1Sabs exit 1 4221.1Sabsfi 4231.58Slukemfind $NETBSDSRCDIR -name \*.o -o -name obj.\* -o -name obj -exec rm \{\} \; 4241.1Sabs 4251.1Sabsif [ -z $BSDOBJDIR ] ; then 4261.1Sabs BSDOBJDIR=/usr/obj 4271.1Sabsfi 4281.1Sabsif [ -d $BSDOBJDIR ] ; then 4291.1Sabs rm -rf $BSDOBJDIR 4301.1Sabsfi 4311.1Sabs 4321.58Slukemcd $NETBSDSRCDIR && make cleandir 4331.1Sabs 4341.1Sabs---cut here--- 4351.1Sabs 4361.1SabsCritical utilities: 4371.1Sabs^^^^^^^^^^^^^^^^^^^ 4381.1Sabs usr.bin/make 4391.1Sabs usr.bin/yacc 4401.1Sabs usr.bin/lex 4411.11Slukem usr.bin/xlint 4421.142Sdrochner usr.bin/config 4431.1Sabs 4441.34SsimonbOther problems and possible solutions: 4451.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 4461.1SabsSymptom:Complaints involving a Makefile. 4471.17SerhFix: Rebuild usr.bin/make: 4481.17Serh cd usr.bin/make && make && make install 4491.111Ssimonb Or, a failsafe method if that doesn't work: 4501.348Srillig cd usr.bin/make && cc -DMAKE_NATIVE *.c -I. -o make \ 4511.348Srillig && install make /usr/bin 4521.17Serh 4531.1SabsFix: Make sure .mk files are up to date. 4541.1Sabs cd share/mk && make install 4551.2Smrg 4561.2SmrgSymptom:Kernel `config' fails to configure any kernel, including GENERIC. 4571.142SdrochnerFix: Rebuild usr.bin/config 4581.1Sabs 4591.4SitojunSymptom:Obsolete intermediate files are used during compilation 4601.4SitojunFix: Try the following sequence of commands in the directory in question. 4611.4Sitojun make cleandir; rm `make print-objdir`; make cleandir; make obj 4621.4Sitojun (If you built the tree without "make obj" in the past, obsolete files 4631.4Sitojun may remain. The command tries to clean everything up) 4641.5Swiz 4651.207SmbalmerSymptom:.../sysinst/run.c:xx: warning: initialization from incompatible 4661.207Smbalmer pointer type 4671.5SwizFix: Rebuild and install usr.bin/menuc 4681.12Sitojun 4691.12SitojunSymptom:mklocale not found during build in share/locale/ctype 4701.12SitojunFix: Build and install usr.bin/mklocale 4711.13Sdogcow 4721.86SkleinkSymptom:undefined reference to `__assert13' or `__unsetenv13' 4731.13SdogcowFix: Rebuild and install lib/libc 4741.13Sdogcow 4751.142SdrochnerSymptom:usr.bin/config fails to build. 4761.19ScgdFix: Try building with -DMAKE_BOOTSTRAP added to CFLAGS in Makefile. 4771.13Sdogcow 4781.19ScgdSymptom:undefined reference to `getprogname' or `setprogname' 4791.19ScgdFix: Rebuild and install lib/libc 4801.24Sabs 4811.223SjoergSymptom:Update build fails in src/tools/gcc complaining that a variable 4821.223Sjoerg (e.g. CPPFLAGS) has changed since the previous run. 4831.223SjoergFix: Run "nbmake-${ARCH} clean" in src/tools/gcc or do a clean build. 4841.257Sapb 4851.257SapbSymptom:cvs [update aborted]: cannot open directory /cvsroot/src/...: 4861.257Sapb No such file or directory. 4871.257SapbCause: If a directory is created by mistake, then it is sometimes 4881.257Sapb deleted from the CVS repository using administrative commands 4891.257Sapb that bypass the normal cvs access controls. If your cvs working tree 4901.257Sapb contains references to a directory that has been deleted on the 4911.257Sapb server in this way, then "cvs update" reports this error. 4921.257SapbFix: Recursively delete the affected directory from your working tree 4931.257Sapb and try the update again. 494