aboutsummaryrefslogtreecommitdiff
path: root/devel/fam
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2006-08-12 20:25:09 +0000
committerPav Lucistnik <pav@FreeBSD.org>2006-08-12 20:25:09 +0000
commita5a43c2a8ac6f151e286acaaaa1be9723fd0c4de (patch)
treef67256d5df7cb6a6fe231fd443bb8e130e721b95 /devel/fam
parentab2d61e614a31553039c3724722842fc0d05c182 (diff)
downloadports-a5a43c2a8ac6f151e286acaaaa1be9723fd0c4de.tar.gz
ports-a5a43c2a8ac6f151e286acaaaa1be9723fd0c4de.zip
Notes
Diffstat (limited to 'devel/fam')
-rw-r--r--devel/fam/Makefile23
-rw-r--r--devel/fam/distinfo9
-rw-r--r--devel/fam/files/mntent.h103
-rw-r--r--devel/fam/files/mntent_compat.c++266
-rw-r--r--devel/fam/files/patch-configure.in23
-rw-r--r--devel/fam/files/patch-fam-Scheduler.h14
-rw-r--r--devel/fam/files/patch-fam_Directory.c++11
-rw-r--r--devel/fam/files/patch-fam_DirectoryScanner.c++11
-rw-r--r--devel/fam/files/patch-fam_DirectoryScanner.h11
-rw-r--r--devel/fam/files/patch-fam_FileSystem.c++11
-rw-r--r--devel/fam/files/patch-fam_FileSystemTable.c++10
-rw-r--r--devel/fam/files/patch-fam_Makefile.am10
-rw-r--r--devel/fam/files/patch-fam_StringTable.h10
-rw-r--r--devel/fam/files/pkg-message.in (renamed from devel/fam/pkg-message)14
-rw-r--r--devel/fam/pkg-plist3
15 files changed, 306 insertions, 223 deletions
diff --git a/devel/fam/Makefile b/devel/fam/Makefile
index 14e26c94e5a7..6e727de6352d 100644
--- a/devel/fam/Makefile
+++ b/devel/fam/Makefile
@@ -6,24 +6,23 @@
#
PORTNAME= fam
-PORTVERSION= 2.6.9
-PORTREVISION= 6
+PORTVERSION= 2.6.10
CATEGORIES= devel
MASTER_SITES= ftp://oss.sgi.com/projects/fam/download/
-PATCH_SITES= ftp://oss.sgi.com/projects/fam/download/patches/
-PATCH_DIST_STRIP= -p1
-PATCHFILES= freebsd-mntent.patch # freebsd-build.patch
DIST_SUBDIR= ${PORTNAME}
-MAINTAINER= ports@FreeBSD.org
+MAINTAINER= ssedov@mbsd.msk.ru
COMMENT= A file alteration monitor
-CFLAGS+= -Wno-deprecated
+CFLAGS+= -Wno-deprecated
-USE_AUTOTOOLS= automake:15 autoconf:253
-CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
+USE_AUTOTOOLS= aclocal:19 automake:19 autoconf:259 libtool:15
+AUTOMAKE_ARGS= -c -a
USE_GMAKE= yes
-INSTALLS_SHLIB= yes
+USE_GNOME= gnometarget
+USE_LDCONFIG= yes
+ACLOCAL_ARGS= --acdir=${ACLOCAL_DIR} -I ${LOCALBASE}/share/aclocal
+SUB_FILES= pkg-message
MAN1= fam.1m
MAN3= fam.3x
@@ -35,11 +34,7 @@ pre-configure:
@${MV} ${WRKSRC}/Makefile.am ${WRKSRC}/Makefile.am.orig
@${SED} -e s/util// -e /SUBDIRS/q \
<${WRKSRC}/Makefile.am.orig >${WRKSRC}/Makefile.am
- @${RM} -f ${WRKSRC}/Makefile.am.orig
- @${RM} -f ${WRKSRC}/fam/mntent*
@${CP} ${FILESDIR}/mntent* ${WRKSRC}/fam
- @${REINPLACE_CMD} -e 's|$$lt_target|$$host|' \
- -e '/^_LT_AC_SHELL_INIT/d' ${WRKSRC}/aclocal.m4
post-install:
@${CAT} ${PKGMESSAGE}
diff --git a/devel/fam/distinfo b/devel/fam/distinfo
index b356bede551b..5562fa676e4f 100644
--- a/devel/fam/distinfo
+++ b/devel/fam/distinfo
@@ -1,6 +1,3 @@
-MD5 (fam/fam-2.6.9.tar.gz) = 8b647472152940b9789e649fa2734443
-SHA256 (fam/fam-2.6.9.tar.gz) = 5a19d8d6be0dd23c058e31debe0e6e7da479b321abf26017e7c28f12851eebb2
-SIZE (fam/fam-2.6.9.tar.gz) = 282627
-MD5 (fam/freebsd-mntent.patch) = d1509acc51463cc7d224ee9afb783e09
-SHA256 (fam/freebsd-mntent.patch) = 785e148691f74e5b640b06c388ed81fc2db83847770b882baa0ed2547a620a28
-SIZE (fam/freebsd-mntent.patch) = 11188
+MD5 (fam/fam-2.6.10.tar.gz) = 1c5a2ea659680bdd1e238d7828a857a7
+SHA256 (fam/fam-2.6.10.tar.gz) = 885ced3480aef3cee519a459a572e31cd2fd5e24bcd35b1d0c8833361699026e
+SIZE (fam/fam-2.6.10.tar.gz) = 321189
diff --git a/devel/fam/files/mntent.h b/devel/fam/files/mntent.h
index 24a574c8a579..078b246cd02e 100644
--- a/devel/fam/files/mntent.h
+++ b/devel/fam/files/mntent.h
@@ -1,67 +1,56 @@
-/* -*-C++-*-
-
- mntent.h
-
- Copyright (C) 2002 Alan Eldridge
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software Foundation,
- Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- $Id$
-
- 2002/09/08 alane@geeksrus.net
-*/
-
-#ifdef HAVE_MNTENT_H
+/*
+ * 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_
-
+#ifndef _MNTENT_H
+#define _MNTENT_H
#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sys/param.h>
-#include <sys/ucred.h>
-#include <sys/mount.h>
-#define MOUNTED "dummy"
-#define MNTTYPE_NFS "nfs"
+#define MOUNTED "dummy"
-const int MOPTSLEN (256 - (MNAMELEN * 2 + MFSNAMELEN + 2 * sizeof(int)));
+#define MNTTYPE_NFS "nfs"
struct mntent {
-public:
- char mnt_fsname[ MNAMELEN ];
- char mnt_dir[ MNAMELEN ];
- char mnt_type[ MFSNAMELEN ];
- char mnt_opts[ MOPTSLEN ];
- int mnt_freq, mnt_passno;
-private:
- void clear();
-public:
- mntent() {
- clear();
- }
- struct mntent *from_statfs(struct statfs *pst);
+ char *mnt_fsname;
+ char *mnt_dir;
+ char *mnt_type;
+ char *mnt_opts;
+ int mnt_freq;
+ int mnt_passno;
};
-FILE *setmntent(const char *szfn, char *szrw);
-struct mntent *getmntent(FILE *pf);
-char *hasmntopt(const struct mntent *pmnt, const char *szopt);
-int endmntent(FILE *pf);
+#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 /* not HAVE_MNTENT_H */
+#endif /* _MNTENT_H */
+#endif /* HAVE_MNTENT_H */
diff --git a/devel/fam/files/mntent_compat.c++ b/devel/fam/files/mntent_compat.c++
index 0675cd2ccf7f..6169936f2a46 100644
--- a/devel/fam/files/mntent_compat.c++
+++ b/devel/fam/files/mntent_compat.c++
@@ -1,156 +1,174 @@
-/* -*-C++-*-
-
- mntentemu.c++
-
- Copyright (C) 2002 Alan Eldridge
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software Foundation,
- Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
- $Id: mntent_compat.cc,v 1.3 2002/09/08 18:42:20 alane Exp $
-
- 2002/09/08 alane@geeksrus.net
-*/
-
-#ifndef HAVE_MNTENT_H
+/*
+ * Copyright (c) 1980, 1989, 1993, 1994
+ * The Regents of the University of California. All rights reserved.
+ * Copyright (c) 2001
+ * David Rufino <daverufino@btinternet.com>
+ * Copyright (c) 2006
+ * Stanislav Sedov <ssedov@mbsd.msk.ru>
+ *
+ * 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"
-
-#include <string>
-
-// globals (yuck, but easier for debugging)
-
-mntent G_mntent;
-int G_mntpos;
-int G_mntsize;
-bool G_mntfOpen = false;
-struct statfs *G_pmntstat = 0;
-
-// map option flags to names
-
-struct optmap {
- int fl;
- std::string st;
-};
-
-static struct optmap omap[] = {
- { MNT_SYNCHRONOUS, "sync" },
- { MNT_NOEXEC, "noexec" },
- { MNT_NOSUID, "nosuid" },
+#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;
+
+struct {
+ int m_flag;
+ const char *m_option;
+} mntoptions[] = {
+ { MNT_ASYNC, "async" },
+ { MNT_NOATIME, "noatime"},
+ { MNT_NOEXEC, "noexec"},
+ { MNT_NOSUID, "nosuid"},
+ { MNT_NOSYMFOLLOW, "nosymfollow"},
+ { MNT_SYNCHRONOUS, "sync"},
+ { MNT_UNION, "union"},
+ { MNT_NOCLUSTERR, "noclusterr"},
+ { MNT_NOCLUSTERW, "noclusterw"},
+ { MNT_SUIDDIR, "suiddir"},
+#ifdef MNT_SNAPSHOT
+ { MNT_SNAPSHOT, "snapshot"},
+#endif
+#ifdef MNT_MULTILABEL
+ { MNT_MULTILABEL, "multilabel"},
+#endif
+#ifdef MNT_ACLS
+ { MNT_ACLS, "acls"},
+#endif
#ifdef MNT_NODEV
- { MNT_NODEV, "nodev" },
+ { MNT_NODEV, "nodev"},
#endif
- { MNT_UNION, "union" },
- { MNT_ASYNC, "async" },
- { MNT_NOATIME, "noatime" },
- { MNT_NOCLUSTERR, "noclusterr" },
- { MNT_NOCLUSTERW, "noclusterw" },
- { MNT_NOSYMFOLLOW, "nosymfollow" },
- { MNT_SUIDDIR, "suiddir" },
- { 0, "noop" }
};
-// zap everything for clarity
+#define N_OPTS (sizeof(mntoptions) / sizeof(*mntoptions))
-void
-mntent::clear()
+char *
+hasmntopt (const struct mntent *mnt, const char *option)
{
- memset(mnt_fsname, 0, sizeof(mnt_fsname));
- memset(mnt_dir, 0, sizeof(mnt_dir));
- memset(mnt_type, 0, sizeof(mnt_type));
- memset(mnt_opts, 0, sizeof(mnt_opts));
- mnt_freq = mnt_passno = 0;
+ 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);
}
-// fake it from a statfs struct
-
-mntent *
-mntent::from_statfs(struct statfs *pst)
+static char *
+catopt (char *s0, const char *s1)
{
+ size_t newlen;
+ char *cp;
- clear();
- strcpy(mnt_fsname, pst->f_mntfromname);
- strcpy(mnt_dir, pst->f_mntonname);
- strcpy(mnt_type, pst->f_fstypename);
- mnt_freq = mnt_passno = 0;
+ if (s1 == NULL || *s1 == '\0')
+ return s0;
- std::string opts;
- int fl = pst->f_flags;
+ if (s0 != NULL) {
+ newlen = strlen(s0) + strlen(s1) + 1 + 1;
+ if ((cp = (char *)realloc(s0, newlen)) == NULL)
+ return (NULL);
- opts += (fl & MNT_RDONLY) ? "ro" : "rw";
- for (optmap *pmp = omap; pmp->fl != 0; pmp++) {
- if ((fl & pmp->fl) != 0) {
- opts += (" " + pmp->st);
- }
- }
- strcpy(mnt_opts, opts.c_str());
+ (void)strcat(cp, " ");
+ (void)strcat(cp, s1);
+ } else
+ cp = strdup(s1);
- return this;
+ return (cp);
}
-// "rewind" the mtab file
-FILE *
-setmntent(const char *, char *)
+static char *
+flags2opts (int flags)
{
- if (!G_mntfOpen) {
- G_mntfOpen = true;
- }
+ char *res = NULL;
+ int i;
- G_mntpos = 0;
- G_mntsize = getmntinfo(&G_pmntstat, MNT_NOWAIT);
+ res = catopt(res, (flags & MNT_RDONLY) ? "ro" : "rw");
- return reinterpret_cast<FILE *>(1);
+ for (i = 0; i < N_OPTS; i++)
+ if (flags & mntoptions[i].m_flag)
+ res = catopt(res, mntoptions[i].m_option);
+ return res;
}
-// return ptr to opt string if present
-
-char *
-hasmntopt(const mntent *pmnt, const char *szopt)
+static struct mntent *
+statfs_to_mntent (struct statfs *mntbuf)
{
- std::string opt(szopt);
- std::string mntopts(pmnt->mnt_opts);
-
- std::string::size_type pos = mntopts.find(opt);
- const char *szret = (pos == std::string::npos) ? "" : pmnt->mnt_opts + pos;
-
- return const_cast<char *>(szret);
+ 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);
}
-// get next mntent until all gone, then return 0
-
struct mntent *
-getmntent(FILE *)
+getmntent (FILE *fp)
{
- if (!G_mntfOpen) {
- return 0;
- } else if (G_mntpos < G_mntsize) {
- return G_mntent.from_statfs(G_pmntstat + G_mntpos++);
- } else {
- G_mntfOpen = false;
- return 0;
- }
-}
+ struct statfs *mntbuf;
-// "close" the mtab file
+ if (pos == -1 || mntsize == -1)
+ mntsize = getmntinfo (&mntbuf, MNT_NOWAIT);
-int
-endmntent(FILE *)
-{
- G_mntfOpen = false;
- return 0;
-}
+ ++pos;
+ if (pos == mntsize) {
+ pos = mntsize = -1;
+ return (NULL);
+ }
-#endif /* ifndef HAVE_MNTENT_H */
+ return (statfs_to_mntent (&mntbuf[pos]));
+}
diff --git a/devel/fam/files/patch-configure.in b/devel/fam/files/patch-configure.in
new file mode 100644
index 000000000000..944540a97b85
--- /dev/null
+++ b/devel/fam/files/patch-configure.in
@@ -0,0 +1,23 @@
+--- configure.in.orig Fri Aug 11 22:23:19 2006
++++ configure.in Fri Aug 11 22:24:34 2006
+@@ -308,11 +308,6 @@
+ 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
+ dnl Test for bindresvport() prototype.
+ dnl
+@@ -563,8 +558,6 @@
+ man/fam.1m
+ support/Makefile
+ test/Makefile
+- util/Makefile
+- util/editconf/Makefile
+ )
+
+ dnl
diff --git a/devel/fam/files/patch-fam-Scheduler.h b/devel/fam/files/patch-fam-Scheduler.h
deleted file mode 100644
index 97fcc700de4e..000000000000
--- a/devel/fam/files/patch-fam-Scheduler.h
+++ /dev/null
@@ -1,14 +0,0 @@
---- fam/Scheduler.h~ Tue Jul 16 02:14:41 2002
-+++ fam/Scheduler.h Fri Sep 6 03:46:29 2002
-@@ -105,7 +105,11 @@
- // for the corresponding I/O type.
-
- struct IOTypeInfo {
-+#if defined(__FreeBSD__) && defined(__GNUC__) && (__GNUC__ > 2)
-+ FDInfo::FDIOHandler FDInfo::*iotype;
-+#else
- FDInfo::FDIOHandler FDInfo::*const iotype;
-+#endif
- unsigned int nbitsset; // number of bits set in fds
- fd_set fds;
- IOTypeInfo(FDInfo::FDIOHandler FDInfo::* a_iotype) :
diff --git a/devel/fam/files/patch-fam_Directory.c++ b/devel/fam/files/patch-fam_Directory.c++
new file mode 100644
index 000000000000..656b780d766a
--- /dev/null
+++ b/devel/fam/files/patch-fam_Directory.c++
@@ -0,0 +1,11 @@
+--- fam/Directory.c++.orig Tue Apr 15 10:21:29 2003
++++ fam/Directory.c++ Sat Aug 12 00:10:16 2006
+@@ -26,7 +26,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <stdio.h>
+-#include <sys/dir.h>
++#include <dirent.h>
+ #include <sys/stat.h>
+ #include <sys/wait.h>
+ #include <unistd.h>
diff --git a/devel/fam/files/patch-fam_DirectoryScanner.c++ b/devel/fam/files/patch-fam_DirectoryScanner.c++
new file mode 100644
index 000000000000..f34a00b49327
--- /dev/null
+++ b/devel/fam/files/patch-fam_DirectoryScanner.c++
@@ -0,0 +1,11 @@
+--- fam/DirectoryScanner.c++.orig Sat Aug 12 00:12:06 2006
++++ fam/DirectoryScanner.c++ Sat Aug 12 00:13:23 2006
+@@ -100,7 +100,7 @@
+
+ while (dir && ready)
+ {
+- struct direct *dp = readdir(dir);
++ struct dirent *dp = readdir(dir);
+ if (dp == NULL)
+ { closedir(dir);
+ dir = NULL;
diff --git a/devel/fam/files/patch-fam_DirectoryScanner.h b/devel/fam/files/patch-fam_DirectoryScanner.h
new file mode 100644
index 000000000000..8bccdcdda9ff
--- /dev/null
+++ b/devel/fam/files/patch-fam_DirectoryScanner.h
@@ -0,0 +1,11 @@
+--- fam/DirectoryScanner.h.orig Tue Apr 15 10:21:30 2003
++++ fam/DirectoryScanner.h Sat Aug 12 00:10:29 2006
+@@ -27,7 +27,7 @@
+
+ #include <stddef.h>
+ #include <sys/types.h>
+-#include <sys/dir.h>
++#include <dirent.h>
+
+ #include "Event.h"
+
diff --git a/devel/fam/files/patch-fam_FileSystem.c++ b/devel/fam/files/patch-fam_FileSystem.c++
new file mode 100644
index 000000000000..f1df752f19a3
--- /dev/null
+++ b/devel/fam/files/patch-fam_FileSystem.c++
@@ -0,0 +1,11 @@
+--- fam/FileSystem.c++.orig Fri Aug 11 22:26:04 2006
++++ fam/FileSystem.c++ Fri Aug 11 22:26:26 2006
+@@ -22,7 +22,7 @@
+
+ #include "FileSystem.h"
+
+-#include <mntent.h>
++#include "mntent.h"
+ #include <string.h>
+
+ #include "Event.h"
diff --git a/devel/fam/files/patch-fam_FileSystemTable.c++ b/devel/fam/files/patch-fam_FileSystemTable.c++
new file mode 100644
index 000000000000..6759e9a32980
--- /dev/null
+++ b/devel/fam/files/patch-fam_FileSystemTable.c++
@@ -0,0 +1,10 @@
+--- fam/FileSystemTable.c++.orig Fri Aug 11 22:27:15 2006
++++ fam/FileSystemTable.c++ Fri Aug 11 22:28:29 2006
+@@ -255,7 +255,6 @@
+ // create_fs_by_name initializes our "root" member variable.
+ if (!fs_by_name)
+ { create_fs_by_name();
+- mtab_watcher = new InternalClient(mtab_name, mtab_event_handler, NULL);
+ }
+
+ cr.become_user();
diff --git a/devel/fam/files/patch-fam_Makefile.am b/devel/fam/files/patch-fam_Makefile.am
new file mode 100644
index 000000000000..a09277096b21
--- /dev/null
+++ b/devel/fam/files/patch-fam_Makefile.am
@@ -0,0 +1,10 @@
+--- fam/Makefile.am.orig Fri Aug 11 22:29:03 2006
++++ fam/Makefile.am Fri Aug 11 22:29:18 2006
+@@ -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 --git a/devel/fam/files/patch-fam_StringTable.h b/devel/fam/files/patch-fam_StringTable.h
new file mode 100644
index 000000000000..b13f3b868cb6
--- /dev/null
+++ b/devel/fam/files/patch-fam_StringTable.h
@@ -0,0 +1,10 @@
+--- fam/StringTable.h.orig Fri Aug 11 22:29:55 2006
++++ fam/StringTable.h Fri Aug 11 22:30:12 2006
+@@ -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 --git a/devel/fam/pkg-message b/devel/fam/files/pkg-message.in
index 1e16a0923c09..5c0c32f5887e 100644
--- a/devel/fam/pkg-message
+++ b/devel/fam/files/pkg-message.in
@@ -3,17 +3,17 @@
1. In order to run this port, please add the following line to /etc/rpc if
it is not already there:
-==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<==
+--------------------------------------------------------------------
sgi_fam 391002
-==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<==
+--------------------------------------------------------------------
2. To run fam from inetd (the recommended method), then please add the
following lines to /etc/inetd.conf if they are not already there:
-==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<==
+--------------------------------------------------------------------
# FAM: File Alteration Monitor [devel/fam]
-sgi_fam/1-2 stream rpc/tcp wait root /usr/local/bin/fam fam
-==8<====8<====8<====8<====8<====8<====8<====8<====8<====8<==
+sgi_fam/1-2 stream rpc/tcp wait root %%LOCALBASE%%/bin/fam fam
+--------------------------------------------------------------------
After modifying /etc/inetd.conf, you must (as root) run:
@@ -25,7 +25,7 @@ entry to /etc/rc.conf:
For 4.x:
Add portmap_enable="YES" and either reboot or run /usr/sbin/portmap.
-For 5.x:
-Add rpcbind_enable="YES" and either reboot or run /usr/sbin/rpcbind.
+For 5.x and later:
+Add rpcbind_enable="YES" and either reboot or run /etc/rc.d/rpcbind start.
************************************************************************
diff --git a/devel/fam/pkg-plist b/devel/fam/pkg-plist
index dd261a6553e8..fd180a8969a6 100644
--- a/devel/fam/pkg-plist
+++ b/devel/fam/pkg-plist
@@ -5,4 +5,5 @@ lib/libfam.a
lib/libfam.la
lib/libfam.so
lib/libfam.so.0
-@unexec rm -f %D/etc/rc.d/fam.sh || true
+@comment For non-standart prefixes
+@unexec rm -f %D/libdata/ldconfig/fam || true