gallium: fix build on GNU/kFreeBSD
authorFabio Pedretti <fabio.ped@libero.it>
Wed, 6 Nov 2013 09:55:28 +0000 (10:55 +0100)
committerAndreas Boll <andreas.boll.dev@gmail.com>
Wed, 6 Nov 2013 21:08:26 +0000 (22:08 +0100)
Patch from Debian package

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Andreas Boll <andreas.boll.dev@gmail.com>
src/gallium/auxiliary/rtasm/rtasm_execmem.c
src/gallium/include/pipe/p_config.h

index 3c4b0483ae82b958ce108193f16af797d7c67838..edc1b66e8363ed1a623230ee2a6c2e0dfc55101b 100644 (file)
@@ -38,7 +38,7 @@
 
 #include "rtasm_execmem.h"
 
-#if defined(PIPE_OS_BSD)
+#ifndef MAP_ANONYMOUS
 #define MAP_ANONYMOUS MAP_ANON
 #endif
 
index 9bccf327d85bd853a7af418d8ade14d205e89131..64acd0283c3cf08b8def0b9949a743b4fd7477e3 100644 (file)
 #define PIPE_OS_ANDROID
 #endif
 
-#if defined(__FreeBSD__)
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
 #define PIPE_OS_FREEBSD
 #define PIPE_OS_BSD
 #define PIPE_OS_UNIX