diff options
author | Julio M. Merino Vidal <jmmv@NetBSD.org> | 2006-04-09 10:12:17 +0000 |
---|---|---|
committer | BenoƮt Dejean <bdejean@src.gnome.org> | 2006-04-09 10:12:17 +0000 |
commit | 9e6115f32274de354766659715ad0fb347bf7d00 (patch) | |
tree | fad4350e34f6cb699800043f4d823a88141afcba | |
parent | cead508eae62bc5a39452a45d3f09b3b21c310d5 (diff) | |
download | libgtop-9e6115f32274de354766659715ad0fb347bf7d00.tar.gz |
Check for the kvm library and use it to link the suid freebsd sysdeps code
2006-04-04 Julio M. Merino Vidal <jmmv@NetBSD.org>
* libgtop-sysdeps.m4:
* sysdeps/freebsd/Makefile.am:
Check for the kvm library and use it to link the suid freebsd
sysdeps code (only if available). This library provides all the
kvm_* functions used in it and is needed, at least, under NetBSD.
Fixes bug #337247.
-rw-r--r-- | ChangeLog | 11 | ||||
-rw-r--r-- | libgtop-sysdeps.m4 | 3 | ||||
-rw-r--r-- | sysdeps/freebsd/Makefile.am | 1 |
3 files changed, 15 insertions, 0 deletions
@@ -1,5 +1,16 @@ 2006-04-04 Julio M. Merino Vidal <jmmv@NetBSD.org> + * libgtop-sysdeps.m4: + * sysdeps/freebsd/Makefile.am: + + Check for the kvm library and use it to link the suid freebsd + sysdeps code (only if available). This library provides all the + kvm_* functions used in it and is needed, at least, under NetBSD. + + Fixes bug #337247. + +2006-04-04 Julio M. Merino Vidal <jmmv@NetBSD.org> + * sysdeps/aix/glibtop_server.h: * sysdeps/freebsd/glibtop_server.h: * sysdeps/osf1/glibtop_server.h: diff --git a/libgtop-sysdeps.m4 b/libgtop-sysdeps.m4 index 5fffc118..953742ad 100644 --- a/libgtop-sysdeps.m4 +++ b/libgtop-sysdeps.m4 @@ -126,6 +126,9 @@ AC_DEFUN([GNOME_LIBGTOP_SYSDEPS],[ case "$host_os" in *bsd*) + AC_CHECK_LIB(kvm, kvm_open, KVM_LIBS=-lkvm, KVM_LIBS=) + AC_SUBST(KVM_LIBS) + AC_CHECK_HEADERS(net/if_var.h) AC_MSG_CHECKING([for I4B]) AC_TRY_COMPILE([ diff --git a/sysdeps/freebsd/Makefile.am b/sysdeps/freebsd/Makefile.am index 20dd8a66..9ec00a3c 100644 --- a/sysdeps/freebsd/Makefile.am +++ b/sysdeps/freebsd/Makefile.am @@ -7,6 +7,7 @@ libgtop_sysdeps_2_0_la_SOURCES = nosuid.c siglist.c sysinfo.c libgtop_sysdeps_2_0_la_LDFLAGS = $(LT_VERSION_INFO) +libgtop_sysdeps_suid_2_0_la_LIBADD = $(KVM_LIBS) libgtop_sysdeps_suid_2_0_la_SOURCES = open.c close.c cpu.c mem.c swap.c \ uptime.c loadavg.c shm_limits.c msg_limits.c \ sem_limits.c proclist.c procstate.c procuid.c \ |