Sun Nov 9 14:32:28 2008 UTC ()
modified patch to apply to OpenBSD, too.


(schwarz)
diff -r1.29 -r1.30 pkgsrc/sysutils/fam/distinfo
diff -r1.12 -r1.13 pkgsrc/sysutils/fam/patches/patch-ap

cvs diff -r1.29 -r1.30 pkgsrc/sysutils/fam/distinfo (expand / switch to unified diff)

--- pkgsrc/sysutils/fam/distinfo 2007/12/28 15:00:45 1.29
+++ pkgsrc/sysutils/fam/distinfo 2008/11/09 14:32:28 1.30
@@ -1,34 +1,34 @@ @@ -1,34 +1,34 @@
1$NetBSD: distinfo,v 1.29 2007/12/28 15:00:45 tron Exp $ 1$NetBSD: distinfo,v 1.30 2008/11/09 14:32:28 schwarz Exp $
2 2
3SHA1 (fam-2.7.0.tar.gz) = 6c2316f02acf89a41c42ffc3d7fd9cf5eada83a8 3SHA1 (fam-2.7.0.tar.gz) = 6c2316f02acf89a41c42ffc3d7fd9cf5eada83a8
4RMD160 (fam-2.7.0.tar.gz) = 1895b578d6a141c36d5bee4e3fbbc2a298a91430 4RMD160 (fam-2.7.0.tar.gz) = 1895b578d6a141c36d5bee4e3fbbc2a298a91430
5Size (fam-2.7.0.tar.gz) = 301974 bytes 5Size (fam-2.7.0.tar.gz) = 301974 bytes
6SHA1 (patch-aa) = d9dd9b6faf4ccd89c41404b74fb577ac327fed05 6SHA1 (patch-aa) = d9dd9b6faf4ccd89c41404b74fb577ac327fed05
7SHA1 (patch-ab) = dcc2820c754a6670c1c6da0380cac79c6b88f280 7SHA1 (patch-ab) = dcc2820c754a6670c1c6da0380cac79c6b88f280
8SHA1 (patch-ac) = 676966b0372780af4ee5536276132a04dd038863 8SHA1 (patch-ac) = 676966b0372780af4ee5536276132a04dd038863
9SHA1 (patch-ad) = 19364c8dd3f887a59f41556206c8c2d179577932 9SHA1 (patch-ad) = 19364c8dd3f887a59f41556206c8c2d179577932
10SHA1 (patch-ae) = aa8fed958555d6870367fd202a6117ddcb5a1da9 10SHA1 (patch-ae) = aa8fed958555d6870367fd202a6117ddcb5a1da9
11SHA1 (patch-af) = 5868f44d29c31533bdb012213022e814d3fc3995 11SHA1 (patch-af) = 5868f44d29c31533bdb012213022e814d3fc3995
12SHA1 (patch-ag) = 3300a1cd565f9edaea3c334a9e278185efbcb7a6 12SHA1 (patch-ag) = 3300a1cd565f9edaea3c334a9e278185efbcb7a6
13SHA1 (patch-ah) = dc8ec60631b57668fcef0b296efe3e271cb7fcae 13SHA1 (patch-ah) = dc8ec60631b57668fcef0b296efe3e271cb7fcae
14SHA1 (patch-ai) = b80aafbb3849fc8c828b6829d8975b910e4d0fd5 14SHA1 (patch-ai) = b80aafbb3849fc8c828b6829d8975b910e4d0fd5
15SHA1 (patch-aj) = 39391961fd7929d6a5fb49ecb492585cb821afaa 15SHA1 (patch-aj) = 39391961fd7929d6a5fb49ecb492585cb821afaa
16SHA1 (patch-ak) = 48ddfcf9b7562832402a464437ca485249d371a1 16SHA1 (patch-ak) = 48ddfcf9b7562832402a464437ca485249d371a1
17SHA1 (patch-al) = e0b4c3ca447f42573def07e8b47209ec6e6ad016 17SHA1 (patch-al) = e0b4c3ca447f42573def07e8b47209ec6e6ad016
18SHA1 (patch-am) = 4fa488940675c5283806819288f7674f4634e038 18SHA1 (patch-am) = 4fa488940675c5283806819288f7674f4634e038
19SHA1 (patch-an) = 7aa54fb1f90e3b2eb767d41fd842f7f4a0561b81 19SHA1 (patch-an) = 7aa54fb1f90e3b2eb767d41fd842f7f4a0561b81
20SHA1 (patch-ao) = 161160f121e9338e807bfe0c5df6cf14457fec62 20SHA1 (patch-ao) = 161160f121e9338e807bfe0c5df6cf14457fec62
21SHA1 (patch-ap) = 0294142889040d4f39bb94216007e70440835cef 21SHA1 (patch-ap) = c30ed27c038ef23da313df0a45f81401b4b9ae19
22SHA1 (patch-aq) = a54ba100b779fa13b35c962ba734ee11e093cb28 22SHA1 (patch-aq) = a54ba100b779fa13b35c962ba734ee11e093cb28
23SHA1 (patch-ar) = 37a8fe2e70d4cbc669a0c853b3404d8c0354235a 23SHA1 (patch-ar) = 37a8fe2e70d4cbc669a0c853b3404d8c0354235a
24SHA1 (patch-as) = d82bd15cfa04e52513e2b052f4e429d2133635f1 24SHA1 (patch-as) = d82bd15cfa04e52513e2b052f4e429d2133635f1
25SHA1 (patch-at) = 209f89cefac326e6c1b99bec4622ba0d6eabe1e4 25SHA1 (patch-at) = 209f89cefac326e6c1b99bec4622ba0d6eabe1e4
26SHA1 (patch-au) = 6bd507eb448b3fd126042759a3b6f70335401c5b 26SHA1 (patch-au) = 6bd507eb448b3fd126042759a3b6f70335401c5b
27SHA1 (patch-av) = e79813d88ec48a886688539da34150c5bd229a0a 27SHA1 (patch-av) = e79813d88ec48a886688539da34150c5bd229a0a
28SHA1 (patch-aw) = 9e5de9617e6cd59644294695d0ea79427b521ba0 28SHA1 (patch-aw) = 9e5de9617e6cd59644294695d0ea79427b521ba0
29SHA1 (patch-ax) = c63bf7f2bff7cb9e3bc4c1c6c474a398b01eafcc 29SHA1 (patch-ax) = c63bf7f2bff7cb9e3bc4c1c6c474a398b01eafcc
30SHA1 (patch-ay) = 081b4bc7cf25a8e30b3680b6df7599570ea0db86 30SHA1 (patch-ay) = 081b4bc7cf25a8e30b3680b6df7599570ea0db86
31SHA1 (patch-az) = 13901fdef8c13318d585e36820c5e0aa4c28f889 31SHA1 (patch-az) = 13901fdef8c13318d585e36820c5e0aa4c28f889
32SHA1 (patch-ba) = 2f41331994a56eb70364beab70d40ac0bbd1b050 32SHA1 (patch-ba) = 2f41331994a56eb70364beab70d40ac0bbd1b050
33SHA1 (patch-bb) = aef31edd9715c8aa0be2f02ebe663bad30e0791a 33SHA1 (patch-bb) = aef31edd9715c8aa0be2f02ebe663bad30e0791a
34SHA1 (patch-bc) = 6265e9739013a5303aa98173a6792df924c4c964 34SHA1 (patch-bc) = 6265e9739013a5303aa98173a6792df924c4c964

cvs diff -r1.12 -r1.13 pkgsrc/sysutils/fam/patches/patch-ap (expand / switch to unified diff)

--- pkgsrc/sysutils/fam/patches/patch-ap 2007/07/08 22:22:29 1.12
+++ pkgsrc/sysutils/fam/patches/patch-ap 2008/11/09 14:32:28 1.13
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1$NetBSD: patch-ap,v 1.12 2007/07/08 22:22:29 minskim Exp $ 1$NetBSD: patch-ap,v 1.13 2008/11/09 14:32:28 schwarz Exp $
2 2
3--- src/mntent_compat.c++.orig Sun Jul 8 08:16:38 2007 3--- src/mntent_compat.c++.orig Sun Jul 8 08:16:38 2007
4+++ src/mntent_compat.c++ 4+++ src/mntent_compat.c++
5@@ -0,0 +1,193 @@ 5@@ -0,0 +1,193 @@
6+/* 6+/*
7+ * Copyright (c) 1980, 1989, 1993, 1994 7+ * Copyright (c) 1980, 1989, 1993, 1994
8+ * The Regents of the University of California. All rights reserved. 8+ * The Regents of the University of California. All rights reserved.
9+ * Copyright (c) 2001 9+ * Copyright (c) 2001
10+ * David Rufino <daverufino@btinternet.com> 10+ * David Rufino <daverufino@btinternet.com>
11+ * 11+ *
12+ * Redistribution and use in source and binary forms, with or without 12+ * Redistribution and use in source and binary forms, with or without
13+ * modification, are permitted provided that the following conditions 13+ * modification, are permitted provided that the following conditions
14+ * are met: 14+ * are met:
@@ -38,27 +38,27 @@ $NetBSD: patch-ap,v 1.12 2007/07/08 22:2 @@ -38,27 +38,27 @@ $NetBSD: patch-ap,v 1.12 2007/07/08 22:2
38+ * SUCH DAMAGE. 38+ * SUCH DAMAGE.
39+ */ 39+ */
40+ 40+
41+/* most of this was ripped from the mount(3) source */ 41+/* most of this was ripped from the mount(3) source */
42+ 42+
43+#include "config.h" 43+#include "config.h"
44+#include "fam-mntent.h" 44+#include "fam-mntent.h"
45+#if !defined(HAVE_MNTENT_H) && !defined(HAVE_SYS_MNTTAB_H) 45+#if !defined(HAVE_MNTENT_H) && !defined(HAVE_SYS_MNTTAB_H)
46+#include <stdlib.h> 46+#include <stdlib.h>
47+#include <string.h> 47+#include <string.h>
48+#include <sys/param.h> 48+#include <sys/param.h>
49+#include <sys/ucred.h> 49+#include <sys/ucred.h>
50+#include <sys/mount.h> 50+#include <sys/mount.h>
51+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) 51+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) && !defined(__OpenBSD__)
52+# include <sys/statvfs.h> 52+# include <sys/statvfs.h>
53+#endif 53+#endif
54+ 54+
55+static int pos = -1; 55+static int pos = -1;
56+static int mntsize = -1; 56+static int mntsize = -1;
57+static struct mntent _mntent; 57+static struct mntent _mntent;
58+ 58+
59+char * 59+char *
60+hasmntopt (const struct mntent *mnt, const char *option) 60+hasmntopt (const struct mntent *mnt, const char *option)
61+{ 61+{
62+ int found; 62+ int found;
63+ char *opt, *optbuf; 63+ char *opt, *optbuf;
64+ 64+
@@ -136,58 +136,58 @@ $NetBSD: patch-ap,v 1.12 2007/07/08 22:2 @@ -136,58 +136,58 @@ $NetBSD: patch-ap,v 1.12 2007/07/08 22:2
136+ if (flags & MNT_SYMPERM) res = catopt(res, "symperm"); 136+ if (flags & MNT_SYMPERM) res = catopt(res, "symperm");
137+#endif 137+#endif
138+#ifdef MNT_NODEVMTIME 138+#ifdef MNT_NODEVMTIME
139+ if (flags & MNT_NODEVMTIME) res = catopt(res, "nodevmtime"); 139+ if (flags & MNT_NODEVMTIME) res = catopt(res, "nodevmtime");
140+#endif 140+#endif
141+#ifdef MNT_SOFTDEP 141+#ifdef MNT_SOFTDEP
142+ if (flags & MNT_SOFTDEP) res = catopt(res, "softdep"); 142+ if (flags & MNT_SOFTDEP) res = catopt(res, "softdep");
143+#endif 143+#endif
144+ 144+
145+ return res; 145+ return res;
146+} 146+}
147+ 147+
148+static struct mntent * 148+static struct mntent *
149+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) 149+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) && !defined(__OpenBSD__)
150+statfs_to_mntent (struct statvfs *mntbuf) 150+statfs_to_mntent (struct statvfs *mntbuf)
151+#else 151+#else
152+statfs_to_mntent (struct statfs *mntbuf) 152+statfs_to_mntent (struct statfs *mntbuf)
153+#endif 153+#endif
154+{ 154+{
155+ static char opts_buf[40], *tmp; 155+ static char opts_buf[40], *tmp;
156+  156+
157+ _mntent.mnt_fsname = mntbuf->f_mntfromname; 157+ _mntent.mnt_fsname = mntbuf->f_mntfromname;
158+ _mntent.mnt_dir = mntbuf->f_mntonname; 158+ _mntent.mnt_dir = mntbuf->f_mntonname;
159+ _mntent.mnt_type = mntbuf->f_fstypename; 159+ _mntent.mnt_type = mntbuf->f_fstypename;
160+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) 160+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) && !defined(__OpenBSD__)
161+ tmp = flags2opts (mntbuf->f_flag); 161+ tmp = flags2opts (mntbuf->f_flag);
162+#else 162+#else
163+ tmp = flags2opts (mntbuf->f_flags); 163+ tmp = flags2opts (mntbuf->f_flags);
164+#endif 164+#endif
165+ if (tmp) { 165+ if (tmp) {
166+ opts_buf[sizeof(opts_buf)-1] = '\0'; 166+ opts_buf[sizeof(opts_buf)-1] = '\0';
167+ strncpy (opts_buf, tmp, sizeof(opts_buf)-1); 167+ strncpy (opts_buf, tmp, sizeof(opts_buf)-1);
168+ free (tmp); 168+ free (tmp);
169+ } else { 169+ } else {
170+ *opts_buf = '\0'; 170+ *opts_buf = '\0';
171+ } 171+ }
172+ _mntent.mnt_opts = opts_buf;  172+ _mntent.mnt_opts = opts_buf;
173+ _mntent.mnt_freq = _mntent.mnt_passno = 0; 173+ _mntent.mnt_freq = _mntent.mnt_passno = 0;
174+ return (&_mntent); 174+ return (&_mntent);
175+} 175+}
176+ 176+
177+struct mntent * 177+struct mntent *
178+getmntent (FILE *fp) 178+getmntent (FILE *fp)
179+{ 179+{
180+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) 180+#if defined(HAVE_SYS_STATVFS_H) && !defined(__APPLE__) && !defined(__DragonFly__) && !defined(__FreeBSD__) && !defined(__OpenBSD__)
181+ static struct statvfs *mntbuf; 181+ static struct statvfs *mntbuf;
182+#else 182+#else
183+ static struct statfs *mntbuf; 183+ static struct statfs *mntbuf;
184+#endif 184+#endif
185+ 185+
186+ if (pos == -1 || mntsize == -1) 186+ if (pos == -1 || mntsize == -1)
187+ mntsize = getmntinfo (&mntbuf, MNT_NOWAIT); 187+ mntsize = getmntinfo (&mntbuf, MNT_NOWAIT);
188+ 188+
189+ ++pos; 189+ ++pos;
190+ if (pos == mntsize) { 190+ if (pos == mntsize) {
191+ pos = mntsize = -1; 191+ pos = mntsize = -1;
192+ return (NULL); 192+ return (NULL);
193+ } 193+ }