PERFORCE change 60549 for review
Peter Wemm
peter at FreeBSD.org
Fri Aug 27 15:55:33 PDT 2004
http://perforce.freebsd.org/chv.cgi?CH=60549
Change 60549 by peter at peter_daintree on 2004/08/27 22:55:04
IFC @60548
Affected files ...
.. //depot/projects/hammer/Makefile.inc1#58 integrate
.. //depot/projects/hammer/UPDATING#50 integrate
.. //depot/projects/hammer/contrib/gnu-sort/lib/version-etc.c#5 integrate
.. //depot/projects/hammer/etc/mtree/BSD.usr.dist#26 integrate
.. //depot/projects/hammer/etc/network.subr#6 integrate
.. //depot/projects/hammer/games/fortune/datfiles/freebsd-tips#9 integrate
.. //depot/projects/hammer/include/ftw.h#2 integrate
.. //depot/projects/hammer/lib/libarchive/archive_read_extract.c#17 integrate
.. //depot/projects/hammer/lib/libarchive/archive_string_sprintf.c#5 integrate
.. //depot/projects/hammer/lib/libc/db/man/mpool.3#3 integrate
.. //depot/projects/hammer/lib/libc/gen/Makefile.inc#18 integrate
.. //depot/projects/hammer/lib/libc/gen/ftw.c#3 integrate
.. //depot/projects/hammer/lib/libc/gen/nftw.c#1 branch
.. //depot/projects/hammer/lib/libc/ia64/gen/Makefile.inc#9 integrate
.. //depot/projects/hammer/lib/libc/ia64/gen/_mcount.S#1 branch
.. //depot/projects/hammer/lib/libc/stdio/setbuf.3#4 integrate
.. //depot/projects/hammer/lib/libc/stdio/vfprintf.c#16 integrate
.. //depot/projects/hammer/lib/libc/stdio/vfwprintf.c#15 integrate
.. //depot/projects/hammer/lib/libc/stdtime/localtime.c#7 integrate
.. //depot/projects/hammer/lib/libpthread/arch/amd64/include/pthread_md.h#8 integrate
.. //depot/projects/hammer/lib/libpthread/arch/i386/include/pthread_md.h#9 integrate
.. //depot/projects/hammer/lib/libz/infback.c#2 integrate
.. //depot/projects/hammer/lib/libz/inflate.c#3 integrate
.. //depot/projects/hammer/release/Makefile#54 integrate
.. //depot/projects/hammer/release/doc/en_US.ISO8859-1/hardware/common/dev.sgml#56 integrate
.. //depot/projects/hammer/release/doc/share/misc/dev.archlist.txt#5 integrate
.. //depot/projects/hammer/release/doc/share/misc/man2hwnotes.pl#3 integrate
.. //depot/projects/hammer/release/scripts/doFS.sh#16 integrate
.. //depot/projects/hammer/release/scripts/split-file.sh#2 integrate
.. //depot/projects/hammer/release/sparc64/mkisoimages.sh#8 integrate
.. //depot/projects/hammer/share/man/man4/Makefile#46 integrate
.. //depot/projects/hammer/share/man/man4/ath.4#15 integrate
.. //depot/projects/hammer/share/man/man4/ath_hal.4#9 integrate
.. //depot/projects/hammer/share/man/man4/axe.4#6 integrate
.. //depot/projects/hammer/share/man/man4/cue.4#6 integrate
.. //depot/projects/hammer/share/man/man4/dc.4#12 integrate
.. //depot/projects/hammer/share/man/man4/ipfirewall.4#5 integrate
.. //depot/projects/hammer/share/man/man4/kue.4#7 integrate
.. //depot/projects/hammer/share/man/man4/lge.4#4 integrate
.. //depot/projects/hammer/share/man/man4/man4.i386/vx.4#4 integrate
.. //depot/projects/hammer/share/man/man4/ng_hci.4#9 integrate
.. //depot/projects/hammer/share/man/man4/ng_vlan.4#2 integrate
.. //depot/projects/hammer/share/man/man4/rue.4#8 integrate
.. //depot/projects/hammer/share/man/man4/sf.4#3 integrate
.. //depot/projects/hammer/share/man/man4/sk.4#6 integrate
.. //depot/projects/hammer/share/man/man4/snd_ad1816.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_als4000.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_cmi.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_cs4281.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_ds1.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_emu10k1.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_es137x.4#1 branch
.. //depot/projects/hammer/share/man/man4/snd_solo.4#1 branch
.. //depot/projects/hammer/share/man/man4/tx.4#3 integrate
.. //depot/projects/hammer/share/man/man4/vr.4#6 integrate
.. //depot/projects/hammer/share/man/man9/altq.9#2 integrate
.. //depot/projects/hammer/share/man/man9/bus_dma.9#11 integrate
.. //depot/projects/hammer/share/man/man9/pfil.9#6 integrate
.. //depot/projects/hammer/share/misc/bsd-family-tree#18 integrate
.. //depot/projects/hammer/share/timedef/sl_SI.ISO8859-2.src#2 integrate
.. //depot/projects/hammer/share/timedef/sl_SI.UTF-8.src#2 integrate
.. //depot/projects/hammer/sys/alpha/alpha/pmap.c#36 integrate
.. //depot/projects/hammer/sys/alpha/conf/GENERIC#20 integrate
.. //depot/projects/hammer/sys/alpha/include/cpu.h#9 integrate
.. //depot/projects/hammer/sys/alpha/include/profile.h#3 integrate
.. //depot/projects/hammer/sys/alpha/linux/linux_proto.h#9 integrate
.. //depot/projects/hammer/sys/alpha/linux/linux_syscall.h#9 integrate
.. //depot/projects/hammer/sys/alpha/linux/linux_sysent.c#9 integrate
.. //depot/projects/hammer/sys/alpha/linux/syscalls.master#9 integrate
.. //depot/projects/hammer/sys/alpha/osf1/osf1_misc.c#10 integrate
.. //depot/projects/hammer/sys/alpha/osf1/osf1_proto.h#6 integrate
.. //depot/projects/hammer/sys/alpha/osf1/osf1_syscall.h#6 integrate
.. //depot/projects/hammer/sys/alpha/osf1/osf1_sysent.c#6 integrate
.. //depot/projects/hammer/sys/alpha/osf1/syscalls.master#6 integrate
.. //depot/projects/hammer/sys/amd64/amd64/machdep.c#100 integrate
.. //depot/projects/hammer/sys/amd64/amd64/nexus.c#29 integrate
.. //depot/projects/hammer/sys/amd64/amd64/pmap.c#102 integrate
.. //depot/projects/hammer/sys/amd64/conf/GENERIC#53 integrate
.. //depot/projects/hammer/sys/amd64/conf/NOTES#44 integrate
.. //depot/projects/hammer/sys/amd64/include/profile.h#21 integrate
.. //depot/projects/hammer/sys/amd64/linux32/linux32_machdep.c#2 integrate
.. //depot/projects/hammer/sys/arm/include/profile.h#4 integrate
.. //depot/projects/hammer/sys/boot/i386/boot0/Makefile#7 integrate
.. //depot/projects/hammer/sys/boot/i386/boot2/Makefile#8 integrate
.. //depot/projects/hammer/sys/compat/linux/linux_socket.c#14 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_fcntl.c#5 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_proto.h#4 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_stream.c#12 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_syscall.h#4 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_syscallnames.c#4 integrate
.. //depot/projects/hammer/sys/compat/svr4/svr4_sysent.c#4 integrate
.. //depot/projects/hammer/sys/compat/svr4/syscalls.master#4 integrate
.. //depot/projects/hammer/sys/conf/NOTES#61 integrate
.. //depot/projects/hammer/sys/conf/files#78 integrate
.. //depot/projects/hammer/sys/conf/ldscript.alpha#4 integrate
.. //depot/projects/hammer/sys/conf/ldscript.ia64#8 integrate
.. //depot/projects/hammer/sys/conf/options#54 integrate
.. //depot/projects/hammer/sys/contrib/ipfilter/netinet/ip_fil.c#11 integrate
.. //depot/projects/hammer/sys/contrib/ipfilter/netinet/ip_fil.h#5 integrate
.. //depot/projects/hammer/sys/dev/acpica/acpi_lid.c#11 integrate
.. //depot/projects/hammer/sys/dev/acpica/acpi_pci_link.c#18 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-all.c#33 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-all.h#19 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-chipset.c#41 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-disk.c#21 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-lowlevel.c#19 integrate
.. //depot/projects/hammer/sys/dev/ata/ata-queue.c#16 integrate
.. //depot/projects/hammer/sys/dev/ata/atapi-cd.c#22 integrate
.. //depot/projects/hammer/sys/dev/ctau/if_ct.c#11 integrate
.. //depot/projects/hammer/sys/dev/cx/if_cx.c#17 integrate
.. //depot/projects/hammer/sys/dev/fdc/fdc.c#14 integrate
.. //depot/projects/hammer/sys/dev/hfa/fore_receive.c#7 integrate
.. //depot/projects/hammer/sys/dev/idt/idt_harp.c#5 integrate
.. //depot/projects/hammer/sys/dev/mpt/mpt_freebsd.c#11 integrate
.. //depot/projects/hammer/sys/dev/ppbus/if_plip.c#10 integrate
.. //depot/projects/hammer/sys/dev/uart/uart_bus_isa.c#4 integrate
.. //depot/projects/hammer/sys/dev/usb/usbdevs#46 integrate
.. //depot/projects/hammer/sys/fs/msdosfs/msdosfs_vfsops.c#22 integrate
.. //depot/projects/hammer/sys/geom/concat/g_concat.c#10 integrate
.. //depot/projects/hammer/sys/geom/geom.h#28 integrate
.. //depot/projects/hammer/sys/geom/geom_io.c#25 integrate
.. //depot/projects/hammer/sys/geom/label/g_label.c#5 integrate
.. //depot/projects/hammer/sys/geom/mirror/g_mirror.c#4 integrate
.. //depot/projects/hammer/sys/geom/raid3/g_raid3.c#4 integrate
.. //depot/projects/hammer/sys/geom/stripe/g_stripe.c#5 integrate
.. //depot/projects/hammer/sys/geom/vinum/geom_vinum.c#7 integrate
.. //depot/projects/hammer/sys/geom/vinum/geom_vinum.h#3 integrate
.. //depot/projects/hammer/sys/geom/vinum/geom_vinum_drive.c#7 integrate
.. //depot/projects/hammer/sys/geom/vinum/geom_vinum_volume.c#5 integrate
.. //depot/projects/hammer/sys/i386/acpica/acpi_panasonic.c#3 integrate
.. //depot/projects/hammer/sys/i386/conf/GENERIC#27 integrate
.. //depot/projects/hammer/sys/i386/i386/pmap.c#50 integrate
.. //depot/projects/hammer/sys/i386/ibcs2/ibcs2_fcntl.c#5 integrate
.. //depot/projects/hammer/sys/i386/ibcs2/ibcs2_proto.h#5 integrate
.. //depot/projects/hammer/sys/i386/ibcs2/ibcs2_syscall.h#5 integrate
.. //depot/projects/hammer/sys/i386/ibcs2/ibcs2_sysent.c#7 integrate
.. //depot/projects/hammer/sys/i386/ibcs2/syscalls.master#5 integrate
.. //depot/projects/hammer/sys/i386/include/in_cksum.h#4 integrate
.. //depot/projects/hammer/sys/i386/include/profile.h#10 integrate
.. //depot/projects/hammer/sys/i386/linux/linux_machdep.c#12 integrate
.. //depot/projects/hammer/sys/i386/linux/linux_proto.h#11 integrate
.. //depot/projects/hammer/sys/i386/linux/linux_syscall.h#11 integrate
.. //depot/projects/hammer/sys/i386/linux/linux_sysent.c#12 integrate
.. //depot/projects/hammer/sys/i386/linux/syscalls.master#11 integrate
.. //depot/projects/hammer/sys/i4b/driver/i4b_ipr.c#10 integrate
.. //depot/projects/hammer/sys/ia64/conf/GENERIC#17 integrate
.. //depot/projects/hammer/sys/ia64/conf/NOTES#3 integrate
.. //depot/projects/hammer/sys/ia64/conf/SKI#12 integrate
.. //depot/projects/hammer/sys/ia64/ia64/nexus.c#4 integrate
.. //depot/projects/hammer/sys/ia64/ia64/pmap.c#34 integrate
.. //depot/projects/hammer/sys/ia64/ia64/support.S#4 integrate
.. //depot/projects/hammer/sys/ia64/include/asm.h#4 integrate
.. //depot/projects/hammer/sys/ia64/include/cpu.h#15 integrate
.. //depot/projects/hammer/sys/ia64/include/profile.h#3 integrate
.. //depot/projects/hammer/sys/isa/psm.c#22 integrate
.. //depot/projects/hammer/sys/kern/kern_kse.c#8 integrate
.. //depot/projects/hammer/sys/kern/kern_linker.c#19 integrate
.. //depot/projects/hammer/sys/kern/kern_lock.c#12 integrate
.. //depot/projects/hammer/sys/kern/subr_bus.c#25 integrate
.. //depot/projects/hammer/sys/kern/sys_generic.c#16 integrate
.. //depot/projects/hammer/sys/kern/uipc_socket.c#37 integrate
.. //depot/projects/hammer/sys/kern/uipc_usrreq.c#24 integrate
.. //depot/projects/hammer/sys/libkern/mcount.c#4 integrate
.. //depot/projects/hammer/sys/modules/bridge/Makefile#3 integrate
.. //depot/projects/hammer/sys/modules/ipfw/Makefile#4 integrate
.. //depot/projects/hammer/sys/net/bridge.c#17 integrate
.. //depot/projects/hammer/sys/net/if.c#25 integrate
.. //depot/projects/hammer/sys/net/if_fwsubr.c#5 integrate
.. //depot/projects/hammer/sys/net/if_loop.c#22 integrate
.. //depot/projects/hammer/sys/net/if_ppp.c#16 integrate
.. //depot/projects/hammer/sys/net/if_sl.c#18 integrate
.. //depot/projects/hammer/sys/net/if_spppsubr.c#16 integrate
.. //depot/projects/hammer/sys/net/netisr.c#7 integrate
.. //depot/projects/hammer/sys/net/rtsock.c#17 integrate
.. //depot/projects/hammer/sys/netgraph/atm/atmpif/ng_atmpif_harp.c#2 integrate
.. //depot/projects/hammer/sys/netinet/ip_dummynet.c#24 integrate
.. //depot/projects/hammer/sys/netinet/ip_fastfwd.c#11 integrate
.. //depot/projects/hammer/sys/netinet/ip_fw2.c#38 integrate
.. //depot/projects/hammer/sys/netinet/ip_fw_pfil.c#3 integrate
.. //depot/projects/hammer/sys/netinet/ip_input.c#38 integrate
.. //depot/projects/hammer/sys/netinet/ip_mroute.c#23 integrate
.. //depot/projects/hammer/sys/netinet/ip_output.c#37 integrate
.. //depot/projects/hammer/sys/netinet/ip_var.h#20 integrate
.. //depot/projects/hammer/sys/netinet6/ah_input.c#5 integrate
.. //depot/projects/hammer/sys/netinet6/esp_input.c#8 integrate
.. //depot/projects/hammer/sys/netinet6/ip6_forward.c#10 integrate
.. //depot/projects/hammer/sys/netinet6/ip6_input.c#17 integrate
.. //depot/projects/hammer/sys/netinet6/ip6_output.c#24 integrate
.. //depot/projects/hammer/sys/netinet6/ip6_var.h#10 integrate
.. //depot/projects/hammer/sys/netipsec/ipsec_input.c#7 integrate
.. //depot/projects/hammer/sys/netipsec/xform_ipip.c#7 integrate
.. //depot/projects/hammer/sys/netkey/key.c#16 integrate
.. //depot/projects/hammer/sys/netkey/keysock.c#10 integrate
.. //depot/projects/hammer/sys/nfsclient/nfs_socket.c#19 integrate
.. //depot/projects/hammer/sys/nfsserver/nfs_serv.c#15 integrate
.. //depot/projects/hammer/sys/pc98/conf/GENERIC#23 integrate
.. //depot/projects/hammer/sys/pci/if_dc.c#38 integrate
.. //depot/projects/hammer/sys/powerpc/conf/GENERIC#19 integrate
.. //depot/projects/hammer/sys/powerpc/include/pmap.h#9 integrate
.. //depot/projects/hammer/sys/powerpc/include/profile.h#3 integrate
.. //depot/projects/hammer/sys/powerpc/powerpc/pmap.c#28 integrate
.. //depot/projects/hammer/sys/sparc64/conf/GENERIC#27 integrate
.. //depot/projects/hammer/sys/sparc64/include/profile.h#3 integrate
.. //depot/projects/hammer/sys/sys/linker.h#14 integrate
.. //depot/projects/hammer/sys/sys/param.h#44 integrate
.. //depot/projects/hammer/tools/lib32/build32.sh#2 integrate
.. //depot/projects/hammer/tools/regression/sockets/accept_fd_leak/accept_fd_leak.c#2 integrate
.. //depot/projects/hammer/tools/regression/sockets/kqueue/Makefile#1 branch
.. //depot/projects/hammer/tools/regression/sockets/kqueue/kqueue.c#1 branch
.. //depot/projects/hammer/usr.bin/fetch/fetch.c#14 integrate
.. //depot/projects/hammer/usr.bin/join/join.1#6 integrate
.. //depot/projects/hammer/usr.bin/join/join.c#4 integrate
.. //depot/projects/hammer/usr.bin/sockstat/sockstat.1#3 integrate
.. //depot/projects/hammer/usr.bin/sockstat/sockstat.c#6 integrate
.. //depot/projects/hammer/usr.bin/tar/bsdtar.1#13 integrate
.. //depot/projects/hammer/usr.bin/tar/bsdtar.c#19 integrate
.. //depot/projects/hammer/usr.bin/tar/read.c#11 integrate
.. //depot/projects/hammer/usr.bin/whois/whois.c#9 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/Makefile#4 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/ef.c#3 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/ef.h#3 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/ef_amd64.c#1 branch
.. //depot/projects/hammer/usr.sbin/kldxref/ef_i386.c#1 branch
.. //depot/projects/hammer/usr.sbin/kldxref/ef_nop.c#2 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/ef_obj.c#1 branch
.. //depot/projects/hammer/usr.sbin/kldxref/ef_sparc64.c#2 integrate
.. //depot/projects/hammer/usr.sbin/kldxref/kldxref.c#6 integrate
.. //depot/projects/hammer/usr.sbin/sysinstall/dist.c#17 integrate
.. //depot/projects/hammer/usr.sbin/sysinstall/dist.h#7 integrate
.. //depot/projects/hammer/usr.sbin/sysinstall/menus.c#26 integrate
Differences ...
==== //depot/projects/hammer/Makefile.inc1#58 (text+ko) ====
@@ -1,5 +1,5 @@
#
-# $FreeBSD: src/Makefile.inc1,v 1.440 2004/08/18 13:21:40 ru Exp $
+# $FreeBSD: src/Makefile.inc1,v 1.443 2004/08/26 10:24:25 paul Exp $
#
# Make command line options:
# -DNO_DYNAMICROOT do not link /bin and /sbin dynamically
@@ -83,6 +83,7 @@
.endif
CVS?= cvs
+CVSFLAGS?= -A -P -d
SUP?= /usr/local/bin/cvsup
SUPFLAGS?= -g -L 2 -P -
.if defined(SUPHOST)
@@ -173,13 +174,13 @@
GROFF_TMAC_PATH=${WORLDTMP}/legacy/usr/share/tmac
# bootstrap-tools stage
-BMAKEENV= DESTDIR= \
- INSTALL="sh ${.CURDIR}/tools/install.sh" \
+BMAKEENV= INSTALL="sh ${.CURDIR}/tools/install.sh" \
PATH=${BPATH}:${PATH} \
WORLDTMP=${WORLDTMP} \
MAKEFLAGS="-m ${.CURDIR}/tools/build/mk ${.MAKEFLAGS}"
BMAKE= MAKEOBJDIRPREFIX=${WORLDTMP} \
${BMAKEENV} ${MAKE} -f Makefile.inc1 \
+ DESTDIR= \
BOOTSTRAPPING=${OSRELDATE} \
-DNOHTML -DNOINFO -DNOLINT -DNOMAN -DNOPIC -DNOPROFILE \
-DNOSHARED -DNO_CPU_CFLAGS -DNO_WARNS
@@ -187,6 +188,7 @@
# build-tools stage
TMAKE= MAKEOBJDIRPREFIX=${OBJTREE} \
${BMAKEENV} ${MAKE} -f Makefile.inc1 \
+ DESTDIR= \
BOOTSTRAPPING=${OSRELDATE} -DNOLINT -DNO_CPU_CFLAGS -DNO_WARNS
# cross-tools stage
@@ -194,11 +196,10 @@
# world stage
WMAKEENV= ${CROSSENV} \
- DESTDIR=${WORLDTMP} \
_SHLIBDIRPREFIX=${WORLDTMP} \
INSTALL="sh ${.CURDIR}/tools/install.sh" \
PATH=${TMPPATH}
-WMAKE= ${WMAKEENV} ${MAKE} -f Makefile.inc1
+WMAKE= ${WMAKEENV} ${MAKE} -f Makefile.inc1 DESTDIR=${WORLDTMP}
# install stage
.if empty(.MAKEFLAGS:M-n)
@@ -655,7 +656,7 @@
@echo "--------------------------------------------------------------"
@echo ">>> Updating ${.CURDIR} from cvs repository" ${CVSROOT}
@echo "--------------------------------------------------------------"
- cd ${.CURDIR}; ${CVS} -R -q update -A -P -d
+ cd ${.CURDIR}; ${CVS} -R -q update ${CVSFLAGS}
.endif
#
==== //depot/projects/hammer/UPDATING#50 (text+ko) ====
@@ -23,6 +23,10 @@
developers choose to disable these features on build machines
to maximize performance.
+20040827:
+ PFIL_HOOKS are a fixed part of the network stack now and do not
+ need to be specified in the kernel configuration file anymore.
+
20040819:
Netgraph changed its message format slightly to align the data
portion well on 64 bit machines.
@@ -1625,11 +1629,10 @@
<make sure you have good level 0 dumps>
<maybe fix /etc/fstab> [7]
make buildworld
- make buildkernel KERNCONF=YOUR_KERNEL_HERE
- make installkernel KERNCONF=YOUR_KERNEL_HERE
+ make kernel KERNCONF=YOUR_KERNEL_HERE
[1]
<reboot in single user> [3]
- /etc/rc.d/preseedrandom [10]
+ src/etc/rc.d/preseedrandom [10]
mergemaster -p [5]
make installworld
mergemaster [4]
@@ -1650,15 +1653,15 @@
<mount current's root partition on directory ${CURRENT_ROOT}>
make installworld DESTDIR=${CURRENT_ROOT}
make buildkernel KERNCONF=YOUR_KERNEL_HERE
- cp /usr/src/sys/${ARCH}/conf/GENERIC.hints \
+ cp src/sys/${ARCH}/conf/GENERIC.hints \
${CURRENT_ROOT}/boot/device.hints # as needed
make installkernel KERNCONF=YOUR_KERNEL_HERE DESTDIR=${CURRENT_ROOT}
- cd /usr/src/etc; make distribution DESTDIR=${CURRENT_ROOT} # if newfs'd
+ cd src/etc; make distribution DESTDIR=${CURRENT_ROOT} # if newfs'd
cp /etc/fstab ${CURRENT_ROOT}/etc/fstab # if newfs'd
<edit ${CURRENT_ROOT}/etc/fstab to mount "/" from the correct partition>
<reboot into current>
<do a "native" rebuild/install as described in the previous section>
- <maybe install compatibility libraries from /usr/src/lib/compat>
+ <maybe install compatibility libraries from src/lib/compat>
<reboot>
@@ -1679,10 +1682,10 @@
make buildkernel KERNCONF=YOUR_KERNEL_HERE [8]
cp sys/${MACHINE}/conf/GENERIC.hints /boot/device.hints [2]
make installkernel KERNCONF=YOUR_KERNEL_HERE
- cd sys/boot ; make STRIP="" install [6]
+ cd sys/boot ; make STRIP="" install [6]
[1]
<reboot in single user> [3]
- /usr/src/etc/rc.d/preseedrandom [10]
+ src/etc/rc.d/preseedrandom [10]
mergemaster -p [5]
rm -rf /usr/include/g++
make installworld
@@ -1713,7 +1716,7 @@
fsck -p
mount -u /
mount -a
- cd /usr/src
+ cd src
adjkerntz -i # if CMOS is wall time
Also, when doing a major release upgrade, it is required that
you boot into single user mode to do the installworld.
@@ -1765,7 +1768,7 @@
using your existing software for a while.
[10] In order to create temporary files, /dev/random must be
- initialized by feeding data into it. /usr/src/etc/rc.d/preseedrandom
+ initialized by feeding data into it. src/etc/rc.d/preseedrandom
takes care of this.
FORMAT:
@@ -1800,4 +1803,4 @@
Contact Warner Losh if you have any questions about your use of
this document.
-$FreeBSD: src/UPDATING,v 1.348 2004/08/23 18:51:36 imp Exp $
+$FreeBSD: src/UPDATING,v 1.350 2004/08/27 15:16:24 andre Exp $
==== //depot/projects/hammer/contrib/gnu-sort/lib/version-etc.c#5 (text+ko) ====
@@ -15,7 +15,7 @@
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-/* $FreeBSD: src/contrib/gnu-sort/lib/version-etc.c,v 1.3 2004/08/12 05:46:04 tjr Exp $ */
+/* $FreeBSD: src/contrib/gnu-sort/lib/version-etc.c,v 1.4 2004/08/27 03:52:29 kientzle Exp $ */
/* Written by Jim Meyering. */
@@ -63,6 +63,9 @@
n_authors = 0;
while (va_arg (tmp_authors, const char *) != NULL)
++n_authors;
+#ifdef va_copy
+ va_end (tmp_authors);
+#endif
}
if (command_name)
==== //depot/projects/hammer/etc/mtree/BSD.usr.dist#26 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.304 2004/08/16 09:31:09 dwmalone Exp $
+# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.305 2004/08/24 19:03:55 ru Exp $
#
# Please see the file src/etc/mtree/README before making changes to this file.
#
@@ -289,8 +289,6 @@
..
tcsh
..
- worm
- ..
..
games
fortune
==== //depot/projects/hammer/etc/network.subr#6 (text+ko) ====
@@ -22,7 +22,7 @@
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
-# $FreeBSD: src/etc/network.subr,v 1.154 2004/06/06 11:46:27 schweikh Exp $
+# $FreeBSD: src/etc/network.subr,v 1.155 2004/08/27 12:11:47 yar Exp $
#
#
@@ -284,7 +284,7 @@
# Separate out dhcp and non-dhcp intefraces
#
_aprefix=
- _brefix=
+ _bprefix=
for _if in ${_tmplist} ; do
eval _ifarg="\$ifconfig_${_if}"
case "$_ifarg" in
==== //depot/projects/hammer/games/fortune/datfiles/freebsd-tips#9 (text+ko) ====
@@ -1,5 +1,5 @@
This fortune brought to you by:
-$FreeBSD: src/games/fortune/datfiles/freebsd-tips,v 1.33 2004/02/18 05:18:27 cperciva Exp $
+$FreeBSD: src/games/fortune/datfiles/freebsd-tips,v 1.34 2004/08/24 11:30:28 blackend Exp $
%
Having trouble using fetch through a firewall? Try setting the environment
variable FTP_PASSIVE_MODE to yes, and see fetch(3) for more details.
@@ -306,9 +306,9 @@
Want to find a specific port, just type the following under /usr/ports,
or one its subdirectories:
- "make search port=<port-name>"
+ "make search name=<port-name>"
or
- "make search key="<keyword>"
+ "make search key=<keyword>"
%
Want to see how much virtual memory you're using? Just type "swapinfo" to
be shown information about the usage of your swap partitions.
==== //depot/projects/hammer/include/ftw.h#2 (text+ko) ====
@@ -1,107 +1,62 @@
+/* $OpenBSD: ftw.h,v 1.1 2003/07/21 21:13:18 millert Exp $ */
+
/*
- * Copyright (c) 2003 by Joel Baker.
- * All rights reserved.
+ * Copyright (c) 2003 Todd C. Miller <Todd.Miller at courtesan.com>
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. Neither the name of the Author nor the names of any contributors
- * may be used to endorse or promote products derived from this software
- * without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
+ * Sponsored in part by the Defense Advanced Research Projects
+ * Agency (DARPA) and Air Force Research Laboratory, Air Force
+ * Materiel Command, USAF, under agreement number F39502-99-1-0512.
*
- * $FreeBSD: src/include/ftw.h,v 1.1 2004/07/05 23:13:16 das Exp $
+ * $FreeBSD: src/include/ftw.h,v 1.2 2004/08/24 13:00:54 tjr Exp $
*/
-#ifndef _FTW_H
-#define _FTW_H
+#ifndef _FTW_H
+#define _FTW_H
+#include <sys/types.h>
#include <sys/stat.h>
-__BEGIN_DECLS
+/*
+ * Valid flags for the 3rd argument to the function that is passed as the
+ * second argument to ftw(3) and nftw(3). Say it three times fast!
+ */
+#define FTW_F 0 /* File. */
+#define FTW_D 1 /* Directory. */
+#define FTW_DNR 2 /* Directory without read permission. */
+#define FTW_DP 3 /* Directory with subdirectories visited. */
+#define FTW_NS 4 /* Unknown type; stat() failed. */
+#define FTW_SL 5 /* Symbolic link. */
+#define FTW_SLN 6 /* Sym link that names a nonexistent file. */
-/* Enumerated values for 'flag' when calling [n]ftw */
+/*
+ * Flags for use as the 4th argument to nftw(3). These may be ORed together.
+ */
+#define FTW_PHYS 0x01 /* Physical walk, don't follow sym links. */
+#define FTW_MOUNT 0x02 /* The walk does not cross a mount point. */
+#define FTW_DEPTH 0x04 /* Subdirs visited before the dir itself. */
+#define FTW_CHDIR 0x08 /* Change to a directory before reading it. */
-enum {
- FTW_D, /* Directories */
- FTW_DNR, /* Unreadable directory */
- FTW_F, /* Regular files */
- FTW_SL, /* Symbolic link */
- FTW_NS, /* stat(2) failed */
-
-#if __XSI_VISIBLE /* X/Open */
-
-/* Flags for nftw only */
-
- FTW_DP, /* Directory, subdirs visited */
- FTW_SLN, /* Dangling symlink */
-
-#endif /* __XSI_VISIBLE */
-};
-
-#if __XSI_VISIBLE /* X/Open */
-
-/* Enumerated values for 'flags' when calling nftw */
-
-enum {
- FTW_CHDIR = 1, /* Do a chdir(2) when entering a directory */
- FTW_DEPTH = 2, /* Report files first (before directory) */
- FTW_MOUNT = 4, /* Single filesystem */
- FTW_PHYS = 8 /* Physical walk; ignore symlinks */
-};
-
-#define FTW_PHYS FTW_PHYS
-#define FTW_MOUNT FTW_MOUNT
-#define FTW_CHDIR FTW_CHDIR
-#define FTW_DEPTH FTW_DEPTH
-
-/* FTW struct for callbacks from nftw */
-
struct FTW {
- int base;
- int level;
+ int base;
+ int level;
};
-#endif /* __XSI_VISIBLE */
-
-/* Typecasts for callback functions */
-
-typedef int (*__ftw_func_t) \
- (const char *file, const struct stat *status, int flag);
-
-/* ftw: walk a directory tree, calling a function for each element */
-
-extern int ftw (const char *dir, __ftw_func_t func, int descr);
-
-#if __XSI_VISIBLE /* X/Open */
-
-typedef int (*__nftw_func_t) \
- (const char *file, const struct stat *status, int flag, struct FTW *detail);
-
-/* nftw: walk a directory tree, calling a function for each element; much
- * like ftw, but with behavior flags and minty freshness.
- */
-
-extern int nftw (const char *dir, __nftw_func_t func, int descr, int flags);
-
-#endif /* __XSI_VISIBLE */
-
+__BEGIN_DECLS
+int ftw(const char *, int (*)(const char *, const struct stat *, int), int);
+int nftw(const char *, int (*)(const char *, const struct stat *, int,
+ struct FTW *), int, int);
__END_DECLS
-#endif /* _FTW_H */
+#endif /* !_FTW_H */
==== //depot/projects/hammer/lib/libarchive/archive_read_extract.c#17 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include "archive_platform.h"
-__FBSDID("$FreeBSD: src/lib/libarchive/archive_read_extract.c,v 1.33 2004/08/07 03:09:28 kientzle Exp $");
+__FBSDID("$FreeBSD: src/lib/libarchive/archive_read_extract.c,v 1.35 2004/08/27 03:40:48 kientzle Exp $");
#include <sys/types.h>
#ifdef HAVE_SYS_ACL_H
@@ -74,6 +74,12 @@
#define FIXUP_TIMES 2
#define FIXUP_FFLAGS 4
+struct bucket {
+ char *name;
+ int hash;
+ id_t id;
+};
+
struct extract {
mode_t umask;
mode_t default_dir_mode;
@@ -81,6 +87,9 @@
struct fixup_entry *fixup_list;
struct fixup_entry *current_fixup;
+ struct bucket ucache[127];
+ struct bucket gcache[127];
+
/*
* Cached stat data from disk for the current entry.
* If this is valid, pst points to st. Otherwise,
@@ -113,6 +122,7 @@
static int extract_file(struct archive *, struct archive_entry *, int);
static int extract_hard_link(struct archive *, struct archive_entry *, int);
static int extract_symlink(struct archive *, struct archive_entry *, int);
+static unsigned int hash(const char *);
static gid_t lookup_gid(struct archive *, const char *uname, gid_t);
static uid_t lookup_uid(struct archive *, const char *uname, uid_t);
static int create_parent_dir(struct archive *, const char *, int flags);
@@ -479,7 +489,7 @@
if (extract->pst != NULL) {
extract->pst = &extract->st;
if (S_ISDIR(extract->pst->st_mode))
- goto success;
+ return (ARCHIVE_OK);
/* It exists but isn't a dir. */
if ((flags & ARCHIVE_EXTRACT_UNLINK))
unlink(path);
@@ -1193,23 +1203,44 @@
#endif
/*
- * XXX The following gid/uid lookups can be a performance bottleneck.
- * Some form of caching would probably be very effective, though
- * I have concerns about staleness.
+ * The following routines do some basic caching of uname/gname lookups.
+ * All such lookups go through these routines, including ACL conversions.
+ *
+ * TODO: Provide an API for clients to override these routines.
*/
static gid_t
lookup_gid(struct archive *a, const char *gname, gid_t gid)
{
struct group *grent;
+ struct extract *extract;
+ int h;
+ struct bucket *b;
+ int cache_size;
- (void)a; /* UNUSED */
+ extract = a->extract;
+ cache_size = sizeof(extract->gcache) / sizeof(extract->gcache[0]);
+
+ /* If no gname, just use the gid provided. */
+ if (gname == NULL || *gname == '\0')
+ return (gid);
+
+ /* Try to find gname in the cache. */
+ h = hash(gname);
+ b = &extract->gcache[h % cache_size ];
+ if (b->name != NULL && b->hash == h && strcmp(gname, b->name) == 0)
+ return ((gid_t)b->id);
+
+ /* Free the cache slot for a new entry. */
+ if (b->name != NULL)
+ free(b->name);
+ b->name = strdup(gname);
+ /* Note: If strdup fails, that's okay; we just won't cache. */
+ b->hash = h;
+ grent = getgrnam(gname);
+ if (grent != NULL)
+ gid = grent->gr_gid;
+ b->id = gid;
- /* Look up gid from gname. */
- if (gname != NULL && *gname != '\0') {
- grent = getgrnam(gname);
- if (grent != NULL)
- gid = grent->gr_gid;
- }
return (gid);
}
@@ -1217,18 +1248,54 @@
lookup_uid(struct archive *a, const char *uname, uid_t uid)
{
struct passwd *pwent;
+ struct extract *extract;
+ int h;
+ struct bucket *b;
+ int cache_size;
+
+ extract = a->extract;
+ cache_size = sizeof(extract->ucache) / sizeof(extract->ucache[0]);
+
+ /* If no uname, just use the uid provided. */
+ if (uname == NULL || *uname == '\0')
+ return (uid);
- (void)a; /* UNUSED */
+ /* Try to find uname in the cache. */
+ h = hash(uname);
+ b = &extract->ucache[h % cache_size ];
+ if (b->name != NULL && b->hash == h && strcmp(uname, b->name) == 0)
+ return ((uid_t)b->id);
+
+ /* Free the cache slot for a new entry. */
+ if (b->name != NULL)
+ free(b->name);
+ b->name = strdup(uname);
+ /* Note: If strdup fails, that's okay; we just won't cache. */
+ b->hash = h;
+ pwent = getpwnam(uname);
+ if (pwent != NULL)
+ uid = pwent->pw_uid;
+ b->id = uid;
- /* Look up uid from uname. */
- if (uname != NULL && *uname != '\0') {
- pwent = getpwnam(uname);
- if (pwent != NULL)
- uid = pwent->pw_uid;
- }
return (uid);
}
+static unsigned int
+hash(const char *p)
+{
+ /* A 32-bit version of Peter Weinberger's (PJW) hash algorithm,
+ as used by ELF for hashing function names. */
+ unsigned g,h = 0;
+ while(*p != '\0') {
+ h = ( h << 4 ) + *p++;
+ if (( g = h & 0xF0000000 )) {
+ h ^= g >> 24;
+ h &= 0x0FFFFFFF;
+ }
+ }
+ return h;
+}
+
void
archive_read_extract_set_progress_callback(struct archive *a,
void (*progress_func)(void *), void *user_data)
==== //depot/projects/hammer/lib/libarchive/archive_string_sprintf.c#5 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include "archive_platform.h"
-__FBSDID("$FreeBSD: src/lib/libarchive/archive_string_sprintf.c,v 1.4 2004/08/14 03:45:45 kientzle Exp $");
+__FBSDID("$FreeBSD: src/lib/libarchive/archive_string_sprintf.c,v 1.5 2004/08/26 03:33:53 kientzle Exp $");
/*
* This uses 'printf' family functions, which can cause issues
@@ -47,19 +47,22 @@
va_list ap)
{
size_t l;
+ va_list ap1;
if (fmt == NULL) {
as->s[0] = 0;
return;
}
+ va_copy(ap1, ap);
l = vsnprintf(as->s, as->buffer_length, fmt, ap);
/* If output is bigger than the buffer, resize and try again. */
if (l+1 >= as->buffer_length) {
__archive_string_ensure(as, l + 1);
- l = vsnprintf(as->s, as->buffer_length, fmt, ap);
+ l = vsnprintf(as->s, as->buffer_length, fmt, ap1);
}
as->length = l;
+ va_end(ap1);
}
/*
==== //depot/projects/hammer/lib/libc/db/man/mpool.3#3 (text+ko) ====
@@ -30,7 +30,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)mpool.3 8.1 (Berkeley) 6/4/93
-.\" $FreeBSD: src/lib/libc/db/man/mpool.3,v 1.12 2003/02/06 11:04:46 charnier Exp $
+.\" $FreeBSD: src/lib/libc/db/man/mpool.3,v 1.13 2004/08/27 14:51:21 roam Exp $
.\"
.Dd June 4, 1993
.Dt MPOOL 3
@@ -65,32 +65,16 @@
.Nm mpool
library interface is intended to provide page oriented buffer management
of files.
-The buffers may be shared between processes.
.Pp
The
.Fn mpool_open
function initializes a memory pool.
The
.Fa key
-argument is the byte string used to negotiate between multiple
-processes wishing to share buffers.
-If the file buffers are mapped in shared memory, all processes using
-the same key will share the buffers.
-If
-.Fa key
-is
-.Dv NULL ,
-the buffers are mapped into private memory.
+argument is currently ignored.
The
.Fa fd
argument is a file descriptor for the underlying file, which must be seekable.
-If
-.Fa key
-is
-.No non\- Ns Dv NULL
-and matches a file already being mapped, the
-.Fa fd
-argument is ignored.
.Pp
The
.Fa pagesize
==== //depot/projects/hammer/lib/libc/gen/Makefile.inc#18 (text+ko) ====
@@ -1,5 +1,5 @@
# @(#)Makefile.inc 8.6 (Berkeley) 5/4/95
-# $FreeBSD: src/lib/libc/gen/Makefile.inc,v 1.116 2004/08/03 08:54:01 dfr Exp $
+# $FreeBSD: src/lib/libc/gen/Makefile.inc,v 1.117 2004/08/24 13:00:55 tjr Exp $
# machine-independent gen sources
.PATH: ${.CURDIR}/${MACHINE_ARCH}/gen ${.CURDIR}/gen
@@ -18,7 +18,7 @@
getpeereid.c getprogname.c getpwent.c getttyent.c \
getusershell.c getvfsbyname.c glob.c \
initgroups.c isatty.c isinf.c isnan.c jrand48.c lcong48.c \
- lockf.c lrand48.c mrand48.c nice.c \
+ lockf.c lrand48.c mrand48.c nftw.c nice.c \
nlist.c nrand48.c ntp_gettime.c opendir.c \
pause.c pmadvise.c popen.c posixshm.c pselect.c \
psignal.c pw_scan.c pwcache.c \
==== //depot/projects/hammer/lib/libc/gen/ftw.c#3 (text+ko) ====
@@ -1,200 +1,98 @@
+/* $OpenBSD: ftw.c,v 1.4 2004/07/07 16:05:23 millert Exp $ */
+
/*
- * Copyright (c) 2003 by Joel Baker.
- * All rights reserved.
+ * Copyright (c) 2003, 2004 Todd C. Miller <Todd.Miller at courtesan.com>
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
*
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. Neither the name of the Author nor the names of any contributors
- * may be used to endorse or promote products derived from this software
- * without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $FreeBSD: src/lib/libc/gen/ftw.c,v 1.3 2004/08/02 08:18:43 stefanf Exp $
+ * Sponsored in part by the Defense Advanced Research Projects
+ * Agency (DARPA) and Air Force Research Laboratory, Air Force
+ * Materiel Command, USAF, under agreement number F39502-99-1-0512.
*/
-#include <sys/types.h> /* Because fts(3) says so */
+#if 0
+#if defined(LIBC_SCCS) && !defined(lint)
+static const char rcsid[] = "$OpenBSD: ftw.c,v 1.4 2004/07/07 16:05:23 millert Exp $";
+#endif /* LIBC_SCCS and not lint */
+#endif
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD: src/lib/libc/gen/ftw.c,v 1.4 2004/08/24 13:00:55 tjr Exp $");
+
+#include <sys/types.h>
#include <sys/stat.h>
+#include <errno.h>
#include <fts.h>
+#include <ftw.h>
+#include <limits.h>
-#include <unistd.h> /* We want strcpy */
+int
+ftw(const char *path, int (*fn)(const char *, const struct stat *, int),
+ int nfds)
+{
+ char * const paths[2] = { (char *)path, NULL };
+ FTSENT *cur;
+ FTS *ftsp;
+ int error = 0, fnflag, sverrno;
-#include <errno.h> /* Because errno is our friend */
+ /* XXX - nfds is currently unused */
+ if (nfds < 1 || nfds > OPEN_MAX) {
+ errno = EINVAL;
+ return (-1);
+ }
-#include "ftw.h"
-
-/* I like symbolic values - this is only used in this file. */
-
-enum __ftw_modes {
- MODE_FTW,
- MODE_NFTW
-};
-
-/* Prototype this so that we can have it later */
-
-static int __ftw_core(const char *, void (*)(), int, int, enum __ftw_modes);
-
-/*
- * The external function calls are really just wrappers around __ftw_core,
- * since the work they do is 90% the same.
- */
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list