Annotation of src/UPDATING, Revision 1.139
1.139 ! christos 1: $NetBSD: UPDATING,v 1.138 2005/04/17 23:12:40 lukem Exp $
1.1 abs 2:
1.123 jmc 3: This file (UPDATING) is intended to be a brief reference to recent
4: changes that might cause problems in the build process, and a guide for
5: what to do if something doesn't work.
1.1 abs 6:
1.123 jmc 7: For a more detailed description of the recommended way to build NetBSD
8: using build.sh, see the BUILDING file.
9:
10: Note that much of the advice in this UPDATING file was written before
11: build.sh existed. Nevertheless, the advice here may be useful for
12: working around specific problems with build.sh.
13:
14: See also: BUILDING, build.sh, Makefile.
1.1 abs 15:
16: Recent changes:
17: ^^^^^^^^^^^^^^^
1.138 lukem 18:
1.139 ! christos 19: 20050531:
! 20: genassym.sh(8) was moved to genassym(8). You need to either build
! 21: tools first or install the version of genassym from /usr/sbin before
! 22: you can build a kernel again.
! 23:
1.138 lukem 24: 20050417:
25: postinstall(8) was moved from /etc to /usr/sbin and made part
26: of the "base" set, to make it easier to invoke after an
27: upgrade.
28:
1.136 cube 29: 20050325:
30: pcppi(4) was separated in two devices, adding attimer(4). Be sure
31: to add a config line for an attimer(4) device in your kernel
32: configuration, or you won't be able to set the pitch of the beep
1.137 cube 33: with wsconsctl. Depending on the default value for the pitch, you
34: might even not hear any more beep. Also, it is advised to attach both
35: devices the same way (i.e., both on isa or both on acpi) or the
36: pcppi(4) device may fail to find the attimer(4) one.
1.136 cube 37:
1.135 jmc 38: 20050211:
39: Fixes to tools/Makefile.gnuhost may cause UPDATE=1 builds in
40: some of the cross tools to fail if they use configure. Some configure's
41: cache the environment passed in and notice the new environment is
42: different and abort. Doing a clean in tools/ should be enough to
43: make a build continue.
44:
1.134 christos 45: 20050109:
46: Since su is using pam by default now, make sure that you have
47: /etc/pam.d populated (postinstall will do that automatically
48: for you). Otherwise su will fail open (i.e. will not require
49: a password).
50:
1.133 christos 51: 20041229:
52: Make had a path resolution bug that manifested itself as not
53: being able to install openpam.3. This bug has been fixed, but
54: you might need to rebuild make manually first to get through
55: the build.
56:
1.130 christos 57: 20041201:
58: Userland programs have been changed to use /dev/bpf instead of
59: /dev/bpfX. You need to create that device by installing a new
1.131 wiz 60: MAKEDEV and running it, or mv /dev/bpf0 /dev/bpf && rm /dev/bpf[0-9]*
1.99 mrg 61:
1.129 jmc 62: 20041006:
63:
64: A bug was introduced into /bin/sh (var.c rev 1.35) which causes
65: variables to not export correctly to subshells in all cases. This
66: will cause builds to break if that version of /bin/sh is installed
67: on the system. The proper version of /bin/sh can be verified with:
68:
69: ident /bin/sh | grep var
70:
71: Any /bin/sh w. version 1.35 will not work and needs to be updated
72: before attempting a build.
73:
1.127 christos 74: 20041001:
75: The ipfilter kernel sources moved from sys/netinet to
76: dist/sys/ipf/netinet. Due to the move some Makefile
77: dependencies are now dangling requiring a make cleandir
1.128 he 78: before they work again (kdump, ktruss, rescue, ipf, and
79: ftp-proxy are the victims).
1.127 christos 80:
1.125 atatat 81: 20040715:
82: The rc.d/sendmail script now uses a heuristic to determine
83: if sendmail should be started at boot time. It checks the
84: contents of /etc/mailer.conf, /etc/mail/submit.cf, and the
85: owner and mode of the sendmail binary to see if any changes
86: to the mail infrastructure have been made. If no changes
87: are detected, it will start an SMTP listener.
88:
89: Setting sendmail=NO in /etc/rc.conf will override this.
90:
91: If you are only using sendmail by default and only for
92: local delivery, it is important that you also update your
93: sendmail.cf so that the SMTP listener only listens on the
94: loopback interface.
95:
96: 20040715:
97: The method by which athhal-elf.o gets pulled into i386
98: kernel builds has been changed again. The latest version
99: of bsd.files.mk is no longer required.
100:
1.124 jmc 101: 20040621:
102: Due to the recent rototill of tools/compat it's crucial one starts
103: from a clean objdir under tools/*.
104:
105: This is mostly due to generated files (yacc and lex sources) needing
1.125 atatat 106: to be generated with new rules from bsd.hostprog.mk.
1.124 jmc 107:
108: The safest course is to rm -rf all objects under tools before building.
109:
1.121 lukem 110: 20040516:
111: The end-user modifiable X11 configuration has been moved
112: from /usr/X11R6/lib/X11/<dir> to /etc/X11/<dir>.
113: Ensure that src and xsrc is up to date, and run
114: "make cleandir" in src/x11 before your next build.
115:
1.126 lukem 116: postinstall currently doesn't migrate the files from
117: /usr/X11R6/lib/X11/* to /etc/X11/* although it does
118: detect that this needs to occur, so you'll have to
119: manually move these files yourself.
120:
1.119 atatat 121: 20040426:
122: Support for the original dynamic sysctl node structure has
123: been removed in favor of the newer layout. This affects
124: consumers of the create and delete interface, as well as
125: the dynamic discovery mechanism. This is believed only to
126: be the sysctl(8) binary itself, at this point in time, so
127: the only effect of this should be that a sysctl binary
128: built from sources dated between 2003/12/04 and 2004/03/24
129: will not work on a kernel built from sources dated after
130: 2004/04/25. If you need a new sysctl binary but build.sh
131: does not work, make sure that your revision of
1.120 atatat 132: src/sys/sys/sysctl.h is 1.112 (or later), and then the
133: do the following:
1.119 atatat 134:
1.120 atatat 135: cd /usr/src (or wherever your source tree is)
136: make USETOOLS=no includes
137: cd lib/libc
138: make USETOOLS=no dependall install
139: cd ../../sbin/sysctl
1.119 atatat 140: make USETOOLS=no dependall install
141:
1.122 itojun 142: If you are using older sysctl binary, GNU autoconf would fail to
143: identify your machine architecture, and tries to build binary for
144: "unknown-unknown-netbsd20F" or something like that. if that happens,
145: make sure to follow the above steps.
146:
1.118 dbj 147: 20040425:
148: The ffs superblock issues listed below under 20040109 and 20030402
149: are now automatically addressed by the /etc/rc.d/fixsb script or by
150: sysinst when it checks a a filesystem. The manual fsck_ffs -b16 -c4
151: invocation mentioned below will continue to work and is now
152: automated by those scripts. Note that under certain circumstances,
153: affected filesystems upgraded to a -current kernel first before
154: upgrading their userland with the fixsb and fsck_ffs fixes may
155: encounter a 'freeing free inode' panic when writing to the affected
156: filesystem, so it is a good idea to repair the filesystem as soon as
157: possible. For more details on the fixsb script, see pr install/25138.
158:
1.115 christos 159: 20040418:
1.121 lukem 160: statfs(2) and friends have been replaced with statvfs(2). Before
1.115 christos 161: installing a newly build userland make sure that you are running
162: a newly built kernel with COMPAT_20 set. In addition your libc
163: build might not work (undefined SYS_statfs symbol) because make
164: clean does not know how to remove files it does not know about
1.116 christos 165: anymore. Manually remove all generated .S sources and objects
166: from the libc build directory.
1.115 christos 167:
1.114 jmc 168: 20040326:
169: The method by which athhal-elf.o gets pulled into i386 kernel builds
1.117 jmc 170: has been changed. The file is now stored as a uuencoded file in CVS
1.114 jmc 171: and the generated Makefile will use the new .uue rules from bsd.file.mk
172: to build it.
173:
174: This means you must have the latest bsd.files.mk installed when
175: building a kernel without USETOOLS=yes.
176:
1.113 dan 177: 20040318:
178: A bug in the cgd(4) blowfish code was corrected, without
179: provision of backwards compatibility, after several public
180: notices over several months. Users of cgd with blowfish cipher
181: ONLY must dump their data before updating their kernels, and
182: recreate cgd's and restore data using the new kernel. See
183: (recent message to current-users, URL when mail-index has updated)
184:
1.108 bjh21 185: 20040313:
186: On acorn32, the opms and qms drivers have been withdrawn, and
187: the old wsqms driver is now called qms. Kernel config files
188: will need updating. See the ones in sys/arch/acorn32/conf
189: for examples.
190:
1.106 bjh21 191: 20040125:
192: On acorn32, the beep and sysbeep devices are no longer
193: needed, and will need to be deleted from kernel configuration
194: files.
1.105 bjh21 195:
1.102 dbj 196: 20040109:
197: Compatibility for old ffs superblock layouts has been
198: added, and the restrictive fsck checks have been reenabled
199: when using those layouts. If you have been using -current
200: since 20030402, you may find that fsck again signals fatal
1.110 dbj 201: superblock mismatches. To repair, make sure you have
1.111 simonb 202: an updated fsck_ffs and then you can use fsck_ffs -b 16 -c 4
1.109 dbj 203: to complete the filesystem upgrade. A message has
1.111 simonb 204: been added to the kernel which should detect this problem.
205: See the following discussion for more information:
1.112 keihan 206: http://mail-index.NetBSD.org/current-users/2004/01/11/0022.html
1.102 dbj 207:
1.99 mrg 208: 20031203:
1.100 keihan 209: New binutils builds may fail due to old dependencies.
1.99 mrg 210: It's necessary to "make cleandir" to ensure that
211: the dependencies will be rebuilt correctly.
1.98 wiz 212:
213: 20031111:
214: A newer mkdep is needed. Error noting that is
215: cc: Ambiguous abbreviation --
1.97 lukem 216:
217: 20031008:
218: /usr/include/sys/disklabel_mbr.h was removed.
219: It's necessary to "make cleandir" to ensure that
220: the dependencies will be rebuilt correctly.
1.96 christos 221:
1.109 dbj 222: 20031007:
1.111 simonb 223: A sign exension bug was fixed which set all the high bits
224: of our newly expanded ffs fs_flags. This should only
225: affect users who installed or upgraded in September of 2003.
1.109 dbj 226: A small utility program was posted to tech-kern which
1.111 simonb 227: should fix this problem, and a warning message was added
228: to the kernel which should discover and warn about it. See
229: http://mail-index.NetBSD.org/tech-kern/2003/10/07/0005.html
1.109 dbj 230:
1.96 christos 231: 20030906:
232: With the addition of siginfo support the old signal trampoline
233: code has been deprecated to COMPAT_16. Make sure that your running
234: kernel has COMPAT_16 enabled before building userland.
1.94 christos 235:
236: 20030801:
1.95 wiz 237: With the new openssl, there is some header and library shuffling.
1.94 christos 238: rm -f /usr/include/des.h /usr/include/kerberosIV/* /lib/libdes* \
1.95 wiz 239: /usr/lib/libdes* before building.
1.92 wiz 240:
241: 20030703:
242: Texinfo was updated to 4.6. To avoid failures when trying to
243: build the included texinfo files, do:
244:
245: cd src/gnu/usr.bin/texinfo
246: make MKINFO=no dependall install
1.90 wiz 247:
248: 20030630:
1.101 junyoung 249: Groff was updated to 1.19; it's probably necessary to do
1.91 wiz 250: cd share/mk && make install
1.90 wiz 251: cd src/gnu/usr.bin/groff
252: make MKMAN=no dependall install
253: (untested).
1.89 christos 254:
255: 20030516:
256: Due to bugs in the export handling code, invalid export lines
257: were accepted before and caused the kernel to panic when
258: mountd got restarted because it freed memory that had already
259: been freed. This has been fixed and the kernel checks
260: export addresses very strictly. If you upgrade your kernel,
261: make sure you also upgrade mountd, because if your export
262: file contains lines with an old inet4 address syntax (i.e.
263: a.b.c or a.b or a), they will get rejected by the new kernel.
1.87 bjh21 264:
265: 20030402:
266: The superblock layout for FFS was changed. If you have 1.6
267: fsck binaries, they will signal a fatal superblock mismatch
268: with the first alternate, because they compare too many
269: fields (even ones that aren't useful). If possible, upgrade
270: your fsck_ffs binary before using a new kernel.
271: None of this signals actual filesystem damage.
1.85 atatat 272:
273: 20030324:
274: sendmail version 8.12.8 was imported. Since sendmail is
275: now setgid to the smmsp group, and runs in "collection"
276: mode for most common activities, there is a new config
277: file called submit.cf that needs to live in /etc/mail.
278: The generic submit.cf sample in /usr/share/sendmail/cf
279: is named netbsd-msp.cf. Upgrading your regular sendmail
280: configuration file is also strongly advised.
281:
282: See the section named "MESSAGE SUBMISSION PROGRAM" in
283: the updated /usr/share/sendmail/README file for more
284: information.
1.82 wiz 285:
286: 20030117:
287: Texinfo was updated to 4.3. To avoid failures when trying to
288: build the included texinfo files, do:
289:
290: cd src/gnu/usr.bin/texinfo
291: make MKINFO=no dependall install
1.81 lukem 292:
293: 20021223:
294: The METALOG format changed slightly, to remove the leading
295: "${DESTDIR}" from path names.
296: This only affects people building with UNPRIVED.
297: For complete safety, remove the DESTDIR entirely and
298: update tools/mtree, before running make build.
1.88 itojun 299:
300: 20021219:
301: CVS repository layout was changed. See the following for details
302: if you are using (anonymous) cvs to update your tree.
303:
1.93 salo 304: http://mail-index.NetBSD.org/netbsd-announce/2002/12/19/0000.html
1.80 lukem 305:
306: 20021219:
307: install(1) had a '-N dbdir' option added, to specify an
308: alternate location to look up users & groups (instead
309: of the host system passwd(5) and group(5) databases).
310:
311: The build system was modified to take advantage of
312: this option (using ${NETBSDSRCDIR}/etc), so if you
1.83 kei 313: use USETOOLS==no, you may have to rebuild and
1.80 lukem 314: reinstall usr.bin/xinstall first.
1.78 lukem 315:
316: 20021130:
317: fparseln(3) moved from libutil to libc.
318: If building to DESTDIR=/, reinstall the includes
319: and rebuild libc:
320: make includes
321: make do-lib-libc
322: If using build.sh, "cd tools/compat && make clean"
323: before rebuilding the tools.
1.77 lukem 324:
325: 20021126:
326: The mk.conf(5) variable SYS_INCLUDE has been deprecated,
327: including the optional "SYS_INCLUDE=symlinks" support.
328: All header files, including <sys/*.h> are copied into
329: /usr/include.
1.76 thorpej 330:
331: 20021121:
332: The C run-time support files crtbegin.o and crtend.o
333: (and their companions crtbeginS.o and crtendS.o) were
334: split up, with new crti.o and crtn.o files resulting.
335: This means that libtool needs to be rebuilt once the
336: new libraries are installed. The process of rebuilding
337: libtool will cause it to automatically notice the new
338: required files, but it *must* be rebuilt in order to
339: do this.
340:
341: An out-of-date libtool will result in shared libraries
342: which lack _init() and _fini() routines, which means that
343: their global contructors/destructors will not be invoked.
1.75 thorpej 344:
345: 20021121:
346: A bug related to how ARM ELF objects were tagged has been
347: corrected.
348:
349: NetBSD ARM ELF uses the soft-VFP floating point model by
350: default. However, the assembler lacked support for marking
351: objects as using the VFP floating point format, and the
1.79 wiz 352: compiler was not properly passing the flag indicating "soft-VFP"
1.75 thorpej 353: to the assembler.
354:
355: Unfortunately, this means that the linker will now consider
356: old (i.e. not marked "softvfp") NetBSD ARM ELF objects to be
357: incompatible with new (properly marked) objects.
358:
359: The problem will only manifest itself if you attempt to compile
360: a new program using the fixed toolchain, and link that program
361: against old libraries which do not have the proper "softvfp"
362: markings. ALL OF YOUR EXISTING BINARIES AND SHARED LIBRARIES
363: WILL CONTINUE TO WORK PROPERLY.
364:
365: The only work-around for the problem is to recompile all of
366: the libraries on the system. The easiest way to do this for
1.79 wiz 367: system libraries is to install a binary snapshot; they are
1.93 salo 368: generally available on releng.NetBSD.org. Any packages you
1.75 thorpej 369: have installed which supply libraries will have to be recompiled
370: if you wish to link new programs against those libraries.
371:
372: If you have questions about this matter, please contact
1.93 salo 373: port-arm@NetBSD.org.
1.73 provos 374:
375: 20021011:
376: Systrace has been improved to support privilege elevation.
377: Updating the kernel requires the userland part of systrace
1.79 wiz 378: to be rebuilt.
1.72 thorpej 379:
380: 20021010:
381: The config(8) grammar was changed to allow options to register
382: dependencies on attributes, as well as other options. Users
383: must update and reinstall usr.sbin/config before building a new
384: kernel.
1.70 thorpej 385:
386: 20021009:
387: A new attribute dependency syntax was introduced to config(8),
388: which is now used by the SCSI configuration description. Users
1.71 wiz 389: must update and reinstall usr.sbin/config before building a new
1.70 thorpej 390: kernel.
1.69 thorpej 391:
392: 20021003:
393: Several changes have been made to the autoconfiguration
394: framework. Users must update and reinstall usr.sbin/config
395: before building a new kernel.
1.74 jschauma 396:
397: 20021001:
398: The i386mp branch has been merged. To compile a kernel, users
399: will need to add the option 'cpu* at mainbus?' to their configuration
400: file. Multiprocessor kernels will need
401: ioapic* at mainbus? apid ?
402: options MULTIPROCESSOR
403: options COM_MPLOCK
1.68 lukem 404:
405: 20020922:
406: MKDYNAMICROOT=yes enabled by default, which means that
407: certain shared libraries are installed into /lib, the shared
408: linker is installed into /libexec, and all programs in /bin
409: and /sbin are dynamically linked.
410: If you do not use "make build", you should ensure that
411: you have the libraries and shared linker in the new locations,
412: with:
413: make do-lib-csu do-lib-libc do-lib do-gnu-lib do-ld.elf_so
1.67 lukem 414:
415: 20020917:
416: USE_NEW_TOOLCHAIN has been replaced with:
417: - TOOLCHAIN_MISSING -- set to "yes" on platforms for which
418: there is no working in-tree toolchain (hppa, ns32k, sh5,
419: x86_64).
420: - EXTERNAL_TOOLCHAIN -- if defined by the user, points to the
1.79 wiz 421: root of an external toolchain (e.g. /usr/local/gnu). This
1.67 lukem 422: enables the cross-build framework even for TOOLCHAIN_MISSING
423: platforms.
1.66 gehenna 424:
425: 20020906:
426: gehenna-devsw has been merged into the trunk. Need to update and
1.79 wiz 427: reinstall usr.sbin/config before building the kernel.
1.65 lukem 428:
429: 20020822:
430: Crunched rescue tools (contents of /bin and /sbin, plus others)
431: are now provided in /rescue.
432:
433: To ensure that these are built statically linked (no matter
434: what the setting of LDSTATIC is), use a crunchgen(1) built
435: from sources newer than 20020820 (see the next entry).
436:
437: 20020820:
438: crunchgen(1) changed to ensure that the generated program
439: is statically linked.
440:
441: Solution: update and reinstall usr.bin/crunch
1.84 grant 442:
443: 20020605:
444: smmsp user/group has been added for sendmail.
445:
446: Add the following into /etc/group:
447:
448: smmsp:*:17:
449:
450: and the following to /etc/master.passwd (via vipw):
451:
452: smmsp:*:17:17::0:0:Sendmail Message Submission Program:/nonexistent:/sbin/nologin
1.61 itojun 453:
454: 20020515:
455: sshd user/group has been added. Need to hand add this in, or sshd
456: will not let you log in (with default, or UsePrivlegeSeparation=yes)
457:
458: Add the following into /etc/group:
459:
460: sshd:*:16:
461:
462: and the following to /etc/master.passwd (via vipw):
463:
1.63 enami 464: sshd:*:16:16::0:0:& pseudo-user:/var/chroot/sshd:/sbin/nologin
1.61 itojun 465:
1.79 wiz 466: Also /var/chroot/sshd directory needs to be present (digged as part of
467: the build process).
1.60 sommerfe 468:
469: 20020426:
470: NBUILDJOBS obsoleted in favor of just using -j.
1.59 lukem 471:
472: 20020426:
473: etc/postinstall added, which performs various checks for
474: configuration file updates and changes, and can fix most of
475: the problems identified.
476: This should make it much easier to upgrade a system's
477: configuration from earlier systems (as far back as NetBSD 1.5).
1.56 lukem 478:
479: 20020320:
1.79 wiz 480: <bsd.lib.mk> needs a new install(1) for its "-a cmd" support.
481: Build and install at usr.bin/xinstall before the build.
1.56 lukem 482:
1.55 itojun 483: 20020319:
1.79 wiz 484: Raw IPv6 socket now makes strict checking for sa_family and sa_len
485: on send(2) operation. Be sure to have sbin/rtsol and usr.sbin/rtsold
1.55 itojun 486: newer than November 2001 when you upgrade the kernel.
487:
1.54 itojun 488: 20020311:
489: ssh configuration files were moved from /etc to /etc/ssh. Beware
490: if you restart your machine from remote. Note that sshd.conf needs
491: to be changed (due to the use of "/etc" inside).
492:
493: 20020223:
1.53 matt 494: Users of the VAX port will need to rebuild and install gas
495: so it deal with the now present register prefix used in all
496: the VAX assembly files.
497:
1.50 itojun 498: 20020118:
499: ntpd user/group has been added. Need to hand add this in or builds
500: will break as mtree aborts early.
501:
502: Add the following into /etc/group:
503:
504: ntpd:*:15:
505:
506: and the following to /etc/master.passwd (via vipw):
507:
508: ntpd:*:15:15::0:0:Ntpd pseudo-user:/var/chroot/ntpd:/sbin/nologin
509:
1.49 jmc 510: 20011207:
511: If you're attempting to build a snapshot on sparc64 and are getting
512: reloc errors from the toolchain groff binary this means your native
513: toolchain has some broken C++ bits.
514:
515: To fix:
516:
517: Build a new toolchain (i.e. build.sh -t)
518: Use the new toolchain to build and install natively (i.e. /usr/lib)
519:
520: gnu/lib/libgcc
1.51 pooka 521: gnu/lib/libstdc++
1.49 jmc 522:
523: After this a snapshot will be able to be built.
524:
1.47 jmc 525: 20011201:
526: In order for a sparc64 build to work you must have a working awk. If
527: you've built and installed a system with the new toolchain up to this
1.52 wiz 528: point you do not have a working awk as its ability to do floating
1.47 jmc 529: point is broken.
530:
531: To build:
532:
533: remake and install gnu/lib/libgcc
534: remake and install gnu/usr.bin/gawk into /usr/bin (make sure it links
1.48 jmc 535: against the new libgcc.a)
1.47 jmc 536:
1.46 thorpej 537: 20011128:
538: Kernel config information was changed to use defflag in
539: the various "files" files. Bug fixes to config(8) are
540: required in order for this to work properly. Make sure
541: to build and install in usr.sbin/config before attempting
542: to build a new kernel.
543:
1.45 yamt 544: 20011030:
545: libc/locale/wcstod.c now needs new lint(1). Update lint(1)
546: before building libc.
1.43 mason 547:
1.44 tv 548: 20011029:
549: The new document BUILDING.mdoc (view with nroff | more, or
550: see pre-generated .txt and .html versions) describes the build
551: procedure in great detail. BUILDING, and the USE_NEW_TOOLCHAIN
552: build process, are intended in the long run to replace this
553: manual update log.
554:
555: Users building a USE_NEW_TOOLCHAIN system should read the
556: BUILDING document for caveats. Generally, BUILDING supersedes
557: UPDATING for these systems, as tool updating is taken care of
558: by the new build system.
1.42 perry 559:
560: 20011028:
561: src/etc/Makefile now needs install to be able to handle
562: symlinks that point to nowhere. A bug in install that
563: prevented this was corrected.
564:
565: Solution: update and reinstall usr.bin/xinstall
566: Better Solution: Use the new toolchain and it will just work
567: for you.
1.40 lukem 568:
569: 20011006:
570: /etc/mtree/NetBSD.dist has been updated to take advantage of
571: absolute path support added to mtree(8). Older mtree(8)s don't
572: understand the format.
573:
574: Solution: update and reinstall usr.sbin/mtree
1.39 jmc 575:
576: 20011004:
577: Crunchgen has been updated to work via reach-over makefiles. Updating
578: is suggested before running a snapshot build
1.36 tv 579:
1.35 thorpej 580: 20010915:
581: The new "ubcperf" code committed by Chuck Silvers removed
582: a header file, uvm/uvm_vnode.h. There may be stale .depend
583: files that still reference this file.
584:
585: Solution: "make cleandir && make dependall" in affected
586: directories.
1.31 enami 587:
588: 20010803:
589: grep.info is now built from grep.texi using makeinfo. Since it
590: requires makeinfo v4.0, you need to install new texinfo before
591: building gnu/usr.bin/grep. To install new texinfo, please follow
592: the instruction described in 20010726 entry.
1.30 enami 593:
1.64 sommerfe 594: 20010803:
1.41 wiz 595: (i386 only): i386 kernel now uses new instructions like
1.111 simonb 596: `fxsave' which old gas doesn't understand. To build the
1.64 sommerfe 597: kernel successfully, you need to build and install a new toolchain,
598: (i.e., build.sh -t) or (temporarily) comment out "options I686_CPU"
599: from your kernel configuration until you rebuild your userland.
600: See 20011029 above and BUILDING file in this directory for more information.
601: [updated 20020630 since i386 gas moved when USE_NEW_TOOLCHAIN enabled]
1.29 bjh21 602:
603: 20010731:
604: Bootloader update on ELF platforms. DDB in kernels from before
605: this will be unable to read symbol tables provided by newer
606: bootloaders.
1.27 assar 607:
608: 20010726:
609: Texinfo was updated to 4.0. To avoid failures when trying to
1.28 assar 610: build the included texinfo files, do:
611:
612: cd src/gnu/usr.bin/texinfo
613: make MKINFO=no dependall install
1.25 thorpej 614:
615: 20010718:
616: Enabled correct .init/.fini processing in crt0. The way this
617: was done was to change a -I directive to cc(1), which means
618: make(1) will have a stale dependency (it will be checking the
619: timestamp on the wrong "dot_init.h").
620:
621: The symptom you will see is that new programs die with SIGSEGV
622: if you have a stale dependency.
623:
624: Solution: "make cleandir" in both lib/csu and libexec/ld.elf_so
625: before starting your build.
1.26 thorpej 626:
627: 20010628:
628: A construct was added to uvm_page.h that uncovered a bug
629: in lint(1). If you get a warning/error about a non-portable
630: bitfield, update your lint(1) before proceeding.
1.21 jmc 631:
632: 20010226:
1.22 jmc 633: Added named user/group to system. Need to hand add this in or builds
1.21 jmc 634: will break as mtree aborts early.
635:
636: To work around add by hand:
637:
638: named:*:14:
639:
1.22 jmc 640: to /etc/group and add:
641:
642: named:*:14:14::0:0:Named pseudo-user:/var/named:/sbin/nologin
643:
644: to master.passwd (use vipw for instance if doing by hand).
645:
646: Now a make build should progress.
1.18 jmc 647:
648: 20010219:
1.52 wiz 649: get/setprogname() added. Any hostprogs that may use this will need
1.111 simonb 650: to be bootstrapped manually until the host system is current.
1.18 jmc 651:
1.111 simonb 652: Known problems: sys/arch/macppc/stand/fixcoff
1.19 cgd 653: usr.sbin/config (adding -DMAKE_BOOTSTRAP to
654: CFLAGS and rebuilding should work)
1.20 jmc 655: usr.sbin/mdsetimage - Build a static copy if
1.111 simonb 656: building a snapshot before fully bootstrapped.
1.15 christos 657:
658: 20010204:
659: prepare the code to compile with stricter gcc flags. in
660: particular start eliminating redundant declarations. Yacc
661: needs to be installed before make build.
1.10 christos 662:
663: 20010114:
664: introduce .if commands(target) in make(1). You need to
665: bring everything up-to-date first, then without installing
1.23 tron 666: anything make and install in usr.bin/make, then proceed
1.10 christos 667: with make build.
1.9 sommerfe 668:
669: 20010101:
670: bsd.subdir.mk committed 20001230 had a bug which caused
671: afterinstall targets to run too soon; update again.
1.8 sommerfe 672:
673: 20001230:
674: New share/mk files needed to support .WAIT in SUBDIR variables.
675: If you get make errors,
676: (cd share/mk; make install)
677: Also, PRINTOBJDIR has changed and is now used more heavily.
1.6 ad 678:
679: 20001019:
1.7 ad 680: The `ca' device driver has been replaced by `ld'; although the
1.6 ad 681: major and minor numbers haven't changed, you should update your /dev
682: directory.
1.1 abs 683:
1.4 itojun 684: 20000929:
685: The following make directives are obsoleted.
686: MKCRYPTO_RSA NOCRYPTO_RSA NOCRYPTO_RC5 NOCRYPTO_IDEA
687: By default, RSA is built into libcrypto. IDEA and RC5 will not be
1.16 wiz 688: built into libcrypto. By using MKCRYPTO_{RC5,IDEA}, you can build
1.4 itojun 689: additional library libcrypto_{idea,rc5}.
1.1 abs 690:
691:
692: Hints for a more successful build:
693: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1.123 jmc 694: Use build.sh, but do not use its "expert mode":
1.132 jmmv 695: This will automatically build the tools in the
1.123 jmc 696: correct order, and it will keep the tools and the
697: new build products from interfering with the running
698: system. This will allow you to ignore most of the
699: other advice in this file.
1.2 mrg 700: Build a new kernel first:
701: This makes sure that any new system calls or features
702: expected by the new userland will be present. This
703: helps to avoid critical errors when upgrading.
1.1 abs 704: Use object directories:
705: This helps to keep stale object
706: files from polluting the build if a Makefile "forgets"
707: about one. It also makes it easier to clean up after
708: a build. It's also necessary if you want to use the
709: same source tree for multiple machines.
1.123 jmc 710: To use object directories with build.sh:
711: a) invoke build.sh with the "-M" or "-O" options.
712: To use object directories without using build.sh:
1.1 abs 713: a) cd /usr/src ; make cleandir
1.2 mrg 714: b) Add "OBJMACHINE=yes" to /etc/mk.conf
715: c) Add "MKOBJDIRS=yes" to /etc/mk.conf
1.1 abs 716: d) cd /usr/src ; make build
1.2 mrg 717: Note that running "make obj" in a directory will create
718: in obj.$MACHINE directory.
1.1 abs 719: Build to a DESTDIR:
1.123 jmc 720: This helps to keep old installed files (especially libraries)
721: from interfering with the new build.
722: To build to a DESTDIR with build.sh, use the "-D" option.
723: To build to a DESTDIR without using build.sh, set the DESTDIR
724: environment variable before running make build. It should be
725: set to the pathname of an initially empty directory.
726: Problems: if you do not use build.sh, you might need to
727: update critical utilities without using DESTDIR since
728: nothing is executed from what is installed in DESTDIR.
729: (See critical utils, below.)
1.1 abs 730: Build often:
731: This keeps critical utilities current enough to not choke
732: on any other part of the source tree that depends on up to
1.123 jmc 733: date functionality. If you use build.sh, you should not have
734: this problem.
1.1 abs 735:
736: What to do if things don't work:
737: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
738: When things don't work there is usually a few things that commonly
739: should be done.
740: 1) make includes
741: This should be done automatically by make build.
742: 2) cd share/mk && make install
743: Again, automatically done by make build.
744:
745: Failsafe rebuild of a small part of the tree:
746: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
747: To make sure you rebuild something correctly you want to do
748: something like the following:
749: 1) Make sure the includes and .mk files are up to date.
750: 2) Make sure any program used to build the particular
751: utility is up to date. (yacc, lex, etc...)
752: 3) cd ...path/to/util...
753: make cleandir
754: rm ...all obj directories...
755: make cleandir # yes, again
756: make obj
757: make depend && make
758:
759: Failsafe rebuild of the entire tree:
760: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
761: If you really want to make sure the source tree is clean and
1.2 mrg 762: ready for a build try the following. Note that sourcing /etc/mk.conf
763: (a make(1) Makefile) in this manner is not right, and will not work
764: for anyone who uses any make(1) features in /etc/mk.conf.
1.1 abs 765:
766: ---cut here---
767: #!/bin/sh
768: . /etc/mk.conf
769:
1.58 lukem 770: if [ -z $NETBSDSRCDIR ] ; then
771: NETBSDSRCDIR=/usr/src
1.1 abs 772: fi
1.58 lukem 773: if [ \! -d $NETBSDSRCDIR ] ; then
1.1 abs 774: echo Unable to find sources
775: exit 1
776: fi
1.58 lukem 777: find $NETBSDSRCDIR -name \*.o -o -name obj.\* -o -name obj -exec rm \{\} \;
1.1 abs 778:
779: if [ -z $BSDOBJDIR ] ; then
780: BSDOBJDIR=/usr/obj
781: fi
782: if [ -d $BSDOBJDIR ] ; then
783: rm -rf $BSDOBJDIR
784: fi
785:
1.58 lukem 786: cd $NETBSDSRCDIR && make cleandir
1.1 abs 787:
788: ---cut here---
789:
790: Critical utilities:
791: ^^^^^^^^^^^^^^^^^^^
792: gnu/usr.bin/egcs
1.3 itojun 793: usr.bin/compile_et
1.1 abs 794: usr.bin/make
795: usr.bin/yacc
796: usr.bin/lex
1.11 lukem 797: usr.bin/xlint
1.2 mrg 798: usr.sbin/config
1.1 abs 799:
1.34 simonb 800: Other problems and possible solutions:
1.1 abs 801: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
802: Symptom:Unreasonable compiler errors.
803: Fix: Rebuild gnu/usr.bin/egcs
804:
805: Symptom:Complaints involving a Makefile.
1.17 erh 806: Fix: Rebuild usr.bin/make:
807: cd usr.bin/make && make && make install
1.111 simonb 808: Or, a failsafe method if that doesn't work:
1.17 erh 809: cd usr.bin/make && cc *.c */*.c -I . -o make && mv make /usr/bin
810:
1.1 abs 811: Fix: Make sure .mk files are up to date.
812: cd share/mk && make install
1.2 mrg 813:
814: Symptom:Kernel `config' fails to configure any kernel, including GENERIC.
815: Fix: Rebuild usr.sbin/config
1.1 abs 816:
817: Symptom:
818: Fix: Rebuild usr.bin/yacc
819:
820: Symptom:
821: Fix: Rebuild usr.bin/lex
822:
823: Symptom:
824: Fix: rm /usr/lib/libbfd.a
1.4 itojun 825:
826: Symptom:Obsolete intermediate files are used during compilation
827: Fix: Try the following sequence of commands in the directory in question.
828: make cleandir; rm `make print-objdir`; make cleandir; make obj
829: (If you built the tree without "make obj" in the past, obsolete files
830: may remain. The command tries to clean everything up)
1.5 wiz 831:
832: Symptom:.../sysinst/run.c:xx: warning: initialization from incompatible pointer type
833: Fix: Rebuild and install usr.bin/menuc
1.12 itojun 834:
835: Symptom:mklocale not found during build in share/locale/ctype
836: Fix: Build and install usr.bin/mklocale
1.13 dogcow 837:
1.86 kleink 838: Symptom:undefined reference to `__assert13' or `__unsetenv13'
1.13 dogcow 839: Fix: Rebuild and install lib/libc
840:
1.19 cgd 841: Symptom:usr.sbin/config fails to build.
842: Fix: Try building with -DMAKE_BOOTSTRAP added to CFLAGS in Makefile.
1.13 dogcow 843:
1.19 cgd 844: Symptom:undefined reference to `getprogname' or `setprogname'
845: Fix: Rebuild and install lib/libc
1.24 abs 846:
847: Symptom:lint does not understand the '-X' option
848: Fix: May need to build & install libs with NOLINT=1 before rebuilding lint
CVSweb <webmaster@jp.NetBSD.org>