- fix a check in configure and first stab at working mountlist.
This commit is contained in:
parent
706b5d1ee3
commit
3d472c5987
@ -1,10 +1,10 @@
|
||||
# $OpenBSD: Makefile,v 1.34 2009/10/16 10:56:04 jasper Exp $
|
||||
# $OpenBSD: Makefile,v 1.35 2009/11/02 20:19:06 jasper Exp $
|
||||
|
||||
COMMENT= portable library for obtaining system information
|
||||
|
||||
GNOME_VERSION= 2.28.0
|
||||
GNOME_PROJECT= libgtop
|
||||
PKGNAME= libgtop2-${VERSION}
|
||||
PKGNAME= libgtop2-${VERSION}p0
|
||||
|
||||
SHARED_LIBS= gtop-2.0 9.0 # .9.0
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
$OpenBSD: patch-configure,v 1.5 2009/10/16 10:56:04 jasper Exp $
|
||||
$OpenBSD: patch-configure,v 1.6 2009/11/02 20:19:06 jasper Exp $
|
||||
--- configure.orig Mon Sep 21 09:57:13 2009
|
||||
+++ configure Fri Oct 16 02:55:53 2009
|
||||
+++ configure Thu Oct 29 00:15:14 2009
|
||||
@@ -6763,10 +6763,12 @@ newos6*)
|
||||
;;
|
||||
|
||||
@ -81,7 +81,7 @@ $OpenBSD: patch-configure,v 1.5 2009/10/16 10:56:04 jasper Exp $
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
|
||||
+#include <sys/param.>
|
||||
+#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/mount.h>
|
||||
-#include <sys/fs_types.h>
|
||||
|
@ -1,7 +1,7 @@
|
||||
$OpenBSD: patch-sysdeps_bsd_glibtop_server_h,v 1.2 2009/10/16 10:56:04 jasper Exp $
|
||||
$OpenBSD: patch-sysdeps_bsd_glibtop_server_h,v 1.3 2009/11/02 20:19:06 jasper Exp $
|
||||
--- sysdeps/bsd/glibtop_server.h.orig Sun Apr 19 01:29:49 2009
|
||||
+++ sysdeps/bsd/glibtop_server.h Fri Oct 16 03:08:40 2009
|
||||
@@ -42,9 +42,12 @@ G_BEGIN_DECLS
|
||||
+++ sysdeps/bsd/glibtop_server.h Wed Oct 28 23:54:49 2009
|
||||
@@ -42,9 +42,11 @@ G_BEGIN_DECLS
|
||||
#define GLIBTOP_SUID_PROC_SEGMENT (1 << GLIBTOP_SYSDEPS_PROC_SEGMENT)
|
||||
#define GLIBTOP_SUID_PROC_ARGS (1 << GLIBTOP_SYSDEPS_PROC_ARGS)
|
||||
#define GLIBTOP_SUID_PROC_MAP (1 << GLIBTOP_SYSDEPS_PROC_MAP)
|
||||
@ -10,7 +10,6 @@ $OpenBSD: patch-sysdeps_bsd_glibtop_server_h,v 1.2 2009/10/16 10:56:04 jasper Ex
|
||||
#define GLIBTOP_SUID_NETLIST 0
|
||||
#define GLIBTOP_SUID_PPP (1 << GLIBTOP_SYSDEPS_PPP)
|
||||
+#define GLIBTOP_SUID_PROC_AFFINITY 0
|
||||
+
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
39
devel/libgtop2/patches/patch-sysdeps_common_mountlist_c
Normal file
39
devel/libgtop2/patches/patch-sysdeps_common_mountlist_c
Normal file
@ -0,0 +1,39 @@
|
||||
$OpenBSD: patch-sysdeps_common_mountlist_c,v 1.1 2009/11/02 20:19:06 jasper Exp $
|
||||
--- sysdeps/common/mountlist.c.orig Thu Oct 29 00:26:32 2009
|
||||
+++ sysdeps/common/mountlist.c Thu Oct 29 00:50:16 2009
|
||||
@@ -52,7 +52,9 @@ static struct mount_entry *read_filesystem_list (void)
|
||||
|
||||
#if defined (MOUNTED_GETFSSTAT) /* __alpha running OSF_1 */
|
||||
# include <sys/mount.h>
|
||||
-# include <sys/fs_types.h>
|
||||
+# if defined(HAVE_SYS_FSTYP_H)
|
||||
+# include <sys/fs_types.h>
|
||||
+# endif /* HAVE_SYS_FSTYP_H */
|
||||
#endif /* MOUNTED_GETFSSTAT */
|
||||
|
||||
#ifdef MOUNTED_GETMNTENT1 /* 4.3BSD, SunOS, HP-UX, Dynix, Irix. */
|
||||
@@ -298,7 +300,11 @@ read_filesystem_list (void)
|
||||
|
||||
#ifdef MOUNTED_GETMNTINFO /* 4.4BSD. */
|
||||
{
|
||||
+#if defined(STAT_STATVFS)
|
||||
+ struct statvfs *fsp;
|
||||
+#else
|
||||
struct statfs *fsp;
|
||||
+#endif /* STAT_STATVFS */
|
||||
int entries;
|
||||
|
||||
entries = getmntinfo (&fsp, MNT_NOWAIT);
|
||||
@@ -374,7 +380,12 @@ read_filesystem_list (void)
|
||||
me = (struct mount_entry *) g_malloc (sizeof (struct mount_entry));
|
||||
me->me_devname = g_strdup (stats[counter].f_mntfromname);
|
||||
me->me_mountdir = g_strdup (stats[counter].f_mntonname);
|
||||
+/* XXX */
|
||||
+#if defined(__OpenBSD__)
|
||||
+ me->me_type = g_strdup (stats[counter].f_fstypename);
|
||||
+#else
|
||||
me->me_type = g_strdup (mnt_names[stats[counter].f_type]);
|
||||
+#endif
|
||||
me->me_dev = (dev_t) -1; /* Magic; means not known yet. */
|
||||
me->me_next = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user