summaryrefslogtreecommitdiff
path: root/devel/libstatgrab
diff options
context:
space:
mode:
Diffstat (limited to 'devel/libstatgrab')
-rw-r--r--devel/libstatgrab/DESCR7
-rw-r--r--devel/libstatgrab/Makefile43
-rw-r--r--devel/libstatgrab/PLIST32
-rw-r--r--devel/libstatgrab/buildlink3.mk18
-rw-r--r--devel/libstatgrab/distinfo6
-rw-r--r--devel/libstatgrab/patches/patch-aa13
-rw-r--r--devel/libstatgrab/patches/patch-ab17
7 files changed, 136 insertions, 0 deletions
diff --git a/devel/libstatgrab/DESCR b/devel/libstatgrab/DESCR
new file mode 100644
index 00000000000..a19732546c7
--- /dev/null
+++ b/devel/libstatgrab/DESCR
@@ -0,0 +1,7 @@
+The libstatgrab library provides an easy to use interface for
+accessing system statistics and information. Available statistics
+include CPU, Load, Memory, Swap, Disk I/O, and Network I/O.
+
+Also part of the package are two tools; saidar provides a curses-based
+interface to viewing live system statistics, and statgrab is a
+sysctl-like interface to the statistics.
diff --git a/devel/libstatgrab/Makefile b/devel/libstatgrab/Makefile
new file mode 100644
index 00000000000..74c82ff34e5
--- /dev/null
+++ b/devel/libstatgrab/Makefile
@@ -0,0 +1,43 @@
+# $NetBSD: Makefile,v 1.1.1.1 2004/05/20 20:48:57 xtraeme Exp $
+
+DISTNAME= libstatgrab-0.10
+CATEGORIES= devel
+MASTER_SITES= ftp://ftp.mirror.ac.uk/sites/ftp.i-scream.org/pub/i-scream/libstatgrab/ \
+ http://www.mirror.ac.uk/sites/ftp.i-scream.org/pub/i-scream/libstatgrab/ \
+ ftp://ftp.i-scream.org/pub/i-scream/libstatgrab/ \
+ http://www.i-scream.org/pub/i-scream/libstatgrab/
+
+MAINTAINER= tim@bishnet.net
+HOMEPAGE= http://www.i-scream.org/libstatgrab/
+COMMENT= Provides a useful interface to system statistics
+
+GNU_CONFIGURE= yes
+USE_LIBTOOL= yes
+USE_BUILDLINK3= yes
+
+PKGCONFIG_OVERRIDE= libstatgrab.pc.in
+
+CONFIGURE_ARGS+= --disable-examples
+
+.include "../../mk/bsd.prefs.mk"
+
+BUILD_DEFS+= WITHOUT_STATGRAB
+BUILD_DEFS+= WITHOUT_SAIDAR
+
+.if defined(WITHOUT_STATGRAB)
+CONFIGURE_ARGS+= --disable-statgrab
+PLIST_SUBST+= STATGRAB="@comment "
+.else
+PLIST_SUBST+= STATGRAB=""
+.endif
+
+.if defined(WITHOUT_SAIDAR)
+CONFIGURE_ARGS+= --disable-saidar
+PLIST_SUBST+= SAIDAR="@comment "
+.else
+PLIST_SUBST+= SAIDAR=""
+.include "../../devel/ncurses/buildlink3.mk"
+.endif
+
+.include "../../devel/pkgconfig/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/devel/libstatgrab/PLIST b/devel/libstatgrab/PLIST
new file mode 100644
index 00000000000..50c730f3691
--- /dev/null
+++ b/devel/libstatgrab/PLIST
@@ -0,0 +1,32 @@
+@comment $NetBSD: PLIST,v 1.1.1.1 2004/05/20 20:48:58 xtraeme Exp $
+${SAIDAR}bin/saidar
+${STATGRAB}bin/statgrab
+${STATGRAB}bin/statgrab-make-mrtg-config
+${STATGRAB}bin/statgrab-make-mrtg-index
+include/statgrab.h
+include/statgrab_deprecated.h
+lib/libstatgrab.a
+lib/libstatgrab.la
+lib/libstatgrab.so
+lib/libstatgrab.so.5
+lib/libstatgrab.so.5.0
+lib/pkgconfig/libstatgrab.pc
+man/man3/sg_get_cpu_percents.3
+man/man3/sg_get_cpu_stats.3
+man/man3/sg_get_cpu_stats_diff.3
+man/man3/sg_get_disk_io_stats.3
+man/man3/sg_get_disk_io_stats_diff.3
+man/man3/sg_get_fs_stats.3
+man/man3/sg_get_host_info.3
+man/man3/sg_get_load_stats.3
+man/man3/sg_get_mem_stats.3
+man/man3/sg_get_network_iface_stats.3
+man/man3/sg_get_network_io_stats.3
+man/man3/sg_get_network_io_stats_diff.3
+man/man3/sg_get_page_stats.3
+man/man3/sg_get_page_stats_diff.3
+man/man3/sg_get_process_count.3
+man/man3/sg_get_process_stats.3
+man/man3/sg_get_swap_stats.3
+man/man3/sg_get_user_stats.3
+man/man3/statgrab.3
diff --git a/devel/libstatgrab/buildlink3.mk b/devel/libstatgrab/buildlink3.mk
new file mode 100644
index 00000000000..3ab50bbc111
--- /dev/null
+++ b/devel/libstatgrab/buildlink3.mk
@@ -0,0 +1,18 @@
+# $NetBSD: buildlink3.mk,v 1.1.1.1 2004/05/20 20:48:58 xtraeme Exp $
+
+BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
+LIBSTATGRAB_BUILDLINK3_MK:= ${LIBSTATGRAB_BUILDLINK3_MK}+
+
+.if !empty(BUILDLINK_DEPTH:M+)
+BUILDLINK_DEPENDS+= libstatgrab
+.endif
+
+BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nlibstatgrab}
+BUILDLINK_PACKAGES+= libstatgrab
+
+.if !empty(LIBSTATGRAB_BUILDLINK3_MK:M+)
+BUILDLINK_DEPENDS.libstatgrab+= libstatgrab>=0.9
+BUILDLINK_PKGSRCDIR.libstatgrab?= ../../wip/libstatgrab
+.endif # LIBSTATGRAB_BUILDLINK3_MK
+
+BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}
diff --git a/devel/libstatgrab/distinfo b/devel/libstatgrab/distinfo
new file mode 100644
index 00000000000..e2cdabe14f9
--- /dev/null
+++ b/devel/libstatgrab/distinfo
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1.1.1 2004/05/20 20:48:58 xtraeme Exp $
+
+SHA1 (libstatgrab-0.10.tar.gz) = 90ed5616776dc3043646dff55c29486bb99f7a0a
+Size (libstatgrab-0.10.tar.gz) = 406060 bytes
+SHA1 (patch-aa) = 96a0468807a4437b30f07a1e6b106459e556ce64
+SHA1 (patch-ab) = 5d0edb931d3c14dcd2560c0a777295fc523e9052
diff --git a/devel/libstatgrab/patches/patch-aa b/devel/libstatgrab/patches/patch-aa
new file mode 100644
index 00000000000..246bf8cbfea
--- /dev/null
+++ b/devel/libstatgrab/patches/patch-aa
@@ -0,0 +1,13 @@
+$NetBSD: patch-aa,v 1.1.1.1 2004/05/20 20:48:58 xtraeme Exp $
+
+--- configure.bak 2004-05-20 13:33:41.000000000 +0100
++++ configure 2004-05-20 13:35:00.000000000 +0100
+@@ -20421,7 +20421,7 @@
+ # Set things up for different OS's
+ # We define the name of the OS so the code can act accordingly
+ # We also need to add the right LDFLAGS
+-case $host_os in
++case $build_os in
+ solaris2.[6-7])
+
+ for ac_header in kstat.h
diff --git a/devel/libstatgrab/patches/patch-ab b/devel/libstatgrab/patches/patch-ab
new file mode 100644
index 00000000000..8b952dc7323
--- /dev/null
+++ b/devel/libstatgrab/patches/patch-ab
@@ -0,0 +1,17 @@
+$NetBSD: patch-ab,v 1.1.1.1 2004/05/20 20:48:58 xtraeme Exp $
+
+--- src/libstatgrab/disk_stats.c.bak 2004-05-20 21:17:27.000000000 +0100
++++ src/libstatgrab/disk_stats.c 2004-05-20 21:17:34.000000000 +0100
+@@ -122,8 +122,12 @@
+ #endif
+ #ifdef ALLBSD
+ int nummnt;
++#if defined(__NetBSD__) && (__NetBSD_Version__ > 200030000)
++ struct statvfs *mp;
++#else
+ struct statfs *mp;
+ #endif
++#endif
+
+ #ifdef ALLBSD
+ nummnt=getmntinfo(&mp , MNT_LOCAL);