summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authortron <tron@pkgsrc.org>2004-04-26 17:39:00 +0000
committertron <tron@pkgsrc.org>2004-04-26 17:39:00 +0000
commit6f8880c048023e0a163f85686b3630b4e23ccecf (patch)
tree47cb5abcddc50740b6832b72d6f63610e0e09480 /net
parent42852ea44c2b4e85e6bd54bc9b9bb10bda00f4d9 (diff)
downloadpkgsrc-6f8880c048023e0a163f85686b3630b4e23ccecf.tar.gz
Make this build under NetBSD 2.0D and above with statvfs(2).
Diffstat (limited to 'net')
-rw-r--r--net/net-snmp/distinfo4
-rw-r--r--net/net-snmp/patches/patch-ag18
-rw-r--r--net/net-snmp/patches/patch-ah31
3 files changed, 52 insertions, 1 deletions
diff --git a/net/net-snmp/distinfo b/net/net-snmp/distinfo
index 38df082f8f4..d67a029cfc9 100644
--- a/net/net-snmp/distinfo
+++ b/net/net-snmp/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.8 2004/04/22 16:50:02 christos Exp $
+$NetBSD: distinfo,v 1.9 2004/04/26 17:39:00 tron Exp $
SHA1 (net-snmp-5.0.9.tar.gz) = bb27bdf38da96833a3fa55f8c6a14732ab2c1991
Size (net-snmp-5.0.9.tar.gz) = 2345822 bytes
@@ -8,3 +8,5 @@ SHA1 (patch-ac) = 23696f87cf5669e52ca9c70d4a7f30f649574083
SHA1 (patch-ad) = 947bc9d8d6190584e9c7f93c2b4aeda63fd5139c
SHA1 (patch-ae) = efc77e7985e9ac44c99e35015e2be55b0601dd4e
SHA1 (patch-af) = 83e3e7f27865d2423b03fc1d967319bc104c877d
+SHA1 (patch-ag) = 6d07febd92597d1d817e3c1960ce9afcc75a6906
+SHA1 (patch-ah) = 9acc8c432c61e071257c24e2041a23b63f81cfe2
diff --git a/net/net-snmp/patches/patch-ag b/net/net-snmp/patches/patch-ag
new file mode 100644
index 00000000000..ea48665aab2
--- /dev/null
+++ b/net/net-snmp/patches/patch-ag
@@ -0,0 +1,18 @@
+$NetBSD: patch-ag,v 1.1 2004/04/26 17:39:00 tron Exp $
+
+--- agent/mibgroup/host/hr_storage.c.orig 2002-12-19 16:07:30.000000000 +0100
++++ agent/mibgroup/host/hr_storage.c 2004-04-26 19:10:23.000000000 +0200
+@@ -148,6 +148,13 @@
+ #define HRFS_mount mnt_mountp
+ #define HRFS_statfs statvfs
+
++#elif defined(HAVE_STATVFS) && defined(__NetBSD__)
++
++extern struct statvfs *HRFS_entry;
++extern int fscount;
++#define HRFS_statfs statvfs
++#define HRFS_mount f_mntonname
++
+ #elif defined(HAVE_STATVFS)
+
+ extern struct mntent *HRFS_entry;
diff --git a/net/net-snmp/patches/patch-ah b/net/net-snmp/patches/patch-ah
new file mode 100644
index 00000000000..3ab558716ed
--- /dev/null
+++ b/net/net-snmp/patches/patch-ah
@@ -0,0 +1,31 @@
+$NetBSD: patch-ah,v 1.1 2004/04/26 17:39:00 tron Exp $
+
+--- agent/mibgroup/host/hr_filesys.c.orig 2003-02-28 19:17:35.000000000 +0100
++++ agent/mibgroup/host/hr_filesys.c 2004-04-26 19:31:03.000000000 +0200
+@@ -85,6 +85,15 @@
+ #define HRFS_type mnt_fstype
+ #define HRFS_statfs statvfs
+
++#elif defined(HAVE_STATVFS) && defined(__NetBSD__)
++
++static struct statvfs *fsstats = NULL;
++struct statvfs *HRFS_entry;
++static int fscount;
++#define HRFS_mount f_mntonname
++#define HRFS_name f_mntfromname
++#define HRFS_statfs statvfs
++#define HRFS_type f_fstypename
+ #elif defined(HAVE_GETFSSTAT)
+ static struct statfs *fsstats = 0;
+ static int fscount;
+@@ -447,7 +456,9 @@
+ return (u_char *) fsys_type_id;
+
+ case HRFSYS_ACCESS:
+-#if HAVE_GETFSSTAT
++#if defined(HAVE_STATVFS) && defined(__NetBSD__)
++ long_return = HRFS_entry->f_flag & MNT_RDONLY ? 2 : 1;
++#elif defined(HAVE_GETFSSTAT)
+ long_return = HRFS_entry->f_flags & MNT_RDONLY ? 2 : 1;
+ #elif defined(cygwin)
+ long_return = 1;