UPDATING revision 1.389
11.389Smartin$NetBSD: UPDATING,v 1.389 2025/12/20 15:33:26 martin 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.389Smartin20251219: 231.389Smartin Reorganization of libraries for PR 58648 requires a new enough 241.389Smartin nbcrunchgen tool (this should be build automatically) and manual 251.389Smartin removal of $DESTDIR/usr/lib/libssh* and $DESTDIR/usr/lib/*/libssh*. 261.389Smartin 271.385Smartin20251028: 281.385Smartin libpthread had it's shared library version go back (from 1.7 to 291.385Smartin 1.6). This may cause fallout during update builds, remove the 301.385Smartin libpthread obj dir and all libpthread.so.1.7\* files in the 311.385Smartin dest dir. 321.386Smartin If you have build other software/packages on a -current system 331.386Smartin from 20251026 or 20251027 you need to rebuild them after 341.386Smartin updating your base system again. 351.385Smartin 361.384Smartin20251019: 371.384Smartin Changes to how libcrypto got linked (libpthread not required 381.384Smartin any more) cause failures in update builds. To fix, run 391.384Smartin (as your build user) a "make cleandir" in the following 401.384Smartin subdirectories: 411.384Smartin 421.384Smartin crypto/external/apache2/openssl 431.384Smartin crypto/external/bsd/heimdal 441.384Smartin crypto/external/bsd/netpgp 451.384Smartin crypto/external/bsd/openssh 461.384Smartin external/bsd/libfido2 471.384Smartin external/bsd/nsd 481.384Smartin external/bsd/ntp 491.384Smartin external/bsd/pam-u2f 501.384Smartin external/bsd/ppp 511.384Smartin external/bsd/tcpdump 521.384Smartin external/bsd/wpa 531.384Smartin games/factor 541.384Smartin libexec/httpd 551.384Smartin tests/crypto/libcrypto 561.384Smartin tests/lib/libc/hash 571.384Smartin usr.bin/dc 581.384Smartin usr.bin/ftp 591.384Smartin usr.bin/moduli 601.384Smartin usr.bin/nbsvtool 611.384Smartin usr.sbin/plainrsa-gen 621.384Smartin usr.sbin/syslogd 631.384Smartin 641.382Smrg20250721: 651.382Smrg GCC 12.5 was imported and there may be weird build issues. 661.382Smrg Clean any GCC build dirs if you encounter weird things. 671.382Smrg 681.383Smartin20250720: 691.383Smartin New openssl and old objects for tests for libcrypto may 701.383Smartin cause spurious test failure, clean the src/tests/crypto/libcrypto 711.383Smartin object dirs. 721.383Smartin 731.380Smartin20250528: 741.380Smartin Changes in the tools build require removing all config.cache 751.380Smartin files in the object tools directories. 761.380Smartin 771.378Spgoyette20250427: 781.378Spgoyette The KERNEL_DIR option to build.sh is now functional. Set it 791.379Skre with ``-V KERNEL_DIR=yes'' on your build.sh command. 801.378Spgoyette With this, you can now colocate kernel and associated modules 811.378Spgoyette in /netbsd/{kernel,kernel.dbg,modules} instead of having the 821.378Spgoyette kernel in / but modules in /stand. 831.378Spgoyette 841.378Spgoyette Note that you'll need new bootstrap code to use this feature. 851.378Spgoyette 861.379Skre This completes work begun many years ago by christos@ :-) 871.378Spgoyette 881.377Sriastrad20250413: 891.377Sriastrad A change to bsd.lib.mk requires a clean build of all libraries. 901.377Sriastrad 911.375Schristos20250131: 921.375Schristos The switch to the new jemalloc requires cleaning in libc. 931.376Spalle 941.367Sriastrad20241122: 951.373Sriastrad Changes to various libraries' build options require cleaning 961.373Sriastrad their objdirs in update builds: 971.368Sriastrad 981.372Sriastrad cd external/bsd/file/lib && $TOOLDIR/bin/nbmake-$ARCH clean 991.370Sriastrad cd external/bsd/libarchive/lib && $TOOLDIR/bin/nbmake-$ARCH clean 1001.372Sriastrad cd external/public-domain/xz/lib && $TOOLDIR/bin/nbmake-$ARCH clean 1011.368Sriastrad 1021.374Sriastrad Also, for architectures with MKCOMPAT, it is necessary to clean 1031.374Sriastrad the compat objdirs too. The easiest way is: 1041.374Sriastrad 1051.374Sriastrad rm -rf OBJDIR/compat/*/*/external/bsd/file/lib 1061.374Sriastrad rm -rf OBJDIR/compat/*/*/external/bsd/libarchive/lib 1071.374Sriastrad rm -rf OBJDIR/compat/*/*/external/public-domain/xz/lib 1081.374Sriastrad 1091.367Sriastrad Changes to bsd.lib.mk to improve detecting differences in 1101.367Sriastrad shared library symbol exports may cause some .actsym files in 1111.367Sriastrad the objdir to become stale in update builds. 1121.367Sriastrad 1131.367Sriastrad To work around this, delete all files matching `*.actsym' in 1141.367Sriastrad the objdir. For example: 1151.367Sriastrad 1161.367Sriastrad find OBJDIR -name '*.actsym' -type f -print0 | xargs -0 rm 1171.367Sriastrad 1181.363Smartin20241104: 1191.363Smartin Changes around the integration of the zstd compression 1201.363Smartin library may require manual deletion of some object directories 1211.366Sriastrad if you update from a build from a few days ago: 1221.366Sriastrad rm -rf DESTDIR/usr/lib/*/libarchive* 1231.366Sriastrad rm -rf DESTDIR/usr/lib/*/libmagic* 1241.366Sriastrad rm -rf DESTDIR/usr/lib/*/libzstd* 1251.366Sriastrad rm -rf DESTDIR/usr/lib/libarchive* 1261.366Sriastrad rm -rf DESTDIR/usr/lib/libmagic* 1271.366Sriastrad rm -rf DESTDIR/usr/lib/libzstd* 1281.366Sriastrad rm -rf OBJDIR/compat/*/*/external/bsd/file/ 1291.366Sriastrad rm -rf OBJDIR/compat/*/*/external/bsd/libarchive/ 1301.366Sriastrad rm -rf OBJDIR/compat/*/*/external/bsd/zstd/ 1311.366Sriastrad rm -rf OBJDIR/external/bsd/file/ 1321.366Sriastrad rm -rf OBJDIR/external/bsd/libarchive/ 1331.366Sriastrad rm -rf OBJDIR/external/bsd/zstd/ 1341.366Sriastrad rm -rf OBJDIR/external/gpl3/gcc/ 1351.366Sriastrad rm -rf OBJDIR/tools/gcc/ 1361.363Smartin 1371.360Swiz20240926: 1381.360Swiz Building -current when running on amd64 from about 20240924 1391.360Swiz to about 20240926 will not work due to a "malloc_np.h" 1401.360Swiz error. Please downgrade to a version from 20240924 or older, 1411.360Swiz or upgrade to a newer version e.g. using a binary release from 1421.360Swiz the NetBSD build servers. 1431.360Swiz 1441.358Smartin20240923: 1451.358Smartin Update builds will require cleaning the object directories for 1461.359Smartin jemalloc (like: "rm -rf $OBJ/external/bsd/jemalloc*") and the 1471.359Smartin libc dependency files (like: "rm $OBJ/lib/libc/jemalloc.*"). 1481.359Smartin On architectures with COMPAT libs, those also have to be cleaned, 1491.359Smartin e.g. on sparc64: "rm -rf $OBJ/compat/sparc64/sparc/external/bsd/jemalloc*" 1501.359Smartin and "rm $OBJ/compat/sparc64/sparc/lib/libc/jemalloc.*". 1511.358Smartin 1521.381Sgutterid20240920: 1531.381Sgutterid Update builds will require cleaning in src/external/historical/nawk/bin 1541.381Sgutterid in order to remove the awk subdirectory since there is now a binary 1551.381Sgutterid called awk. 1561.381Sgutterid 1571.357Schristos20240817: 1581.357Schristos Update builds will require cleaning in src/external/historical/nawk/bin 1591.357Schristos in order to remove the awk binary since now there is a subdirectory 1601.357Schristos called awk. 1611.358Smartin 1621.355Smartin20240812: 1631.355Smartin Update builds will require removing the tools objdir for gdb 1641.355Smartin if building with MKCROSSGDB=yes. All architectures use gdb.old 1651.355Smartin now. 1661.356Sriastrad 1671.354Smartin20240630: 1681.353Smartin Update builds will require removing the tools objdir for binutils 1691.353Smartin (as most architectures should use binutils.old now). 1701.353Smartin 1711.352Skre20240610: 1721.352Skre Update builds are likely to require removing the objdir for 1731.352Skre distrib/<arch>/cdroms - or at least references to libarchive 1741.352Skre from within there after the recent libarchive update. 1751.352Skre 1761.350Sriastrad20240504: 1771.350Sriastrad Update builds on x86 require making the `cleandir' target in 1781.350Sriastrad lib/libm, or deleting the objdir for lib/libm. 1791.350Sriastrad 1801.349Smaya20240423: 1811.349Smaya Update builds with x11 may fail after switching to Mesa 21. 1821.349Smaya 1831.346Sriastrad20240410: 1841.346Sriastrad Update builds may require manually deleting 1851.346Sriastrad $DESTDIR/var/run/named (and, potentially, 1861.346Sriastrad $DESTDIR/var/run/lwresd) in order to avoid checkflist failure. 1871.346Sriastrad 1881.347Snia20240409: 1891.347Snia 32-bit compatibility libraries were moved into the base32 1901.347Snia and debug32 sets. HTML man pages were moved into the manhtml set. 1911.347Snia 1921.343Sriastrad20230828: 1931.343Sriastrad If: 1941.343Sriastrad - you updated to current and ran postinstall between 20230826 1951.343Sriastrad and 20230828 inclusive, and 1961.343Sriastrad - you are not using anything outside the base system to 1971.343Sriastrad populate /etc/openssl/certs (e.g., manually adding 1981.343Sriastrad certificates or using ca-certificates or mozilla-rootcerts or 1991.343Sriastrad mozilla-rootcerts-openssl from pkgsrc), 2001.343Sriastrad delete /etc/openssl/certs and rerun postinstall or just 2011.343Sriastrad `certctl rehash'. 2021.343Sriastrad 2031.343Sriastrad Otherwise, certctl(8) will think someone else has left 2041.343Sriastrad /etc/openssl/certs in the way and will avoid clobbering it on 2051.343Sriastrad upgrade from older NetBSD. 2061.343Sriastrad 2071.341Slukem20230718: 2081.341Slukem build.sh will use mk.conf in the same directory as build.sh instead 2091.341Slukem of /etc/mk.conf, unless MAKECONF is already defined in the environment. 2101.341Slukem 2111.342Smartin20230714: 2121.342Smartin Import of gcc 10.5 requires a clean build of at least tools/gcc 2131.342Smartin and external/gpl3/gcc* object directories. An update build 2141.342Smartin without cleaning will result in obscure failures in rare corner 2151.342Smartin cases. 2161.342Smartin 2171.339Smartin20230604: 2181.339Smartin Building native kernels with the installed make(1) instead of 2191.339Smartin the $TOOLDIR/bin/nbmake-${arch} wrapper will fail if userland 2201.339Smartin has not been updated. Note that this is an unsupported build 2211.339Smartin configuration (but usually works if userland is -current enough). 2221.338Slukem 2231.338Slukem20230523: 2241.338Slukem ctfmerge was fixed as macOS host tool. This may require a clean tools 2251.338Slukem rebuild to detect the update to tools/compat/configure. 2261.338Slukem 2271.340Smartin20230515: 2281.340Smartin New openssl build requires removal of the crypto/external/bsd/openssl 2291.345Sandvar and tests/crypto/libcrypto subdirectories in the ${OBJDIR} hierarchy. 2301.340Smartin Otherwise test results may be wrong due to wrong "golden" output 2311.340Smartin files being installed. 2321.340Smartin 2331.337Smrg20230322: 2341.337Smrg Fixes for moved /lib/libisns* mean that builds will complain about 2351.337Smrg ./usr/lib/libisns* being missing until src/lib/libisns is forced 2361.337Smrg to (re)install the files, including the symlinks. The simplest 2371.337Smrg way is to clean this subdir before building. 2381.337Smrg 2391.336Smartin20230112: 2401.336Smartin New binutils require an updated ld.elf_so. If you are doing 2411.336Smartin (unsupported) in-place self builds (with the -E flag to build.sh), 2421.336Smartin make sure to have installed latest ld.elf_so before you rebuild 2431.336Smartin userland. 2441.336Smartin 2451.335Schs20221116: 2461.335Schs The addition to NetBSD's version of UFS2 of support for extended 2471.335Schs attributes broke backward compatibility with previous releases 2481.335Schs of NetBSD, so UFS2 has been restored to being compatible with 2491.335Schs previous NetBSD releases by disabling extended attributes. 2501.335Schs (Note that ACLs are implemented as extended attributes, so 2511.335Schs this changes disables ACLs as well.) 2521.335Schs 2531.335Schs Support for UFS2 with extended attributes is now available in a new 2541.335Schs UFS variant called UFS2ea. If you have created extended attributes 2551.335Schs in an original UFS2 file system then "fsck -p" will now fail due to 2561.335Schs the unexpected presence of extended attributes and "fsck -y" will 2571.335Schs remove all extended attributes. If you wish to preserve extended 2581.335Schs attributes rather than delete them, there is a utility to convert 2591.335Schs a UFS2 file system to UFS2ea and leave extended attributes in place, 2601.335Schs but this should be used with caution since it will preserve any 2611.335Schs extended attributes that have been corrupted by the backward 2621.335Schs incompatibility too. 2631.335Schs 2641.335Schs If you wish to use a UFS2ea file system as your root file system, 2651.335Schs then you will need to update your boot loader to a version that 2661.335Schs supports UFS2ea. 2671.335Schs 2681.335Schs For more information, see: 2691.335Schs https://wiki.netbsd.org/features/UFS2ea 2701.335Schs 2711.334Smrg20221111: 2721.334Smrg The new libdrm import worsened the conflict issues for the 2731.334Smrg kdump/ktruss ioctl, and i915 now conflicts with base, and has 2741.334Smrg been turned off. This will cause update build issues like: 2751.334Smrg 2761.334Smrg kdump-ioctl.c:12175:143: error: 'DRM_IOCTL_I915_DESTROY_HEAP' 2771.334Smrg undeclared here (not in a function); 2781.334Smrg did you mean 'DRM_IOCTL_MODE_DESTROY_DUMB'? 2791.334Smrg 2801.334Smrg You'll need to clean usr.bin/ktruss, usr.bin/kdump, and rescue. 2811.334Smrg 2821.331Sriastrad20220921: 2831.331Sriastrad Since the kernel version was bumped to 9.99.100, the bootloader 2841.333Sriastrad must be updated on x86 or EFI boot platforms in order to load 2851.333Sriastrad modules from boot.cfg(5) or interactively at the bootloader 2861.333Sriastrad prompt. 2871.333Sriastrad 2881.333Sriastrad The kernel can still load modules at runtime, with modload(8) 2891.333Sriastrad or modules.conf(5), with no bootloader update. This will not 2901.333Sriastrad affect release branches because it only applies to patch 2911.333Sriastrad numbers >=100. 2921.333Sriastrad 2931.333Sriastrad On x86 (i386 or amd64) with BIOS boot, this requires copying a 2941.333Sriastrad new /usr/mdec/boot to /boot. You can build this in the destdir 2951.333Sriastrad by running `$TOOLDIR/bin/nbmake-$ARCH dependall install' in 2961.333Sriastrad sys/arch/i386/stand. 2971.333Sriastrad 2981.333Sriastrad On platforms with EFI boot (including x86 with EFI boot), this 2991.333Sriastrad requires copying a new /usr/mdec/boot*.efi to the EFI/BOOT/ 3001.333Sriastrad directory on the EFI system partition. The boot*.efi file is: 3011.333Sriastrad 3021.333Sriastrad aarch64 bootaa64.efi 3031.333Sriastrad amd64 bootx64.efi 3041.333Sriastrad arm bootarm.efi (32-bit arm) 3051.333Sriastrad i386 bootx32.efi 3061.333Sriastrad 3071.333Sriastrad You can build this in the destdir by running 3081.333Sriastrad `$TOOLDIR/bin/nbmake-$ARCH dependall install' in 3091.333Sriastrad sys/stand/efiboot/boot*. 3101.331Sriastrad 3111.330Slukem20220821: 3121.330Slukem Support for building extsrc/ has been deprecated. 3131.330Slukem EXTSRCSRCDIR and MKEXTSRC have been deprecated. 3141.330Slukem 3151.329Smrg20220714: 3161.329Smrg Updates to xorg-server and associated drivers may cause builds to 3171.329Smrg fail. Cleaning both DESTDIR and the xorg build tree may be needed. 3181.329Smrg 3191.328Smartin20220628: 3201.328Smartin Changes in the build of src/games/robots require a clean build 3211.328Smartin of that program. 3221.328Smartin 3231.324Smartin20211116: 3241.324Smartin Changes in the xorg build require clean obj dirs for external/mit/xorg 3251.325Smartin (or a full clean/non-update build). 3261.324Smartin 3271.323Snia20211112: 3281.323Snia Device tree sources were updated for evbarm. Some device nodes 3291.323Snia (in particular, ld(4) devices on the ROCKPro64) will be renumbered. 3301.323Snia 3311.322Smartin20211014: 3321.323Snia MKPIE default for aarch64 has changed, a clean build is required. 3331.322Smartin 3341.321Schristos20210917: 3351.321Schristos Changed MNT_ACLS to default to POSIX1e ACLs instead of NFSv4 3361.321Schristos ACLs, to be compatible with FreeBSD. If you are using NFSv4 ACLs 3371.321Schristos and have "acls" in /etc/fstab you'll need to change it to "nfs4acls". 3381.321Schristos 3391.319Smrg20210711: 3401.319Smrg Updated GMP sources may require cleaning in tools/gmp and/or in 3411.319Smrg external/lgpl3/gmp/lib, particularly if GCC itself does not build. 3421.319Smrg 3431.318Smrg20210417: 3441.318Smrg GCC 10 was enabled for several platforms. If builds fail in either 3451.351Sgutterid tools/gcc or external/gpl3/gcc, first try cleaning those objects and 3461.318Smrg removing the $DESTDIR/usr/include/g++ subdirectory. 3471.318Smrg 3481.316Smrg20201016: 3491.316Smrg MIPS kernel modules have been disabled until they work. This will 3501.316Smrg turn up in extra files in the DESTDIR, which should be cleaned. 3511.316Smrg 3521.315Smrg20200925: 3531.315Smrg GNU MPC and MPFR have been updated. At least MPFR needs cleaning 3541.315Smrg in both the tools and external dirs. 3551.315Smrg 3561.314Smrg20200912: 3571.314Smrg GCC 9 has arrived for Arm and x86 platforms, and will be coming 3581.314Smrg for several more, as will binutils 2.34. Clean as required. 3591.314Smrg 3601.313Smrg20200907: 3611.313Smrg GCC 9 is coming, and binutils has been updated for MIPS. This 3621.313Smrg probably requires cleaning the tools/binutils. 3631.313Smrg 3641.311Smrg20200811: 3651.312Smrg GCC updates may require cleaning the objdir. This may occur 3661.312Smrg due to GCC 7.5 update, GCC 8.4 move to gcc.old, or the upcoming 3671.312Smrg GCC 9 upgrade. 3681.311Smrg 3691.309Schristos20200614: 3701.310Schristos blacklist* has been renamed to blocklist*. postinstall(8) 3711.332Sgutterid should handle the migration. 3721.309Schristos 3731.308Schristos20200601: 3741.308Schristos Due to a mistake in LIBISPRIVATE handling, .so libraries were 3751.308Schristos created in the build directories and need cleaning. 3761.308Schristos 3771.307Smrg20200311: 3781.307Smrg GCC 8 ports will need cleaning in src/tools/gcc and 3791.307Smrg src/external/gpl3/gcc due to GCC 8.4 update. 3801.307Smrg 3811.306Schristos20191118: 3821.306Schristos More architectures were switched to gcc8: 3831.306Schristos i386, ia64 powerpc64, sparc, sparc64, arm 3841.306Schristos The same comments as in 20191022 apply. 3851.306Schristos 3861.305Smartin20191112: 3871.305Smartin The LLVM update requires a clean rebuild for all architectures using 3881.305Smartin LLVM during the tools build phase (i386, amd64, aarch64). 3891.305Smartin 3901.304Smartin20191022: 3911.304Smartin Ports amd64 and aarch64 switched to GCC 8.3 by default. 3921.304Smartin In-place ("expert mode", build.sh -E) builds are not supported 3931.304Smartin when going from a GCC 7 userland to GCC 8. Do a regular 3941.304Smartin build to a different DESTDIR (or preferably: build.sh -U) at least 3951.306Schristos once and install sets, or download comp.{tar.xz,tgz} from the 3961.304Smartin daily builds and install that before doing the next in-place build. 3971.304Smartin 3981.303Smrg20191001: 3991.303Smrg GCC 8.3 was imported. Builds of src/tools/gcc may fail if 4001.303Smrg old builds with GCC 7 output now uses GCC 8. Clean this 4011.303Smrg directory, and also clean src/external/gpl3/gcc. 4021.303Smrg 4031.302Sriastrad20190903: 4041.306Schristos Files with names that coincide with existing files' names on 4051.302Sriastrad case-insensitive file systems were inadvertently committed, for 4061.302Sriastrad radeon GPU firmware. We cannot mark these as obsolete for 4071.302Sriastrad postinstall to fix, so if you updated src since 2019-08-26, and 4081.302Sriastrad ran build.sh distribution or ran build.sh release, you must 4091.302Sriastrad manually delete the following files in your DESTDIR (which is 4101.302Sriastrad usually $OBJDIR/destir.$ARCH), or from / if you have installed 4111.302Sriastrad them: 4121.302Sriastrad 4131.302Sriastrad /libdata/firmware/radeon/bonaire_ce.bin 4141.302Sriastrad /libdata/firmware/radeon/bonaire_mc.bin 4151.302Sriastrad /libdata/firmware/radeon/bonaire_me.bin 4161.302Sriastrad /libdata/firmware/radeon/bonaire_mec.bin 4171.302Sriastrad /libdata/firmware/radeon/bonaire_pfp.bin 4181.302Sriastrad /libdata/firmware/radeon/bonaire_rlc.bin 4191.302Sriastrad /libdata/firmware/radeon/bonaire_sdma.bin 4201.302Sriastrad /libdata/firmware/radeon/bonaire_smc.bin 4211.302Sriastrad /libdata/firmware/radeon/bonaire_uvd.bin 4221.302Sriastrad /libdata/firmware/radeon/hainan_ce.bin 4231.302Sriastrad /libdata/firmware/radeon/hainan_mc.bin 4241.302Sriastrad /libdata/firmware/radeon/hainan_me.bin 4251.302Sriastrad /libdata/firmware/radeon/hainan_pfp.bin 4261.302Sriastrad /libdata/firmware/radeon/hainan_rlc.bin 4271.302Sriastrad /libdata/firmware/radeon/hainan_smc.bin 4281.302Sriastrad /libdata/firmware/radeon/hawaii_ce.bin 4291.302Sriastrad /libdata/firmware/radeon/hawaii_mc.bin 4301.302Sriastrad /libdata/firmware/radeon/hawaii_me.bin 4311.302Sriastrad /libdata/firmware/radeon/hawaii_mec.bin 4321.302Sriastrad /libdata/firmware/radeon/hawaii_pfp.bin 4331.302Sriastrad /libdata/firmware/radeon/hawaii_rlc.bin 4341.302Sriastrad /libdata/firmware/radeon/hawaii_sdma.bin 4351.302Sriastrad /libdata/firmware/radeon/hawaii_smc.bin 4361.302Sriastrad /libdata/firmware/radeon/kabini_ce.bin 4371.302Sriastrad /libdata/firmware/radeon/kabini_me.bin 4381.302Sriastrad /libdata/firmware/radeon/kabini_mec.bin 4391.302Sriastrad /libdata/firmware/radeon/kabini_pfp.bin 4401.302Sriastrad /libdata/firmware/radeon/kabini_rlc.bin 4411.302Sriastrad /libdata/firmware/radeon/kabini_sdma.bin 4421.302Sriastrad /libdata/firmware/radeon/kaveri_ce.bin 4431.302Sriastrad /libdata/firmware/radeon/kaveri_me.bin 4441.302Sriastrad /libdata/firmware/radeon/kaveri_mec.bin 4451.302Sriastrad /libdata/firmware/radeon/kaveri_mec2.bin 4461.302Sriastrad /libdata/firmware/radeon/kaveri_pfp.bin 4471.302Sriastrad /libdata/firmware/radeon/kaveri_rlc.bin 4481.302Sriastrad /libdata/firmware/radeon/kaveri_sdma.bin 4491.302Sriastrad /libdata/firmware/radeon/mullins_ce.bin 4501.302Sriastrad /libdata/firmware/radeon/mullins_me.bin 4511.302Sriastrad /libdata/firmware/radeon/mullins_mec.bin 4521.302Sriastrad /libdata/firmware/radeon/mullins_pfp.bin 4531.302Sriastrad /libdata/firmware/radeon/mullins_rlc.bin 4541.302Sriastrad /libdata/firmware/radeon/mullins_sdma.bin 4551.302Sriastrad /libdata/firmware/radeon/oland_ce.bin 4561.302Sriastrad /libdata/firmware/radeon/oland_mc.bin 4571.302Sriastrad /libdata/firmware/radeon/oland_me.bin 4581.302Sriastrad /libdata/firmware/radeon/oland_pfp.bin 4591.302Sriastrad /libdata/firmware/radeon/oland_rlc.bin 4601.302Sriastrad /libdata/firmware/radeon/oland_smc.bin 4611.302Sriastrad /libdata/firmware/radeon/pitcairn_ce.bin 4621.302Sriastrad /libdata/firmware/radeon/pitcairn_mc.bin 4631.302Sriastrad /libdata/firmware/radeon/pitcairn_me.bin 4641.302Sriastrad /libdata/firmware/radeon/pitcairn_pfp.bin 4651.302Sriastrad /libdata/firmware/radeon/pitcairn_rlc.bin 4661.302Sriastrad /libdata/firmware/radeon/pitcairn_smc.bin 4671.302Sriastrad /libdata/firmware/radeon/tahiti_ce.bin 4681.302Sriastrad /libdata/firmware/radeon/tahiti_mc.bin 4691.302Sriastrad /libdata/firmware/radeon/tahiti_me.bin 4701.302Sriastrad /libdata/firmware/radeon/tahiti_pfp.bin 4711.302Sriastrad /libdata/firmware/radeon/tahiti_rlc.bin 4721.302Sriastrad /libdata/firmware/radeon/tahiti_smc.bin 4731.302Sriastrad /libdata/firmware/radeon/verde_ce.bin 4741.302Sriastrad /libdata/firmware/radeon/verde_mc.bin 4751.302Sriastrad /libdata/firmware/radeon/verde_me.bin 4761.302Sriastrad /libdata/firmware/radeon/verde_pfp.bin 4771.302Sriastrad /libdata/firmware/radeon/verde_rlc.bin 4781.302Sriastrad /libdata/firmware/radeon/verde_smc.bin 4791.302Sriastrad 4801.302Sriastrad We will re-import these radeon firmware images another way 4811.302Sriastrad later. 4821.302Sriastrad 4831.301Smartin20190727: 4841.301Smartin The uefi bootloader has gained tftp support and needs a clean 4851.301Smartin build. If you do update builds, manually clean its object 4861.301Smartin directory by something like: 4871.301Smartin cd sys/arch/i386/stand/efiboot && make clean 4881.301Smartin 4891.300Smartin20190723: 4901.344Sgutterid The jemalloc allocator in libc is now built without extended 4911.300Smartin debugging (for performance reasons). In update builds make sure 4921.326Sandvar to rebuild it completely, by removing all affected object files, 4931.300Smartin including compat builds, something like: 4941.300Smartin cd /usr/obj && find . -type d -name jemalloc|xargs rm -rf 4951.300Smartin 4961.299Smrg20190207: 4971.299Smrg GCC 7 switched for many ports. Update builds are likely to fail. 4981.299Smrg 4991.1SabsHints for a more successful build: 5001.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 5011.123Sjmc Use build.sh, but do not use its "expert mode": 5021.132Sjmmv This will automatically build the tools in the 5031.123Sjmc correct order, and it will keep the tools and the 5041.123Sjmc new build products from interfering with the running 5051.123Sjmc system. This will allow you to ignore most of the 5061.123Sjmc other advice in this file. 5071.2Smrg Build a new kernel first: 5081.2Smrg This makes sure that any new system calls or features 5091.2Smrg expected by the new userland will be present. This 5101.2Smrg helps to avoid critical errors when upgrading. 5111.1Sabs Use object directories: 5121.1Sabs This helps to keep stale object 5131.1Sabs files from polluting the build if a Makefile "forgets" 5141.1Sabs about one. It also makes it easier to clean up after 5151.1Sabs a build. It's also necessary if you want to use the 5161.1Sabs same source tree for multiple machines. 5171.123Sjmc To use object directories with build.sh: 5181.123Sjmc a) invoke build.sh with the "-M" or "-O" options. 5191.123Sjmc To use object directories without using build.sh: 5201.1Sabs a) cd /usr/src ; make cleandir 5211.2Smrg b) Add "OBJMACHINE=yes" to /etc/mk.conf 5221.2Smrg c) Add "MKOBJDIRS=yes" to /etc/mk.conf 5231.1Sabs d) cd /usr/src ; make build 5241.2Smrg Note that running "make obj" in a directory will create 5251.2Smrg in obj.$MACHINE directory. 5261.1Sabs Build to a DESTDIR: 5271.123Sjmc This helps to keep old installed files (especially libraries) 5281.123Sjmc from interfering with the new build. 5291.123Sjmc To build to a DESTDIR with build.sh, use the "-D" option. 5301.123Sjmc To build to a DESTDIR without using build.sh, set the DESTDIR 5311.123Sjmc environment variable before running make build. It should be 5321.123Sjmc set to the pathname of an initially empty directory. 5331.123Sjmc Problems: if you do not use build.sh, you might need to 5341.123Sjmc update critical utilities without using DESTDIR since 5351.123Sjmc nothing is executed from what is installed in DESTDIR. 5361.123Sjmc (See critical utils, below.) 5371.1Sabs Build often: 5381.1Sabs This keeps critical utilities current enough to not choke 5391.1Sabs on any other part of the source tree that depends on up to 5401.123Sjmc date functionality. If you use build.sh, you should not have 5411.123Sjmc this problem. 5421.241Swiz 5431.1SabsWhat to do if things don't work: 5441.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 5451.230StlsWhen things don't work there are usually a few things that commonly 5461.1Sabsshould be done. 5471.1Sabs 1) make includes 5481.1Sabs This should be done automatically by make build. 5491.1Sabs 2) cd share/mk && make install 5501.1Sabs Again, automatically done by make build. 5511.1Sabs 5521.1SabsFailsafe rebuild of a small part of the tree: 5531.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 5541.1SabsTo make sure you rebuild something correctly you want to do 5551.1Sabssomething like the following: 5561.1Sabs 1) Make sure the includes and .mk files are up to date. 5571.1Sabs 2) Make sure any program used to build the particular 5581.1Sabs utility is up to date. (yacc, lex, etc...) 5591.1Sabs 3) cd ...path/to/util... 5601.1Sabs make cleandir 5611.1Sabs rm ...all obj directories... 5621.1Sabs make cleandir # yes, again 5631.1Sabs make obj 5641.1Sabs make depend && make 5651.1Sabs 5661.1SabsFailsafe rebuild of the entire tree: 5671.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 5681.1SabsIf you really want to make sure the source tree is clean and 5691.2Smrgready for a build try the following. Note that sourcing /etc/mk.conf 5701.2Smrg(a make(1) Makefile) in this manner is not right, and will not work 5711.2Smrgfor anyone who uses any make(1) features in /etc/mk.conf. 5721.1Sabs 5731.1Sabs---cut here--- 5741.1Sabs#!/bin/sh 5751.1Sabs. /etc/mk.conf 5761.1Sabs 5771.58Slukemif [ -z $NETBSDSRCDIR ] ; then 5781.58Slukem NETBSDSRCDIR=/usr/src 5791.1Sabsfi 5801.58Slukemif [ \! -d $NETBSDSRCDIR ] ; then 5811.1Sabs echo Unable to find sources 5821.1Sabs exit 1 5831.1Sabsfi 5841.58Slukemfind $NETBSDSRCDIR -name \*.o -o -name obj.\* -o -name obj -exec rm \{\} \; 5851.1Sabs 5861.1Sabsif [ -z $BSDOBJDIR ] ; then 5871.1Sabs BSDOBJDIR=/usr/obj 5881.1Sabsfi 5891.1Sabsif [ -d $BSDOBJDIR ] ; then 5901.1Sabs rm -rf $BSDOBJDIR 5911.1Sabsfi 5921.1Sabs 5931.58Slukemcd $NETBSDSRCDIR && make cleandir 5941.1Sabs 5951.1Sabs---cut here--- 5961.1Sabs 5971.1SabsCritical utilities: 5981.1Sabs^^^^^^^^^^^^^^^^^^^ 5991.1Sabs usr.bin/make 6001.1Sabs usr.bin/yacc 6011.1Sabs usr.bin/lex 6021.11Slukem usr.bin/xlint 6031.142Sdrochner usr.bin/config 6041.1Sabs 6051.34SsimonbOther problems and possible solutions: 6061.1Sabs^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 6071.1SabsSymptom:Complaints involving a Makefile. 6081.17SerhFix: Rebuild usr.bin/make: 6091.17Serh cd usr.bin/make && make && make install 6101.111Ssimonb Or, a failsafe method if that doesn't work: 6111.348Srillig cd usr.bin/make && cc -DMAKE_NATIVE *.c -I. -o make \ 6121.348Srillig && install make /usr/bin 6131.17Serh 6141.1SabsFix: Make sure .mk files are up to date. 6151.1Sabs cd share/mk && make install 6161.2Smrg 6171.2SmrgSymptom:Kernel `config' fails to configure any kernel, including GENERIC. 6181.142SdrochnerFix: Rebuild usr.bin/config 6191.1Sabs 6201.4SitojunSymptom:Obsolete intermediate files are used during compilation 6211.4SitojunFix: Try the following sequence of commands in the directory in question. 6221.4Sitojun make cleandir; rm `make print-objdir`; make cleandir; make obj 6231.4Sitojun (If you built the tree without "make obj" in the past, obsolete files 6241.4Sitojun may remain. The command tries to clean everything up) 6251.5Swiz 6261.207SmbalmerSymptom:.../sysinst/run.c:xx: warning: initialization from incompatible 6271.207Smbalmer pointer type 6281.5SwizFix: Rebuild and install usr.bin/menuc 6291.12Sitojun 6301.12SitojunSymptom:mklocale not found during build in share/locale/ctype 6311.12SitojunFix: Build and install usr.bin/mklocale 6321.13Sdogcow 6331.86SkleinkSymptom:undefined reference to `__assert13' or `__unsetenv13' 6341.13SdogcowFix: Rebuild and install lib/libc 6351.13Sdogcow 6361.142SdrochnerSymptom:usr.bin/config fails to build. 6371.19ScgdFix: Try building with -DMAKE_BOOTSTRAP added to CFLAGS in Makefile. 6381.13Sdogcow 6391.19ScgdSymptom:undefined reference to `getprogname' or `setprogname' 6401.19ScgdFix: Rebuild and install lib/libc 6411.24Sabs 6421.223SjoergSymptom:Update build fails in src/tools/gcc complaining that a variable 6431.223Sjoerg (e.g. CPPFLAGS) has changed since the previous run. 6441.223SjoergFix: Run "nbmake-${ARCH} clean" in src/tools/gcc or do a clean build. 6451.257Sapb 6461.257SapbSymptom:cvs [update aborted]: cannot open directory /cvsroot/src/...: 6471.257Sapb No such file or directory. 6481.257SapbCause: If a directory is created by mistake, then it is sometimes 6491.257Sapb deleted from the CVS repository using administrative commands 6501.257Sapb that bypass the normal cvs access controls. If your cvs working tree 6511.257Sapb contains references to a directory that has been deleted on the 6521.257Sapb server in this way, then "cvs update" reports this error. 6531.257SapbFix: Recursively delete the affected directory from your working tree 6541.257Sapb and try the update again. 655