openbsd: merge patches from ports tree

Bring OpenBSD closer to FreeBSD to help checking what is missing/different.
Also we make sure to use and build mountlist and fsusage from the
sysdeps/openbsd directory instead of the common one.

https://bugzilla.gnome.org/show_bug.cgi?id=723521
This commit is contained in:
Antoine Jacoutot
2014-02-03 10:56:02 +01:00
parent c99ceeaa65
commit 4cd3e4fed6
17 changed files with 379 additions and 262 deletions

View File

@@ -37,7 +37,7 @@ static const unsigned long _required_cpu_flags =
/* Init function. */
void
_glibtop_init_uptime_p (glibtop *server)
_glibtop_init_uptime_s (glibtop *server)
{
server->sysdeps.uptime = _glibtop_sysdeps_uptime;
}
@@ -45,7 +45,7 @@ _glibtop_init_uptime_p (glibtop *server)
/* Provides uptime and idle time. */
void
glibtop_get_uptime_p (glibtop *server, glibtop_uptime *buf)
glibtop_get_uptime_s (glibtop *server, glibtop_uptime *buf)
{
time_t now;
int mib[2];
@@ -63,7 +63,7 @@ glibtop_get_uptime_p (glibtop *server, glibtop_uptime *buf)
buf->boot_time = boottime.tv_sec;
}
glibtop_get_cpu_p (server, &cpu);
glibtop_get_cpu_s (server, &cpu);
/* Put something clever in buf->idletime: CP_IDLE. */
buf->idletime = (double) cpu.idle / (double) cpu.frequency;