Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 25 Nov 2001 17:10:02 -0800 (PST)
From:      Jeremy Norris <ishmael27@home.com>
To:        freebsd-ports@FreeBSD.org
Subject:   Re: ports/32231: Update port devel/fam
Message-ID:  <200111260110.fAQ1A2f66458@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/32231; it has been noted by GNATS.

From: Jeremy Norris <ishmael27@home.com>
To: petef@FreeBSD.org
Cc: FreeBSD-gnats-submit@FreeBSD.org
Subject: Re: ports/32231: Update port devel/fam
Date: Sun, 25 Nov 2001 19:03:54 -0600

 I have sent these patches to the official FAM mailing list <fam@oss.sgi.com>. I
 have also created a bug in SGI's OSS bugzilla (http://oss.sgi.com/bugzilla),
 tracker ID 92. As mentioned in the PR's body, most of these patches already
 exist in files/patch-freebsd; I have merely broken them apart, 1 file patched
 per individual patchfile. This update also does make some more changes
 (changing some wording in manpages, default installation directory, etc.) so
 that they better integrate into FreeBSD.
 
 Finally, please use this diff instead of the original in the PR. It changes
 installation dir to ${LOCALBASE}/sbin, removes files/fam.sh.sample, and updates
 pkg-message to give better instructions on how to start FAM. Don't forget to
 cvs rm files/fam.sh.sample and files/patch-freebsd. Also, the repo-copy request
 still stands (move from devel to sysutils).
 
 Jeremy
 
 
 Index: Makefile
 ===================================================================
 RCS file: /home/ncvs/ports/devel/fam/Makefile,v
 retrieving revision 1.1
 diff -u -r1.1 Makefile
 --- Makefile	31 Mar 2001 02:45:55 -0000	1.1
 +++ Makefile	26 Nov 2001 00:39:17 -0000
 @@ -6,24 +6,67 @@
  #
  
  PORTNAME=	fam
 -PORTVERSION=	2.6.4
 -CATEGORIES=	devel
 +PORTVERSION=	2.6.6
 +CATEGORIES=	sysutils
  MASTER_SITES=	ftp://oss.sgi.com/projects/fam/download/
 -DISTNAME=	${PORTNAME}-oss-${PORTVERSION}
  
  MAINTAINER=	ishmael27@home.com
  
  USE_AUTOMAKE=	yes
 +AUTOMAKE_ARGS=	--add-missing --copy --foreign --include-deps
  USE_LIBTOOL=	yes
 -USE_GMAKE=	yes
 -PATCH_STRIP=	-p1
 +EXTRACT_AFTER_ARGS=	| ${TAR} -xf - -C ${WRKSRC}
 +PKGMESSAGE=	${WRKDIR}/pkg-message
  INSTALLS_SHLIB=	yes
  
 -MAN1=		fam.1m
 -MAN3=		fam.3x
 +MAN3=		fam.3
 +MAN8=		fam.8
 +
 +.if exists(/usr/sbin/rpcbind)
 +PORTMAP=	rpcbind
 +.else
 +PORTMAP=	portmap
 +.endif
 +
 +do-extract:
 +	@${RM} -rf ${WRKDIR}
 +	@${MKDIR} ${WRKSRC}
 +	@for file in ${EXTRACT_ONLY}; do \
 +		if ! (cd ${WRKDIR} && ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${_DISTDIR}/$$file ${EXTRACT_AFTER_ARGS});\
 +		then \
 +			exit 1; \
 +		fi \
 +	done
 +.if !defined(EXTRACT_PRESERVE_OWNERSHIP)
 +	@if [ `id -u` = 0 ]; then \
 +		${CHMOD} -R ug-s ${WRKDIR}; \
 +		${CHOWN} -R 0:0 ${WRKDIR}; \
 +	fi
 +.endif
 +
 +pre-configure:
 +	@${MV} ${WRKSRC}/man/fam.1m.in ${WRKSRC}/man/fam.8.in
 +	@${MV} ${WRKSRC}/man/fam.3x ${WRKSRC}/man/fam.3
 +	@${RM} -f ${WRKSRC}/install-sh ${WRKSRC}/missing \
 +		${WRKSRC}/mkinstalldirs
 +	@cd ${WRKSRC} && ${LOCALBASE}/bin/libtoolize --force --copy && \
 +		${ACLOCAL} && ${AUTOHEADER}
 +
 +post-configure:
 +	@${FIND} ${WRKSRC} -name "Makefile" |xargs ${PERL} -pi -e  '\
 +		s|^ACLOCAL =.*|ACLOCAL = ${ACLOCAL}| ; \
 +		s|^AUTOCONF =.*|AUTOCONF = ${AUTOCONF}| ; \
 +		s|^AUTOMAKE =.*|AUTOMAKE = ${AUTOMAKE}| ; \
 +		s|^AUTOHEADER =.*|AUTOHEADER = ${AUTOHEADER}|'
 +	@${PERL} -pi -e 's|%%PORTMAP%%|${PORTMAP}|g' ${WRKSRC}/man/fam.8
 +	@${MV} ${WRKSRC}/fam/fam.conf ${WRKSRC}/fam/fam.conf.sample
 +	@${SED} -e 's|%%PORTMAP%%|${PORTMAP}|g' -e 's|%%PREFIX%%|${PREFIX}|g' \
 +		${PKGDIR}/pkg-message >${PKGMESSAGE}
  
  post-install:
 -	@${INSTALL_SCRIPT} -m 751 ${FILESDIR}/fam.sh.sample ${PREFIX}/etc/rc.d/fam.sh.sample
 +	@if [ ! -f ${PREFIX}/etc/fam.conf ]; then \
 +		${CP} -p ${PREFIX}/etc/fam.conf.sample ${PREFIX}/etc/fam.conf; \
 +	fi
  	@${CAT} ${PKGMESSAGE}
  
  .include <bsd.port.mk>
 Index: distinfo
 ===================================================================
 RCS file: /home/ncvs/ports/devel/fam/distinfo,v
 retrieving revision 1.1
 diff -u -r1.1 distinfo
 --- distinfo	31 Mar 2001 02:45:55 -0000	1.1
 +++ distinfo	23 Nov 2001 14:53:49 -0000
 @@ -1 +1 @@
 -MD5 (fam-oss-2.6.4.tar.gz) = d060919b3d9ede61a8b68eae1ded53ce
 +MD5 (fam-2.6.6.tar.gz) = c1ecf4136b673e49fd0ea7a2e50d9885
 Index: pkg-message
 ===================================================================
 RCS file: /home/ncvs/ports/devel/fam/pkg-message,v
 retrieving revision 1.1
 diff -u -r1.1 pkg-message
 --- pkg-message	31 Mar 2001 02:45:55 -0000	1.1
 +++ pkg-message	25 Nov 2001 23:13:59 -0000
 @@ -1,8 +1,17 @@
 -************************************************************************
  
 -In order to run this port, please add the following line to /etc/rpc if
 -it is not already there:
 +To run FAM, please check and perform the following:
  
 +1. Be sure that the following line is in /etc/rpc
  sgi_fam		391002
  
 -************************************************************************
 +2. Be sure that %%PORTMAP%%(8) is running.
 +You probably will want to add the following line to /etc/rc.conf
 +portmap_enable="YES"
 +
 +3. Be sure that the following line is in /etc/inetd.conf
 +sgi_fam/1-2	stream rpc/tcp wait root	%%PREFIX%%/sbin/fam	fam
 +
 +4. Be sure that inetd(8) is running.
 +You probably will want to add the following line to /etc/rc.conf
 +inetd_enable="YES"
 +
 Index: pkg-plist
 ===================================================================
 RCS file: /home/ncvs/ports/devel/fam/pkg-plist,v
 retrieving revision 1.2
 diff -u -r1.2 pkg-plist
 --- pkg-plist	21 May 2001 07:13:05 -0000	1.2
 +++ pkg-plist	26 Nov 2001 00:20:53 -0000
 @@ -1,9 +1,9 @@
 -bin/fam
 -etc/fam.conf
 -etc/rc.d/fam.sh.sample
 +@comment $FreeBSD$
 +@unexec if cmp -s %D/etc/fam.conf %D/etc/fam.conf.sample; then rm -f %D/etc/fam.conf; fi
 +etc/fam.conf.sample
 +@exec if [ ! -f %D/etc/fam.conf ]; then cp -p %D/%F %B/fam.conf; fi
  include/fam.h
 -lib/fam/editconf.perl
  lib/libfam.a
  lib/libfam.so
  lib/libfam.so.0
 -@dirrm lib/fam
 +sbin/fam
 Index: files/fam.sh.sample
 ===================================================================
 RCS file: files/fam.sh.sample
 diff -N files/fam.sh.sample
 --- files/fam.sh.sample	31 Mar 2001 02:45:55 -0000	1.1
 +++ /dev/null	1 Jan 1970 00:00:00 -0000
 @@ -1,20 +0,0 @@
 -#!/bin/sh
 -
 -if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then
 -    echo "$0: Cannot determine the PREFIX" >&2
 -    exit 1
 -fi
 -
 -case "$1" in
 -start)
 -	[ -x ${PREFIX}/bin/fam ] && ( ${PREFIX}/bin/fam & ) && echo -n ' fam'
 -	;;
 -stop)
 -	killall fam && echo -n ' fam'
 -	;;
 -*)
 -	echo "Usage: `basename $0` {start|stop}" >&2
 -	;;
 -esac
 -
 -exit 0
 Index: files/patch-Makefile.am
 ===================================================================
 RCS file: /home/ncvs/ports/devel/fam/files/patch-Makefile.am,v
 retrieving revision 1.1
 diff -u -r1.1 patch-Makefile.am
 --- files/patch-Makefile.am	31 Mar 2001 02:45:55 -0000	1.1
 +++ files/patch-Makefile.am	26 Nov 2001 00:46:40 -0000
 @@ -1,33 +1,55 @@
 ---- Makefile.am.orig	Fri May 19 23:46:31 2000
 -+++ Makefile.am	Mon Mar 19 11:51:05 2001
 -@@ -7,30 +7,3 @@
 - rpm: dist
 - 	@cd build && $(MAKE) $(AM_MAKEFLAGS) rpm
 +--- Makefile.am.orig	Mon Oct 22 01:33:09 2001
 ++++ Makefile.am	Sun Nov 25 18:46:14 2001
 +@@ -1,6 +1,6 @@
 + include $(top_srcdir)/common.am
   
 --#  We proceed even if these commands fail because this might be an install
 --#  into $DESTDIR by a non-root user.
 +-SUBDIRS = util include support libfam fam man test build
 ++SUBDIRS = include support libfam fam man
 + 
 + EXTRA_DIST = common.am INSTALL.rpm
 + 
 +@@ -9,28 +9,28 @@
 + 
 + #  We proceed even if these commands fail because this might be an install
 + #  into $DESTDIR by a non-root user.
  -install-exec-hook:
  -	-@if test "no$(LDCONFIG)" != "no"; then \
 --##	    echo "Adding $(libdir) to ld.so.conf..."; \
 ++#install-exec-hook:
 ++#	-@if test "no$(LDCONFIG)" != "no"; then \
 + ##	    echo "Adding $(libdir) to ld.so.conf..."; \
  -	    $(EDITCONF) ld.so.conf add $(DESTDIR)$(libdir) $(DESTDIR)$(libdir); \
  -	    exec $(LDCONFIG); \
  -	fi
 --##	@echo "Adding fam to rpc..."
 ++#	    $(EDITCONF) ld.so.conf add $(DESTDIR)$(libdir) $(DESTDIR)$(libdir); \
 ++#	    exec $(LDCONFIG); \
 ++#	fi
 + ##	@echo "Adding fam to rpc..."
  -	-@$(EDITCONF) rpc add 391002 "sgi_fam		391002"
 --##	@echo "Adding fam to inetd.conf..."
 ++#	-@$(EDITCONF) rpc add 391002 "sgi_fam		391002"
 + ##	@echo "Adding fam to inetd.conf..."
  -	-@$(EDITCONF) inetd.conf add '\b(fam|FAM)\b' \
  -	    "#  fam, the File Alteration Monitor, http://oss.sgi.com/projects/fam/" \
  -	    "sgi_fam/1-2 stream rpc/tcp wait root $(DESTDIR)$(bindir)/fam fam"
  -	@echo "Restarting inetd..."
  -	-@killall -HUP inetd
 --
 --#  We don't remove $(libdir) from ld.so.conf here because we don't have
 --#  a way to tell whether we're the ones who added it, and other things
 --#  probably use it as well.
 ++#	-@$(EDITCONF) inetd.conf add '\b(fam|FAM)\b' \
 ++#	    "#  fam, the File Alteration Monitor, http://oss.sgi.com/projects/fam/" \
 ++#	    "sgi_fam/1-2 stream rpc/tcp wait root $(DESTDIR)$(bindir)/fam fam"
 ++#	@echo "Restarting inetd..."
 ++#	-@killall -HUP inetd
 + 
 + #  We don't remove $(libdir) from ld.so.conf here because we don't have
 + #  a way to tell whether we're the ones who added it, and other things
 + #  probably use it as well.
  -uninstall-local:
 --##	@echo "Removing fam from rpc..."
 ++#uninstall-local:
 + ##	@echo "Removing fam from rpc..."
  -	-@$(EDITCONF) rpc remove 391002
 --##	@echo "Removing fam from inetd.conf..."
 ++#	-@$(EDITCONF) rpc remove 391002
 + ##	@echo "Removing fam from inetd.conf..."
  -	-@$(EDITCONF) inetd.conf remove '\b(fam|FAM)\b'
  -	@echo "Restarting inetd..."
  -	-@killall -HUP inetd
 ++#	-@$(EDITCONF) inetd.conf remove '\b(fam|FAM)\b'
 ++#	@echo "Restarting inetd..."
 ++#	-@killall -HUP inetd
 Index: files/patch-acconfig.h
 ===================================================================
 RCS file: files/patch-acconfig.h
 diff -N files/patch-acconfig.h
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-acconfig.h	23 Nov 2001 15:54:25 -0000
 @@ -0,0 +1,11 @@
 +--- acconfig.h.orig	Mon Oct 22 01:33:09 2001
 ++++ acconfig.h	Fri Nov 23 09:54:00 2001
 +@@ -47,6 +47,8 @@
 + **  Otherwise, we'll use MNTTYPE_NFS.  */
 + #undef HAVE_FSID_NFS2
 + 
 ++#undef HAVE_MNTENT_H
 ++
 + /* Define if we have MNTTYPE_NFS2 */
 + #define HAVE_MNTTYPE_NFS2 0
 + 
 Index: files/patch-common.am
 ===================================================================
 RCS file: files/patch-common.am
 diff -N files/patch-common.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-common.am	7 Oct 2001 21:40:51 -0000
 @@ -0,0 +1,11 @@
 +--- common.am.orig	Fri May 19 23:46:31 2000
 ++++ common.am	Sun Oct  7 16:40:38 2001
 +@@ -1,7 +1,7 @@
 + #  Since we're not always using gcc, we don't want to use dependency
 + #  tracking.  (It croaks non-GNU compilers.)  Seems like this should be
 + #  configurable through autoconf!
 +-AUTOMAKE_OPTIONS=no-dependencies
 ++#AUTOMAKE_OPTIONS=no-dependencies
 + 
 + #  why couldn't CONFIG_ETC_CONFIG_PATH be defined in config.h???
 + INCLUDES = @FAMPROTOINC@ -DCONFIG_ETC_CONFIG_PATH=\"@FAM_CONF@\"
 Index: files/patch-config.h.in
 ===================================================================
 RCS file: files/patch-config.h.in
 diff -N files/patch-config.h.in
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-config.h.in	7 Oct 2001 20:28:42 -0000
 @@ -0,0 +1,11 @@
 +--- config.h.in.orig	Fri May 19 23:50:17 2000
 ++++ config.h.in	Sun Oct  7 15:22:17 2001
 +@@ -12,6 +12,8 @@
 + /*  Define if the system has imon and IMONIOC_ ioctl flags.  */
 + #undef HAVE_IMON
 + 
 ++#undef HAVE_MNTENT_H
 ++
 + /*  Define if the system has the struct revokdi and the IMONIOC_REVOKDI
 + **  ioctl flag.  (IRIX 5.3 doesn't.)
 + */
 Index: files/patch-configure.in
 ===================================================================
 RCS file: files/patch-configure.in
 diff -N files/patch-configure.in
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-configure.in	26 Nov 2001 00:42:27 -0000
 @@ -0,0 +1,79 @@
 +--- configure.in.orig	Sun Nov  4 23:31:30 2001
 ++++ configure.in	Sun Nov 25 18:28:59 2001
 +@@ -95,6 +95,8 @@
 + dnl AC_HEADER_SYS_WAIT
 + dnl AC_CHECK_HEADERS(fcntl.h limits.h sys/time.h syslog.h unistd.h)
 + 
 ++AC_CHECK_HEADER(mntent.h, AC_DEFINE(HAVE_MNTENT_H))
 ++
 + dnl
 + dnl  See if imon is available; if so, is it IRIX or Linux?
 + dnl
 +@@ -310,10 +312,10 @@
 + dnl If we don't have MNTTYPE_NFS , we croak.
 + dnl
 + 
 +-FAM_DECL_IN_MNTENT(MNTTYPE_NFS, ,AC_MSG_ERROR(Didn't find MNTTYPE_NFS in mntent.h))
 +-FAM_DECL_IN_MNTENT(MNTTYPE_NFS2, AC_DEFINE(HAVE_MNTTYPE_NFS2))
 +-FAM_DECL_IN_MNTENT(MNTTYPE_NFS3, AC_DEFINE(HAVE_MNTTYPE_NFS3))
 +-FAM_DECL_IN_MNTENT(MNTTYPE_CACHEFS, AC_DEFINE(HAVE_MNTTYPE_CACHEFS))
 ++dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS, ,AC_MSG_ERROR(Didn't find MNTTYPE_NFS in mntent.h))
 ++dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS2, AC_DEFINE(HAVE_MNTTYPE_NFS2))
 ++dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS3, AC_DEFINE(HAVE_MNTTYPE_NFS3))
 ++dnl FAM_DECL_IN_MNTENT(MNTTYPE_CACHEFS, AC_DEFINE(HAVE_MNTTYPE_CACHEFS))
 + 
 + dnl
 + dnl  Test for bindresvport() prototype.
 +@@ -516,8 +518,8 @@
 + 
 + dnl
 + dnl  This grief is for replacing XXX_FAM_CONF with $FAM_CONF
 +-dnl  in the fam(1M) man page.  (Simply putting @FAM_CONF@ in
 +-dnl  fam.1m.in puts the string "$sysconfdir/fam.conf" in the
 ++dnl  in the fam(8) man page.  (Simply putting @FAM_CONF@ in
 ++dnl  fam.8.in puts the string "$sysconfdir/fam.conf" in the
 + dnl  man page, which isn't acceptable.  Isn't there a way to make
 + dnl  autoconf handle this??)
 + dnl
 +@@ -529,7 +531,7 @@
 + [
 +     TMPFILE=configure.tmp
 +     for f in $CONFIG_FILES; do
 +-        if test `basename $f` != 'fam.1m'; then
 ++        if test `basename $f` != 'fam.8'; then
 +             continue
 +         fi
 +         echo "replacing XXX_FAM_CONF with $FAM_CONF and removing maintainer comments in $f"
 +@@ -554,25 +556,25 @@
 + dnl
 + AC_OUTPUT(
 +     Makefile 
 +-    build/Makefile
 +-    build/rpm/Makefile
 +-    build/rpm/rpm.spec
 ++dnl    build/Makefile
 ++dnl    build/rpm/Makefile
 ++dnl    build/rpm/rpm.spec
 +     fam/Makefile
 +     fam/fam.conf
 +     include/Makefile
 +     libfam/Makefile
 +     man/Makefile
 +-    man/fam.1m
 ++    man/fam.8
 +     support/Makefile
 +     test/Makefile
 +-    util/Makefile
 +-    util/editconf/Makefile
 ++dnl    util/Makefile
 ++dnl    util/editconf/Makefile
 + )
 + 
 + dnl 
 + dnl  fam is a good deal less interesting without imon.
 + dnl 
 +-if test "$have_imon" != 'yes'; then
 ++if test `uname` = Linux && "$have_imon" != 'yes'; then
 +     cat << EOF
 + 
 +   ******************************************************************
 Index: files/patch-fam::Client.h
 ===================================================================
 RCS file: files/patch-fam::Client.h
 diff -N files/patch-fam::Client.h
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Client.h	7 Oct 2001 20:22:45 -0000
 @@ -0,0 +1,10 @@
 +--- fam/Client.h.orig	Fri May 19 23:46:31 2000
 ++++ fam/Client.h	Sun Oct  7 15:22:17 2001
 +@@ -23,6 +23,7 @@
 + #ifndef Client_included
 + #define Client_included
 + 
 ++#include <sys/types.h>
 + #include <netinet/in.h>  // for in_addr
 + 
 + #include "Activity.h"
 Index: files/patch-fam::FileSystem.c++
 ===================================================================
 RCS file: files/patch-fam::FileSystem.c++
 diff -N files/patch-fam::FileSystem.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::FileSystem.c++	7 Oct 2001 20:23:29 -0000
 @@ -0,0 +1,11 @@
 +--- fam/FileSystem.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/FileSystem.c++	Sun Oct  7 15:22:17 2001
 +@@ -22,7 +22,7 @@
 + 
 + #include "FileSystem.h"
 + 
 +-#include <mntent.h>
 ++#include "mntent.h"
 + #include <string.h>
 + 
 + #include "Event.h"
 Index: files/patch-fam::FileSystemTable.c++
 ===================================================================
 RCS file: files/patch-fam::FileSystemTable.c++
 diff -N files/patch-fam::FileSystemTable.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::FileSystemTable.c++	7 Oct 2001 20:24:05 -0000
 @@ -0,0 +1,25 @@
 +--- fam/FileSystemTable.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/FileSystemTable.c++	Sun Oct  7 15:22:17 2001
 +@@ -21,9 +21,10 @@
 + //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 + 
 + #include <stddef.h>
 ++#include <stdio.h>
 + #include "FileSystemTable.h"
 + 
 +-#include <mntent.h>
 ++#include "mntent.h"
 + #include <stdlib.h>
 + #include <string.h>
 + 
 +@@ -255,7 +256,10 @@
 +     //  create_fs_by_name initializes our "root" member variable.
 +     if (!fs_by_name)
 +     {   create_fs_by_name();
 ++#if !defined(__FreeBSD__)
 ++	/* there is no mtab "file" in freebsd! */
 + 	mtab_watcher = new InternalClient(mtab_name, mtab_event_handler, NULL);
 ++#endif
 +     }
 + 
 +     cr.become_user();
 Index: files/patch-fam::IMon.c++
 ===================================================================
 RCS file: files/patch-fam::IMon.c++
 diff -N files/patch-fam::IMon.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::IMon.c++	7 Oct 2001 20:24:25 -0000
 @@ -0,0 +1,13 @@
 +--- fam/IMon.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/IMon.c++	Sun Oct  7 15:22:17 2001
 +@@ -34,7 +34,9 @@
 + #endif
 + #endif
 + 
 +-#include <sys/sysmacros.h>
 ++#if !defined(__FreeBSD__)
 ++#  include <sys/sysmacros.h>
 ++#endif
 + #include <unistd.h>
 + 
 + #include "Interest.h"
 Index: files/patch-fam::Interest.c++
 ===================================================================
 RCS file: files/patch-fam::Interest.c++
 diff -N files/patch-fam::Interest.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Interest.c++	7 Oct 2001 20:24:54 -0000
 @@ -0,0 +1,13 @@
 +--- fam/Interest.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/Interest.c++	Sun Oct  7 15:22:17 2001
 +@@ -25,7 +25,9 @@
 + #include <string.h>
 + #include <errno.h>
 + #include <sys/param.h>
 +-#include <sys/sysmacros.h>
 ++#if !defined(__FreeBSD__)
 ++#  include <sys/sysmacros.h>
 ++#endif
 + 
 + #ifdef HAVE_IRIX_XTAB_VERIFICATION
 + #include <stdio.h>
 Index: files/patch-fam::InternalClient.c++
 ===================================================================
 RCS file: files/patch-fam::InternalClient.c++
 diff -N files/patch-fam::InternalClient.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::InternalClient.c++	7 Oct 2001 20:25:13 -0000
 @@ -0,0 +1,12 @@
 +--- fam/InternalClient.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/InternalClient.c++	Sun Oct  7 15:22:17 2001
 +@@ -35,8 +35,8 @@
 + {
 +     assert(filename);
 +     assert(h);
 +-    assert(filename[0] == '/');
 +     Log::debug("%s watching %s", name(), filename);
 ++    assert(filename[0] == '/');
 +     interest = new File(filename, this, Request(0), Cred::SuperUser);
 + }
 + 
 Index: files/patch-fam::Listener.c++
 ===================================================================
 RCS file: files/patch-fam::Listener.c++
 diff -N files/patch-fam::Listener.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Listener.c++	23 Nov 2001 15:53:02 -0000
 @@ -0,0 +1,56 @@
 +--- fam/Listener.c++.orig	Mon Oct 22 01:33:10 2001
 ++++ fam/Listener.c++	Fri Nov 23 09:52:14 2001
 +@@ -22,6 +22,8 @@
 + 
 + #include "Listener.h"
 + 
 ++#include <stdio.h>
 ++#include <stdlib.h>
 + #include <assert.h>
 + #include <fcntl.h>
 + #include <sys/types.h>
 +@@ -205,7 +207,11 @@
 +     unsetenv("TMPDIR");
 + 
 +     char *tmpfile = tempnam("/tmp", ".fam");
 ++#if defined(__FreeBSD__)
 ++    sockaddr_un sun = { sizeof(sockaddr_un), AF_UNIX, "" };
 ++#else
 +     sockaddr_un sun = { AF_UNIX, "" };
 ++#endif
 +     if(strlen(tmpfile) >= (sizeof(sun.sun_path) - 1))
 +     {
 +         Log::error("tmpnam() too long for sun_path (%d >= %d)!",
 +@@ -239,7 +245,7 @@
 +         return;
 +     }
 + 
 +-    if (chown(sun.sun_path, uid, -1) != 0)
 ++    if (chown(sun.sun_path, uid, (gid_t)-1) != 0)
 +     {   Log::perror("localclient chown");
 + 	close(client_sock);
 +         return;
 +@@ -275,7 +281,11 @@
 + 
 +     // Get the new socket.
 + 
 ++#if defined(__FreeBSD__)
 ++    struct sockaddr_un sun = { sizeof(sockaddr_un), AF_UNIX, "" };
 ++#else
 +     struct sockaddr_un sun = { AF_UNIX, "" };
 ++#endif
 +     CONFIG_SOCKLEN_T sunlen = sizeof(sun);
 +     int client_fd = accept(ofd, (struct sockaddr *) &sun, &sunlen);
 +     if (client_fd < 0)
 +@@ -337,7 +347,11 @@
 + void
 + Listener::dirty_ugly_hack()
 + {
 ++#if defined(__FreeBSD__)
 ++    static sockaddr_un sun = { sizeof (sockaddr_un), AF_UNIX, "/tmp/.fam_socket" };
 ++#else
 +     static sockaddr_un sun = { AF_UNIX, "/tmp/.fam_socket" };
 ++#endif
 + 
 +     int sock = socket(PF_UNIX, SOCK_STREAM, 0);
 +     if (sock < 0)
 Index: files/patch-fam::Log.c++
 ===================================================================
 RCS file: files/patch-fam::Log.c++
 diff -N files/patch-fam::Log.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Log.c++	7 Oct 2001 20:25:48 -0000
 @@ -0,0 +1,11 @@
 +--- fam/Log.c++.orig	Fri May 19 23:46:31 2000
 ++++ fam/Log.c++	Sun Oct  7 15:22:17 2001
 +@@ -28,6 +28,8 @@
 + #include <stdlib.h>
 + #include <string.h>
 + #include <syslog.h>
 ++#include <sys/time.h>
 ++#include <sys/types.h>
 + #include <sys/resource.h>
 + #include <sys/stat.h>
 + #include <unistd.h>
 Index: files/patch-fam::Makefile.am
 ===================================================================
 RCS file: files/patch-fam::Makefile.am
 diff -N files/patch-fam::Makefile.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Makefile.am	26 Nov 2001 00:38:44 -0000
 @@ -0,0 +1,27 @@
 +--- fam/Makefile.am.orig	Mon Oct 22 01:33:10 2001
 ++++ fam/Makefile.am	Sun Nov 25 18:38:06 2001
 +@@ -1,7 +1,7 @@
 + include $(top_srcdir)/common.am
 + 
 +-bin_PROGRAMS = fam
 +-sysconf_DATA = fam.conf
 ++sbin_PROGRAMS = fam
 ++sysconf_DATA = fam.conf.sample
 + 
 + fam_SOURCES = \
 +   Activity.c++ \
 +@@ -72,11 +72,12 @@
 +   main.c++ \
 +   timeval.c++ \
 +   timeval.h \
 ++  mntent_compat.c++ \
 +   @IMON_FUNCS@.c++
 + 
 + EXTRA_fam_SOURCES = IMonIrix.c++ IMonLinux.c++ IMonNone.c++
 + 
 + fam_LDADD = -lrpcsvc $(top_srcdir)/support/libsupport.a
 + 
 +-CLEANFILES += @MKDEPFILE@ ii_files/*.ii
 +-sinclude @MKDEPFILE@
 ++CLEANFILES = @MKDEPFILE@ ii_files/*.ii
 ++#sinclude @MKDEPFILE@
 Index: files/patch-fam::Scheduler.h
 ===================================================================
 RCS file: files/patch-fam::Scheduler.h
 diff -N files/patch-fam::Scheduler.h
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::Scheduler.h	7 Oct 2001 20:26:25 -0000
 @@ -0,0 +1,10 @@
 +--- fam/Scheduler.h.orig	Fri May 19 23:46:32 2000
 ++++ fam/Scheduler.h	Sun Oct  7 15:22:17 2001
 +@@ -24,6 +24,7 @@
 + #define Scheduler_included
 + 
 + #include <sys/time.h>
 ++#include <string.h>
 + 
 + #include "Boolean.h"
 + 
 Index: files/patch-fam::StringTable.h
 ===================================================================
 RCS file: files/patch-fam::StringTable.h
 diff -N files/patch-fam::StringTable.h
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::StringTable.h	7 Oct 2001 20:26:42 -0000
 @@ -0,0 +1,10 @@
 +--- fam/StringTable.h.orig	Fri May 19 23:46:32 2000
 ++++ fam/StringTable.h	Sun Oct  7 15:22:17 2001
 +@@ -25,6 +25,7 @@
 + 
 + #include <assert.h>
 + #include <string.h>
 ++#include "mntent.h"
 + 
 + //  A StringTable maps C strings onto values.  It is a cheap O(n)
 + //  implementation, suitable only for small tables that are
 Index: files/patch-fam::fam.conf.in
 ===================================================================
 RCS file: files/patch-fam::fam.conf.in
 diff -N files/patch-fam::fam.conf.in
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::fam.conf.in	26 Nov 2001 00:24:01 -0000
 @@ -0,0 +1,11 @@
 +--- fam/fam.conf.in.orig	Mon Oct 22 01:33:11 2001
 ++++ fam/fam.conf.in	Sun Nov 25 18:23:46 2001
 +@@ -6,7 +6,7 @@
 + #  fam.conf
 + #
 + #  For more information on the configuration options below, see the
 +-#  fam(1M) man page.
 ++#  fam(8) man page.
 + 
 + #
 + #  insecure_compatibility disables authentication.  This causes
 Index: files/patch-fam::mntent.h
 ===================================================================
 RCS file: files/patch-fam::mntent.h
 diff -N files/patch-fam::mntent.h
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::mntent.h	7 Oct 2001 20:27:09 -0000
 @@ -0,0 +1,59 @@
 +--- fam/mntent.h.orig	Sun Oct  7 15:22:17 2001
 ++++ fam/mntent.h	Sun Oct  7 15:22:17 2001
 +@@ -0,0 +1,56 @@
 ++/*
 ++ *  mntent
 ++ *  mntent.h - compatability header for FreeBSD
 ++ *
 ++ *  Copyright (c) 2001 David Rufino <daverufino@btinternet.com>
 ++ *  All rights reserved.
 ++ *
 ++ * 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.
 ++ *
 ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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.
 ++ */
 ++
 ++#if defined(HAVE_MNTENT_H)
 ++#include <mntent.h>
 ++#else
 ++#ifndef _MNTENT_H
 ++#define _MNTENT_H
 ++#include <stdio.h>
 ++
 ++#define MOUNTED "dummy"
 ++
 ++#define MNTTYPE_NFS "nfs"
 ++
 ++struct mntent {
 ++	char *mnt_fsname;
 ++	char *mnt_dir;
 ++	char *mnt_type;
 ++	char *mnt_opts;
 ++	int mnt_freq;
 ++	int mnt_passno;
 ++};
 ++
 ++#define setmntent(x,y) ((FILE *)0x1)
 ++struct mntent *getmntent __P ((FILE *fp));
 ++char *hasmntopt __P ((const struct mntent *mnt, const char *option));
 ++#define endmntent(x) ((int)1)
 ++
 ++#endif /* _MNTENT_H */
 ++#endif /* HAVE_MNTENT_H */
 Index: files/patch-fam::mntent_compat.c++
 ===================================================================
 RCS file: files/patch-fam::mntent_compat.c++
 diff -N files/patch-fam::mntent_compat.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-fam::mntent_compat.c++	7 Oct 2001 20:27:32 -0000
 @@ -0,0 +1,154 @@
 +--- fam/mntent_compat.c++.orig	Sun Oct  7 15:22:17 2001
 ++++ fam/mntent_compat.c++	Sun Oct  7 15:22:17 2001
 +@@ -0,0 +1,151 @@
 ++/*
 ++ * Copyright (c) 1980, 1989, 1993, 1994
 ++ *      The Regents of the University of California.  All rights reserved.
 ++ * Copyright (c) 2001
 ++ *      David Rufino <daverufino@btinternet.com>
 ++ *
 ++ * 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. All advertising materials mentioning features or use of this software
 ++ *    must display the following acknowledgement:
 ++ *      This product includes software developed by the University of
 ++ *      California, Berkeley and its contributors.
 ++ * 4. Neither the name of the University nor the names of its contributors
 ++ *    may be used to endorse or promote products derived from this software
 ++ *    without specific prior written permission.
 ++ *
 ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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.
 ++ */
 ++
 ++/* most of this was ripped from the mount(3) source */
 ++
 ++#include "config.h"
 ++#include "mntent.h"
 ++#if !defined(HAVE_MNTENT_H)
 ++#include <stdlib.h>
 ++#include <string.h>
 ++#include <sys/param.h>
 ++#include <sys/ucred.h>
 ++#include <sys/mount.h>
 ++
 ++static int pos = -1;
 ++static int mntsize = -1;
 ++static struct mntent _mntent;
 ++
 ++char *
 ++hasmntopt (const struct mntent *mnt, const char *option)
 ++{
 ++        int found;
 ++        char *opt, *optbuf;
 ++
 ++        optbuf = strdup(mnt->mnt_opts);
 ++        found = 0;
 ++        for (opt = optbuf; (opt = strtok(opt, " ")) != NULL; opt = NULL) {
 ++                if (!strcasecmp(opt, option)) {
 ++			opt = opt - optbuf + mnt->mnt_opts;
 ++			free (optbuf);
 ++			return (opt);
 ++		}
 ++        }
 ++	free (optbuf);
 ++        return (NULL);
 ++}
 ++
 ++static char *
 ++catopt (char *s0, const char *s1)
 ++{
 ++        size_t i;
 ++        char *cp;
 ++
 ++        if (s1 == NULL || *s1 == '\0')
 ++                return s0;
 ++        if (s0 && *s0) {
 ++                i = strlen(s0) + strlen(s1) + 1 + 1;
 ++                if ((cp = (char *)malloc(i)) == NULL)
 ++			return (NULL);
 ++                (void)snprintf(cp, i, "%s %s", s0, s1);
 ++        } else
 ++                cp = strdup(s1);
 ++
 ++        if (s0)
 ++                free(s0);
 ++        return (cp);
 ++}
 ++
 ++
 ++static char *
 ++flags2opts (int flags)
 ++{
 ++        char *res;
 ++        res = NULL;
 ++        res = catopt(res, (flags & MNT_RDONLY) ? "ro" : "rw");
 ++        if (flags & MNT_SYNCHRONOUS)    res = catopt(res, "sync");
 ++        if (flags & MNT_NOEXEC)         res = catopt(res, "noexec");
 ++        if (flags & MNT_NOSUID)         res = catopt(res, "nosuid");
 ++        if (flags & MNT_NODEV)          res = catopt(res, "nodev");
 ++        if (flags & MNT_UNION)          res = catopt(res, "union");
 ++        if (flags & MNT_ASYNC)          res = catopt(res, "async");
 ++        if (flags & MNT_NOATIME)        res = catopt(res, "noatime");
 ++        if (flags & MNT_NOCLUSTERR)     res = catopt(res, "noclusterr");
 ++        if (flags & MNT_NOCLUSTERW)     res = catopt(res, "noclusterw");
 ++        if (flags & MNT_NOSYMFOLLOW)    res = catopt(res, "nosymfollow");
 ++        if (flags & MNT_SUIDDIR)        res = catopt(res, "suiddir");
 ++
 ++        return res;
 ++}
 ++
 ++static struct mntent *
 ++statfs_to_mntent (struct statfs *mntbuf)
 ++{
 ++	static char opts_buf[40], *tmp;
 ++	
 ++	_mntent.mnt_fsname = mntbuf->f_mntfromname;
 ++	_mntent.mnt_dir = mntbuf->f_mntonname;
 ++	_mntent.mnt_type = mntbuf->f_fstypename;
 ++	tmp = flags2opts (mntbuf->f_flags);
 ++	if (tmp) {
 ++		opts_buf[sizeof(opts_buf)-1] = '\0';
 ++		strncpy (opts_buf, tmp, sizeof(opts_buf)-1);
 ++		free (tmp);
 ++	} else {
 ++		*opts_buf = '\0';
 ++	}
 ++	_mntent.mnt_opts = opts_buf;	
 ++	_mntent.mnt_freq = _mntent.mnt_passno = 0;
 ++	return (&_mntent);
 ++}
 ++
 ++struct mntent *
 ++getmntent (FILE *fp)
 ++{
 ++	struct statfs *mntbuf;
 ++
 ++	if (pos == -1 || mntsize == -1)
 ++		mntsize = getmntinfo (&mntbuf, MNT_NOWAIT);
 ++
 ++	++pos;
 ++	if (pos == mntsize) {
 ++		pos = mntsize = -1;
 ++		return (NULL);
 ++	}
 ++
 ++	return (statfs_to_mntent (&mntbuf[pos]));
 ++}
 ++
 ++#endif /* HAVE_MNTENT_H */
 Index: files/patch-freebsd
 ===================================================================
 RCS file: files/patch-freebsd
 diff -N files/patch-freebsd
 --- files/patch-freebsd	31 Mar 2001 02:45:55 -0000	1.1
 +++ /dev/null	1 Jan 1970 00:00:00 -0000
 @@ -1,490 +0,0 @@
 -diff -urN fam-oss-2.6.4/config.h.in fam-oss-2.6.4-freebsd/config.h.in
 ---- fam-oss-2.6.4/config.h.in	Sat May 20 05:50:17 2000
 -+++ fam-oss-2.6.4-freebsd/config.h.in	Sun Mar 18 00:02:38 2001
 -@@ -12,6 +12,8 @@
 - /*  Define if the system has imon and IMONIOC_ ioctl flags.  */
 - #undef HAVE_IMON
 - 
 -+#undef HAVE_MNTENT_H
 -+
 - /*  Define if the system has the struct revokdi and the IMONIOC_REVOKDI
 - **  ioctl flag.  (IRIX 5.3 doesn't.)
 - */
 -diff -urN fam-oss-2.6.4/configure.in fam-oss-2.6.4-freebsd/configure.in
 ---- fam-oss-2.6.4/configure.in	Sat May 20 06:23:17 2000
 -+++ fam-oss-2.6.4-freebsd/configure.in	Sun Mar 18 00:36:29 2001
 -@@ -95,6 +95,8 @@
 - dnl AC_HEADER_SYS_WAIT
 - dnl AC_CHECK_HEADERS(fcntl.h limits.h sys/time.h syslog.h unistd.h)
 - 
 -+AC_CHECK_HEADER(mntent.h, AC_DEFINE(HAVE_MNTENT_H))
 -+
 - dnl
 - dnl  See if imon is available; if so, is it IRIX or Linux?
 - dnl
 -@@ -299,10 +301,10 @@
 - dnl If we don't have MNTTYPE_NFS , we croak.
 - dnl
 - 
 --FAM_DECL_IN_MNTENT(MNTTYPE_NFS, ,AC_MSG_ERROR(Didn't find MNTTYPE_NFS in mntent.h))
 --FAM_DECL_IN_MNTENT(MNTTYPE_NFS2, AC_DEFINE(HAVE_MNTTYPE_NFS2))
 --FAM_DECL_IN_MNTENT(MNTTYPE_NFS3, AC_DEFINE(HAVE_MNTTYPE_NFS3))
 --FAM_DECL_IN_MNTENT(MNTTYPE_CACHEFS, AC_DEFINE(HAVE_MNTTYPE_CACHEFS))
 -+dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS, ,AC_MSG_ERROR(Didn't find MNTTYPE_NFS in mntent.h))
 -+dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS2, AC_DEFINE(HAVE_MNTTYPE_NFS2))
 -+dnl FAM_DECL_IN_MNTENT(MNTTYPE_NFS3, AC_DEFINE(HAVE_MNTTYPE_NFS3))
 -+dnl FAM_DECL_IN_MNTENT(MNTTYPE_CACHEFS, AC_DEFINE(HAVE_MNTTYPE_CACHEFS))
 - 
 - dnl
 - dnl  Test for bindresvport() prototype.
 -diff -urN fam-oss-2.6.4/fam/Client.h fam-oss-2.6.4-freebsd/fam/Client.h
 ---- fam-oss-2.6.4/fam/Client.h	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Client.h	Sat Mar 17 00:14:35 2001
 -@@ -23,6 +23,7 @@
 - #ifndef Client_included
 - #define Client_included
 - 
 -+#include <sys/types.h>
 - #include <netinet/in.h>  // for in_addr
 - 
 - #include "Activity.h"
 -diff -urN fam-oss-2.6.4/fam/FileSystem.c++ fam-oss-2.6.4-freebsd/fam/FileSystem.c++
 ---- fam-oss-2.6.4/fam/FileSystem.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/FileSystem.c++	Sat Mar 17 13:18:10 2001
 -@@ -22,7 +22,7 @@
 - 
 - #include "FileSystem.h"
 - 
 --#include <mntent.h>
 -+#include "mntent.h"
 - #include <string.h>
 - 
 - #include "Event.h"
 -diff -urN fam-oss-2.6.4/fam/FileSystemTable.c++ fam-oss-2.6.4-freebsd/fam/FileSystemTable.c++
 ---- fam-oss-2.6.4/fam/FileSystemTable.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/FileSystemTable.c++	Sat Mar 17 23:44:17 2001
 -@@ -21,9 +21,10 @@
 - //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 - 
 - #include <stddef.h>
 -+#include <stdio.h>
 - #include "FileSystemTable.h"
 - 
 --#include <mntent.h>
 -+#include "mntent.h"
 - #include <stdlib.h>
 - #include <string.h>
 - 
 -@@ -255,7 +256,10 @@
 -     //  create_fs_by_name initializes our "root" member variable.
 -     if (!fs_by_name)
 -     {   create_fs_by_name();
 -+#if !defined(__FreeBSD__)
 -+	/* there is no mtab "file" in freebsd! */
 - 	mtab_watcher = new InternalClient(mtab_name, mtab_event_handler, NULL);
 -+#endif
 -     }
 - 
 -     cr.become_user();
 -diff -urN fam-oss-2.6.4/fam/IMon.c++ fam-oss-2.6.4-freebsd/fam/IMon.c++
 ---- fam-oss-2.6.4/fam/IMon.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/IMon.c++	Sat Mar 17 14:06:17 2001
 -@@ -34,7 +34,9 @@
 - #endif
 - #endif
 - 
 --#include <sys/sysmacros.h>
 -+#if !defined(__FreeBSD__)
 -+#  include <sys/sysmacros.h>
 -+#endif
 - #include <unistd.h>
 - 
 - #include "Interest.h"
 -diff -urN fam-oss-2.6.4/fam/Interest.c++ fam-oss-2.6.4-freebsd/fam/Interest.c++
 ---- fam-oss-2.6.4/fam/Interest.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Interest.c++	Sat Mar 17 14:06:37 2001
 -@@ -25,7 +25,9 @@
 - #include <string.h>
 - #include <errno.h>
 - #include <sys/param.h>
 --#include <sys/sysmacros.h>
 -+#if !defined(__FreeBSD__)
 -+#  include <sys/sysmacros.h>
 -+#endif
 - 
 - #ifdef HAVE_IRIX_XTAB_VERIFICATION
 - #include <stdio.h>
 -diff -urN fam-oss-2.6.4/fam/InternalClient.c++ fam-oss-2.6.4-freebsd/fam/InternalClient.c++
 ---- fam-oss-2.6.4/fam/InternalClient.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/InternalClient.c++	Sat Mar 17 23:20:15 2001
 -@@ -35,8 +35,8 @@
 - {
 -     assert(filename);
 -     assert(h);
 --    assert(filename[0] == '/');
 -     Log::debug("%s watching %s", name(), filename);
 -+    assert(filename[0] == '/');
 -     interest = new File(filename, this, Request(0), Cred::SuperUser);
 - }
 - 
 -diff -urN fam-oss-2.6.4/fam/Listener.c++ fam-oss-2.6.4-freebsd/fam/Listener.c++
 ---- fam-oss-2.6.4/fam/Listener.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Listener.c++	Sat Mar 17 14:12:57 2001
 -@@ -22,6 +22,8 @@
 - 
 - #include "Listener.h"
 - 
 -+#include <stdio.h>
 -+#include <stdlib.h>
 - #include <assert.h>
 - #include <fcntl.h>
 - #include <sys/types.h>
 -@@ -202,7 +204,11 @@
 -     //  requested user and pass the name back to the client.
 - 
 -     char *tmpfile = tempnam("/tmp", ".fam");
 -+#if defined(__FreeBSD__)
 -+    sockaddr_un sun = { sizeof(sockaddr_un), AF_UNIX, "" };
 -+#else
 -     sockaddr_un sun = { AF_UNIX, "" };
 -+#endif
 -     if(strlen(tmpfile) >= (sizeof(sun.sun_path) - 1))
 -     {
 -         Log::error("tmpnam() too long for sun_path (%d >= %d)!",
 -@@ -235,7 +241,7 @@
 -         return;
 -     }
 - 
 --    if (chown(sun.sun_path, uid, -1) != 0)
 -+    if (chown(sun.sun_path, uid, (gid_t)-1) != 0)
 -     {   Log::perror("localclient chown");
 - 	close(client_sock);
 -         return;
 -@@ -271,7 +277,11 @@
 - 
 -     // Get the new socket.
 - 
 -+#if defined(__FreeBSD__)
 -+    struct sockaddr_un sun = { sizeof(sockaddr_un), AF_UNIX, "" };
 -+#else
 -     struct sockaddr_un sun = { AF_UNIX, "" };
 -+#endif
 -     CONFIG_SOCKLEN_T sunlen = sizeof(sun);
 -     int client_fd = accept(ofd, (struct sockaddr *) &sun, &sunlen);
 -     if (client_fd < 0)
 -@@ -333,7 +343,11 @@
 - void
 - Listener::dirty_ugly_hack()
 - {
 -+#if defined(__FreeBSD__)
 -+    static sockaddr_un sun = { sizeof (sockaddr_un), AF_UNIX, "/tmp/.fam_socket" };
 -+#else
 -     static sockaddr_un sun = { AF_UNIX, "/tmp/.fam_socket" };
 -+#endif
 - 
 -     int sock = socket(PF_UNIX, SOCK_STREAM, 0);
 -     if (sock < 0)
 -diff -urN fam-oss-2.6.4/fam/Log.c++ fam-oss-2.6.4-freebsd/fam/Log.c++
 ---- fam-oss-2.6.4/fam/Log.c++	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Log.c++	Sat Mar 17 14:14:31 2001
 -@@ -28,6 +28,8 @@
 - #include <stdlib.h>
 - #include <string.h>
 - #include <syslog.h>
 -+#include <sys/time.h>
 -+#include <sys/types.h>
 - #include <sys/resource.h>
 - #include <sys/stat.h>
 - #include <unistd.h>
 -diff -urN fam-oss-2.6.4/fam/Makefile.am fam-oss-2.6.4-freebsd/fam/Makefile.am
 ---- fam-oss-2.6.4/fam/Makefile.am	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Makefile.am	Sat Mar 17 18:12:17 2001
 -@@ -72,6 +72,7 @@
 -   main.c++ \
 -   timeval.c++ \
 -   timeval.h \
 -+  mntent_compat.c++ \
 -   @IMON_FUNCS@.c++
 - 
 - EXTRA_fam_SOURCES = IMonIrix.c++ IMonLinux.c++ IMonNone.c++
 -diff -urN fam-oss-2.6.4/fam/Scheduler.h fam-oss-2.6.4-freebsd/fam/Scheduler.h
 ---- fam-oss-2.6.4/fam/Scheduler.h	Sat May 20 05:46:32 2000
 -+++ fam-oss-2.6.4-freebsd/fam/Scheduler.h	Sat Mar 17 00:14:04 2001
 -@@ -24,6 +24,7 @@
 - #define Scheduler_included
 - 
 - #include <sys/time.h>
 -+#include <string.h>
 - 
 - #include "Boolean.h"
 - 
 -diff -urN fam-oss-2.6.4/fam/StringTable.h fam-oss-2.6.4-freebsd/fam/StringTable.h
 ---- fam-oss-2.6.4/fam/StringTable.h	Sat May 20 05:46:32 2000
 -+++ fam-oss-2.6.4-freebsd/fam/StringTable.h	Sat Mar 17 18:05:38 2001
 -@@ -25,6 +25,7 @@
 - 
 - #include <assert.h>
 - #include <string.h>
 -+#include "mntent.h"
 - 
 - //  A StringTable maps C strings onto values.  It is a cheap O(n)
 - //  implementation, suitable only for small tables that are
 -diff -urN fam-oss-2.6.4/fam/mntent.h fam-oss-2.6.4-freebsd/fam/mntent.h
 ---- fam-oss-2.6.4/fam/mntent.h	Thu Jan  1 01:00:00 1970
 -+++ fam-oss-2.6.4-freebsd/fam/mntent.h	Sat Mar 17 18:11:08 2001
 -@@ -0,0 +1,56 @@
 -+/*
 -+ *  mntent
 -+ *  mntent.h - compatability header for FreeBSD
 -+ *
 -+ *  Copyright (c) 2001 David Rufino <daverufino@btinternet.com>
 -+ *  All rights reserved.
 -+ *
 -+ * 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.
 -+ *
 -+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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.
 -+ */
 -+
 -+#if defined(HAVE_MNTENT_H)
 -+#include <mntent.h>
 -+#else
 -+#ifndef _MNTENT_H
 -+#define _MNTENT_H
 -+#include <stdio.h>
 -+
 -+#define MOUNTED "dummy"
 -+
 -+#define MNTTYPE_NFS "nfs"
 -+
 -+struct mntent {
 -+	char *mnt_fsname;
 -+	char *mnt_dir;
 -+	char *mnt_type;
 -+	char *mnt_opts;
 -+	int mnt_freq;
 -+	int mnt_passno;
 -+};
 -+
 -+#define setmntent(x,y) ((FILE *)0x1)
 -+struct mntent *getmntent __P ((FILE *fp));
 -+char *hasmntopt __P ((const struct mntent *mnt, const char *option));
 -+#define endmntent(x) ((int)1)
 -+
 -+#endif /* _MNTENT_H */
 -+#endif /* HAVE_MNTENT_H */
 -diff -urN fam-oss-2.6.4/fam/mntent_compat.c++ fam-oss-2.6.4-freebsd/fam/mntent_compat.c++
 ---- fam-oss-2.6.4/fam/mntent_compat.c++	Thu Jan  1 01:00:00 1970
 -+++ fam-oss-2.6.4-freebsd/fam/mntent_compat.c++	Sat Mar 17 23:48:07 2001
 -@@ -0,0 +1,151 @@
 -+/*
 -+ * Copyright (c) 1980, 1989, 1993, 1994
 -+ *      The Regents of the University of California.  All rights reserved.
 -+ * Copyright (c) 2001
 -+ *      David Rufino <daverufino@btinternet.com>
 -+ *
 -+ * 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. All advertising materials mentioning features or use of this software
 -+ *    must display the following acknowledgement:
 -+ *      This product includes software developed by the University of
 -+ *      California, Berkeley and its contributors.
 -+ * 4. Neither the name of the University nor the names of its contributors
 -+ *    may be used to endorse or promote products derived from this software
 -+ *    without specific prior written permission.
 -+ *
 -+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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.
 -+ */
 -+
 -+/* most of this was ripped from the mount(3) source */
 -+
 -+#include "config.h"
 -+#include "mntent.h"
 -+#if !defined(HAVE_MNTENT_H)
 -+#include <stdlib.h>
 -+#include <string.h>
 -+#include <sys/param.h>
 -+#include <sys/ucred.h>
 -+#include <sys/mount.h>
 -+
 -+static int pos = -1;
 -+static int mntsize = -1;
 -+static struct mntent _mntent;
 -+
 -+char *
 -+hasmntopt (const struct mntent *mnt, const char *option)
 -+{
 -+        int found;
 -+        char *opt, *optbuf;
 -+
 -+        optbuf = strdup(mnt->mnt_opts);
 -+        found = 0;
 -+        for (opt = optbuf; (opt = strtok(opt, " ")) != NULL; opt = NULL) {
 -+                if (!strcasecmp(opt, option)) {
 -+			opt = opt - optbuf + mnt->mnt_opts;
 -+			free (optbuf);
 -+			return (opt);
 -+		}
 -+        }
 -+	free (optbuf);
 -+        return (NULL);
 -+}
 -+
 -+static char *
 -+catopt (char *s0, const char *s1)
 -+{
 -+        size_t i;
 -+        char *cp;
 -+
 -+        if (s1 == NULL || *s1 == '\0')
 -+                return s0;
 -+        if (s0 && *s0) {
 -+                i = strlen(s0) + strlen(s1) + 1 + 1;
 -+                if ((cp = (char *)malloc(i)) == NULL)
 -+			return (NULL);
 -+                (void)snprintf(cp, i, "%s %s", s0, s1);
 -+        } else
 -+                cp = strdup(s1);
 -+
 -+        if (s0)
 -+                free(s0);
 -+        return (cp);
 -+}
 -+
 -+
 -+static char *
 -+flags2opts (int flags)
 -+{
 -+        char *res;
 -+        res = NULL;
 -+        res = catopt(res, (flags & MNT_RDONLY) ? "ro" : "rw");
 -+        if (flags & MNT_SYNCHRONOUS)    res = catopt(res, "sync");
 -+        if (flags & MNT_NOEXEC)         res = catopt(res, "noexec");
 -+        if (flags & MNT_NOSUID)         res = catopt(res, "nosuid");
 -+        if (flags & MNT_NODEV)          res = catopt(res, "nodev");
 -+        if (flags & MNT_UNION)          res = catopt(res, "union");
 -+        if (flags & MNT_ASYNC)          res = catopt(res, "async");
 -+        if (flags & MNT_NOATIME)        res = catopt(res, "noatime");
 -+        if (flags & MNT_NOCLUSTERR)     res = catopt(res, "noclusterr");
 -+        if (flags & MNT_NOCLUSTERW)     res = catopt(res, "noclusterw");
 -+        if (flags & MNT_NOSYMFOLLOW)    res = catopt(res, "nosymfollow");
 -+        if (flags & MNT_SUIDDIR)        res = catopt(res, "suiddir");
 -+
 -+        return res;
 -+}
 -+
 -+static struct mntent *
 -+statfs_to_mntent (struct statfs *mntbuf)
 -+{
 -+	static char opts_buf[40], *tmp;
 -+	
 -+	_mntent.mnt_fsname = mntbuf->f_mntfromname;
 -+	_mntent.mnt_dir = mntbuf->f_mntonname;
 -+	_mntent.mnt_type = mntbuf->f_fstypename;
 -+	tmp = flags2opts (mntbuf->f_flags);
 -+	if (tmp) {
 -+		opts_buf[sizeof(opts_buf)-1] = '\0';
 -+		strncpy (opts_buf, tmp, sizeof(opts_buf)-1);
 -+		free (tmp);
 -+	} else {
 -+		*opts_buf = '\0';
 -+	}
 -+	_mntent.mnt_opts = opts_buf;	
 -+	_mntent.mnt_freq = _mntent.mnt_passno = 0;
 -+	return (&_mntent);
 -+}
 -+
 -+struct mntent *
 -+getmntent (FILE *fp)
 -+{
 -+	struct statfs *mntbuf;
 -+
 -+	if (pos == -1 || mntsize == -1)
 -+		mntsize = getmntinfo (&mntbuf, MNT_NOWAIT);
 -+
 -+	++pos;
 -+	if (pos == mntsize) {
 -+		pos = mntsize = -1;
 -+		return (NULL);
 -+	}
 -+
 -+	return (statfs_to_mntent (&mntbuf[pos]));
 -+}
 -+
 -+#endif /* HAVE_MNTENT_H */
 -diff -urN fam-oss-2.6.4/libfam/Client.c++ fam-oss-2.6.4-freebsd/libfam/Client.c++
 ---- fam-oss-2.6.4/libfam/Client.c++	Sat May 20 05:46:32 2000
 -+++ fam-oss-2.6.4-freebsd/libfam/Client.c++	Sat Mar 17 00:12:01 2001
 -@@ -20,6 +20,7 @@
 - //  with this program; if not, write the Free Software Foundation, Inc., 59
 - //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 - 
 -+#include <stdio.h>
 - #include <stdlib.h>
 - #include <unistd.h>
 - #include <netinet/in.h>
 -diff -urN fam-oss-2.6.4/libfam/fam.c++ fam-oss-2.6.4-freebsd/libfam/fam.c++
 ---- fam-oss-2.6.4/libfam/fam.c++	Sat May 20 05:46:32 2000
 -+++ fam-oss-2.6.4-freebsd/libfam/fam.c++	Sat Mar 17 00:12:43 2001
 -@@ -21,6 +21,7 @@
 - //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 - 
 - #include <sys/types.h>
 -+#include <rpc/rpc.h>
 - #include <sys/time.h>
 - #include <unistd.h>
 - #include <stdlib.h>
 -diff -urN fam-oss-2.6.4/test/test.c++ fam-oss-2.6.4-freebsd/test/test.c++
 ---- fam-oss-2.6.4/test/test.c++	Sat May 20 05:46:32 2000
 -+++ fam-oss-2.6.4-freebsd/test/test.c++	Sat Mar 17 18:39:23 2001
 -@@ -1,6 +1,7 @@
 - #include <sys/types.h>
 - #include <sys/time.h>
 - #include <stdio.h>
 -+#include <string.h>
 - #include <unistd.h>
 - #include <signal.h>
 - #include <errno.h>
 ---- fam-oss-2.6.4/acconfig.h	Sat May 20 05:46:31 2000
 -+++ fam-oss-2.6.4-freebsd/acconfig.h	Sun Mar 18 00:40:47 2001
 -@@ -44,6 +44,8 @@
 - **  Otherwise, we'll use MNTTYPE_NFS.  */
 - #undef HAVE_FSID_NFS2
 - 
 -+#undef HAVE_MNTENT_H
 -+
 - /* Define if we have MNTTYPE_NFS2 */
 - #define HAVE_MNTTYPE_NFS2 0
 - 
 Index: files/patch-libfam::Client.c++
 ===================================================================
 RCS file: files/patch-libfam::Client.c++
 diff -N files/patch-libfam::Client.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-libfam::Client.c++	7 Oct 2001 20:28:07 -0000
 @@ -0,0 +1,10 @@
 +--- libfam/Client.c++.orig	Fri May 19 23:46:32 2000
 ++++ libfam/Client.c++	Sun Oct  7 15:22:17 2001
 +@@ -20,6 +20,7 @@
 + //  with this program; if not, write the Free Software Foundation, Inc., 59
 + //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 + 
 ++#include <stdio.h>
 + #include <stdlib.h>
 + #include <unistd.h>
 + #include <netinet/in.h>
 Index: files/patch-libfam::Makefile.am
 ===================================================================
 RCS file: files/patch-libfam::Makefile.am
 diff -N files/patch-libfam::Makefile.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-libfam::Makefile.am	7 Oct 2001 21:28:53 -0000
 @@ -0,0 +1,8 @@
 +--- libfam/Makefile.am.orig	Fri May 19 23:46:32 2000
 ++++ libfam/Makefile.am	Sun Oct  7 16:28:34 2001
 +@@ -11,4 +11,4 @@
 + 
 + EXTRA_DIST = fam.sym
 + 
 +-CLEANFILES += ii_files/*.ii
 ++CLEANFILES = ii_files/*.ii
 Index: files/patch-libfam::fam.c++
 ===================================================================
 RCS file: files/patch-libfam::fam.c++
 diff -N files/patch-libfam::fam.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-libfam::fam.c++	7 Oct 2001 20:28:28 -0000
 @@ -0,0 +1,10 @@
 +--- libfam/fam.c++.orig	Fri May 19 23:46:32 2000
 ++++ libfam/fam.c++	Sun Oct  7 15:22:17 2001
 +@@ -21,6 +21,7 @@
 + //  Temple Place - Suite 330, Boston MA 02111-1307, USA.
 + 
 + #include <sys/types.h>
 ++#include <rpc/rpc.h>
 + #include <sys/time.h>
 + #include <unistd.h>
 + #include <stdlib.h>
 Index: files/patch-man::Makefile.am
 ===================================================================
 RCS file: files/patch-man::Makefile.am
 diff -N files/patch-man::Makefile.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-man::Makefile.am	23 Nov 2001 16:49:32 -0000
 @@ -0,0 +1,12 @@
 +--- man/Makefile.am.orig	Mon Oct 22 01:33:11 2001
 ++++ man/Makefile.am	Fri Nov 23 10:49:15 2001
 +@@ -1,5 +1,5 @@
 +-#  This is a little weird because fam.1m is generated from fam.1m.in
 ++#  This is a little weird because fam.8 is generated from fam.8.in
 + #  at the end of the configure script.
 +-man_MANS = fam.1m fam.3x
 +-EXTRA_DIST = fam.1m.in fam.3x
 +-CLEANFILES = fam.1m
 ++man_MANS = fam.8 fam.3
 ++EXTRA_DIST = fam.8.in fam.3
 ++CLEANFILES = fam.8
 Index: files/patch-man::fam.1m.in
 ===================================================================
 RCS file: files/patch-man::fam.1m.in
 diff -N files/patch-man::fam.1m.in
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-man::fam.1m.in	25 Nov 2001 22:12:56 -0000
 @@ -0,0 +1,76 @@
 +--- man/fam.1m.in.orig	Mon Oct 22 01:33:11 2001
 ++++ man/fam.1m.in	Sun Nov 25 16:09:29 2001
 +@@ -1,6 +1,6 @@
 +-.\"##  fam.1m.in
 ++.\"##  fam.8.in
 + .\"##
 +-.\"##  When configure.in generates fam.1m, lines starting with .\"##
 ++.\"##  When configure.in generates fam.8, lines starting with .\"##
 + .\"##  should be removed; when building on IRIX, lines starting with
 + .\"##  .\"IRIX should have that part removed (uncommenting the rest
 + .\"##  of the line).
 +@@ -9,13 +9,13 @@
 + .\"##  separate files.
 + .\"##
 + .nr X
 +-.if \nX=0 .ds x} fam 1M "Silicon Graphics" "\&"
 ++.if \nX=0 .ds x} fam 8 "Silicon Graphics" "\&"
 + .TH \*(x}
 + .SH NAME
 + fam \- file alteration monitor
 + .SH SYNOPSIS
 + .nf
 +-\f3/usr/etc/fam\f1 [ \f3\-f\f1 | \f3\-v\f1 | \f3\-d\f1 ] [ \f3\-l\f1 | \c
 ++\f3fam\f1 [ \f3\-f\f1 | \f3\-v\f1 | \f3\-d\f1 ] [ \f3\-l\f1 | \c
 + \f3\-t\f1 \f2NFS_polling_interval\f1 ] 
 + 	[ \f3\-T\f1 \f2idle_timeout\f1 ] [ \f3\-p\f1 \c
 + \f2program\f3.\f2version\f1 ] [ \f3\-L\f1 ] [ \f3-C\f1 ]
 +@@ -24,22 +24,13 @@
 + .SH DESCRIPTION
 + \f2fam\f1 is a server that tracks changes to the filesystem and
 + relays these changes to interested applications.
 +-Applications such as
 +-\f2fm\f1(1G) and \f2mailbox\f1(1) present an up-to-date view of the filesystem.
 +-In the absence of \f2fam\f1, these applications and others like them
 +-are forced to poll the filesystem to detect changes.
 +-\f2fam\f1 is
 +-more efficient.
 +-.P
 + Applications can request \f2fam\f1 to monitor any files or directories in
 + any filesystem.
 + When \f2fam\f1 detects changes to monitored files, it notifies
 + the appropriate application.
 + The FAM API provides a programmatic interface to \f2fam\f1; see
 +-.IR fam (3X).
 ++.IR fam (3).
 + .P
 +-\f2fam\f1 is informed of filesystem changes as they happen by the
 +-kernel through the \f2imon\f1(7M) pseudo device driver.
 + If asked to
 + monitor files on an NFS mounted filesystem, \f2fam\f1 tries to use
 + \f2fam\f1 on the NFS server to monitor files.
 +@@ -47,9 +38,9 @@
 + contact a remote \f2fam\f1, it polls the files instead.
 + \f2fam\f1 also polls special files.
 + .P
 +-Normally, \f2fam\f1 is started by \f2inetd\f1(1M).
 ++Normally, \f2fam\f1 is started by \f2inetd\f1(8).
 + It is registered with
 +-\f2portmap\f1(1M) as performing the sgi_fam service.
 ++\f2%%PORTMAP%%\f1(8) as performing the sgi_fam service.
 + .SH OPTIONS
 + .TP 26
 + \f3\-l\f1
 +@@ -196,9 +187,7 @@
 + XXX_FAM_CONF
 + .SH "SEE ALSO"
 + .\"IRIX fm(1G),
 +-inetd(1M),
 ++fam(3),
 ++inetd(8),
 + .\"IRIX mailbox(1),
 +-portmap(1M),
 +-fam(3X),
 +-imon(7M),
 +-stat(1M).
 ++%%PORTMAP%%(8).
 Index: files/patch-man::fam.3x
 ===================================================================
 RCS file: files/patch-man::fam.3x
 diff -N files/patch-man::fam.3x
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-man::fam.3x	23 Nov 2001 16:52:23 -0000
 @@ -0,0 +1,38 @@
 +--- man/fam.3x.orig	Mon Oct 22 01:33:11 2001
 ++++ man/fam.3x	Fri Nov 23 10:51:07 2001
 +@@ -1,9 +1,9 @@
 + '\"macro stdmacro
 +-.if n .pH g3x.fam @(#)fam	30.3 of 1/19/86
 ++.if n .pH g3.fam @(#)fam	30.3 of 1/19/86
 + .nr X
 +-.if \nX=0 .ds x} FAM 3X "Specialized Libraries" "\&"
 +-.if \nX=1 .ds x} FAM 3X "Specialized Libraries"
 +-.if \nX=2 .ds x} FAM 3X "" "\&"
 ++.if \nX=0 .ds x} FAM 3 "Specialized Libraries" "\&"
 ++.if \nX=1 .ds x} FAM 3 "Specialized Libraries"
 ++.if \nX=2 .ds x} FAM 3 "" "\&"
 + .if \nX=3 .ds x} FAM "" "" "\&"
 + .TH \*(x}
 + .SH NAME
 +@@ -65,10 +65,9 @@
 + .PP
 + .SH DESCRIPTION
 + \fIFAM\fP monitors files and directories, notifying interested
 +-applications of changes.  Routines for communicating with the fam(1M)
 ++applications of changes.  Routines for communicating with the fam(8)
 + server process are found in ``libfam.a'', which is loaded if the
 +-option ``-lfam'' is used with cc(1) or ld(1).  The library
 +-``libC.a'' (``-lC'') must also be specified.
 ++option ``-lfam'' is used with cc(1) or ld(1).
 + .PP
 + An application calls routines described here to establish a list of
 + files for \fIfam \fPto monitor.  \fIFam \fPgenerates events on a socket to
 +@@ -282,7 +281,7 @@
 + 
 + 
 + .SH SEE ALSO
 +-fam(1M).
 ++fam(8).
 + .SH BUGS
 + The FAMMoved event is not currently supported.
 + .PP
 Index: files/patch-support::Makefile.am
 ===================================================================
 RCS file: files/patch-support::Makefile.am
 diff -N files/patch-support::Makefile.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-support::Makefile.am	26 Nov 2001 00:39:03 -0000
 @@ -0,0 +1,10 @@
 +--- support/Makefile.am.orig	Mon Oct 22 01:33:11 2001
 ++++ support/Makefile.am	Sun Nov 25 18:38:28 2001
 +@@ -11,5 +11,5 @@
 + libsupport_a_DEPENDENCIES = @snprintf_o@ @foo_o@
 + libsupport_a_LIBADD       = @snprintf_o@ @foo_o@
 + 
 +-CLEANFILES += @MKDEPFILE@ ii_files/*.ii
 +-sinclude @MKDEPFILE@
 ++CLEANFILES = @MKDEPFILE@ ii_files/*.ii
 ++#sinclude @MKDEPFILE@
 Index: files/patch-test::Makefile.am
 ===================================================================
 RCS file: files/patch-test::Makefile.am
 diff -N files/patch-test::Makefile.am
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-test::Makefile.am	7 Oct 2001 21:29:41 -0000
 @@ -0,0 +1,8 @@
 +--- test/Makefile.am.orig	Fri May 19 23:46:32 2000
 ++++ test/Makefile.am	Sun Oct  7 16:29:21 2001
 +@@ -4,4 +4,4 @@
 + test_SOURCES = test.c++
 + test_LDADD = ../libfam/libfam.la
 + 
 +-CLEANFILES += ii_files/*.ii
 ++CLEANFILES = ii_files/*.ii
 Index: files/patch-test::test.c++
 ===================================================================
 RCS file: files/patch-test::test.c++
 diff -N files/patch-test::test.c++
 --- /dev/null	1 Jan 1970 00:00:00 -0000
 +++ files/patch-test::test.c++	7 Oct 2001 20:27:46 -0000
 @@ -0,0 +1,10 @@
 +--- test/test.c++.orig	Fri May 19 23:46:32 2000
 ++++ test/test.c++	Sun Oct  7 15:22:17 2001
 +@@ -1,6 +1,7 @@
 + #include <sys/types.h>
 + #include <sys/time.h>
 + #include <stdio.h>
 ++#include <string.h>
 + #include <unistd.h>
 + #include <signal.h>
 + #include <errno.h>

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200111260110.fAQ1A2f66458>