[Mesa-dev] [PATCH 2/3] gallium/aux: Fill in Haiku get process name code
Alexander von Gluck IV
kallisti5 at unixzen.com
Tue Aug 19 06:23:41 PDT 2014
---
src/gallium/auxiliary/os/os_process.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/src/gallium/auxiliary/os/os_process.c b/src/gallium/auxiliary/os/os_process.c
index 3e060b9..a626228 100644
--- a/src/gallium/auxiliary/os/os_process.c
+++ b/src/gallium/auxiliary/os/os_process.c
@@ -36,6 +36,9 @@
# include <errno.h>
#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE)
# include <stdlib.h>
+#elif defined(PIPE_OS_HAIKU)
+# include <kernel/OS.h>
+# include <kernel/image.h>
#else
#warning unexpected platform in os_process.c
#endif
@@ -73,6 +76,10 @@ os_get_process_name(char *procname, size_t size)
#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE)
/* *BSD and OS X */
name = getprogname();
+#elif defined(PIPE_OS_HAIKU)
+ image_info info;
+ get_image_info(B_CURRENT_TEAM, &info);
+ name = info.name;
#else
#warning unexpected platform in os_process.c
return FALSE;
--
1.7.1
More information about the mesa-dev
mailing list