blob: fb1bf79f957dee87e2756b5aa3164d8d4fb22985 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
--- mono/utils/mono-proclib.c.orig 2008-11-10 20:56:14 -0800
+++ mono/utils/mono-proclib.c 2009-03-03 15:30:03 -0800
@@ -13,14 +13,19 @@
#endif
/* FIXME: bsds untested */
-#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
+#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
#include <sys/types.h>
#include <sys/sysctl.h>
+#ifndef __DragonFly__
#include <sys/proc.h>
+#endif
#ifdef HAVE_SYS_USER_H
#include <sys/user.h>
#endif
-#ifdef HAVE_STRUCT_KINFO_PROC_KP_PROC
+#ifdef __DragonFly__
+#define kinfo_pid_member kp_pid
+#define kinfo_name_member kp_comm
+#elif HAVE_STRUCT_KINFO_PROC_KP_PROC
#define kinfo_pid_member kp_proc.p_pid
#define kinfo_name_member kp_proc.p_comm
#else
|