summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/util
diff options
context:
space:
mode:
authorEmil Velikov <[email protected]>2015-11-25 20:43:03 +0000
committerEmil Velikov <[email protected]>2016-03-09 17:21:39 +0000
commit373f118c6c750d717fd0727fc3fc191828714c6f (patch)
tree09eebda7e8291ed3cd01960aaa84728a9c36a114 /src/gallium/auxiliary/util
parent69d389c52f91e4d36e740f804a36b50af657a786 (diff)
gallium: do not wrap header inclusion in
Add one missing extern C guard within include/pipe/p_video_enums.h, and remove the wrapping throughout gallium. On Haiku one could even use the gallium debug_printf() although that's another topic. v2: Leave dbghelp.h as is (Jose) Cc: Jose Fonseca <[email protected]> Cc: Brian Paul <[email protected]> Cc: Alexander von Gluck IV <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r--src/gallium/auxiliary/util/u_debug.h8
-rw-r--r--src/gallium/auxiliary/util/u_draw_quad.h3
-rw-r--r--src/gallium/auxiliary/util/u_helpers.h4
-rw-r--r--src/gallium/auxiliary/util/u_video.h8
4 files changed, 12 insertions, 11 deletions
diff --git a/src/gallium/auxiliary/util/u_debug.h b/src/gallium/auxiliary/util/u_debug.h
index c2707b402cb..85d0cb64e6c 100644
--- a/src/gallium/auxiliary/util/u_debug.h
+++ b/src/gallium/auxiliary/util/u_debug.h
@@ -39,6 +39,11 @@
#define U_DEBUG_H_
+#if defined(PIPE_OS_HAIKU)
+/* Haiku provides debug_printf in libroot with OS.h */
+#include <OS.h>
+#endif
+
#include "os/os_misc.h"
#include "pipe/p_format.h"
@@ -94,9 +99,6 @@ debug_printf(const char *format, ...)
(void) format; /* silence warning */
#endif
}
-#else /* is Haiku */
-/* Haiku provides debug_printf in libroot with OS.h */
-#include <OS.h>
#endif
diff --git a/src/gallium/auxiliary/util/u_draw_quad.h b/src/gallium/auxiliary/util/u_draw_quad.h
index b298ef2ae59..6553d5d7b6b 100644
--- a/src/gallium/auxiliary/util/u_draw_quad.h
+++ b/src/gallium/auxiliary/util/u_draw_quad.h
@@ -32,6 +32,7 @@
#include "pipe/p_compiler.h"
#include "pipe/p_context.h"
+#include "util/u_draw.h"
#ifdef __cplusplus
extern "C" {
@@ -40,8 +41,6 @@ extern "C" {
struct pipe_resource;
struct cso_context;
-#include "util/u_draw.h"
-
extern void
util_draw_vertex_buffer(struct pipe_context *pipe, struct cso_context *cso,
struct pipe_resource *vbuf, uint vbuf_slot,
diff --git a/src/gallium/auxiliary/util/u_helpers.h b/src/gallium/auxiliary/util/u_helpers.h
index f25f2807fe5..a9a53e4347a 100644
--- a/src/gallium/auxiliary/util/u_helpers.h
+++ b/src/gallium/auxiliary/util/u_helpers.h
@@ -28,12 +28,12 @@
#ifndef U_HELPERS_H
#define U_HELPERS_H
+#include "pipe/p_state.h"
+
#ifdef __cplusplus
extern "C" {
#endif
-#include "pipe/p_state.h"
-
void util_set_vertex_buffers_mask(struct pipe_vertex_buffer *dst,
uint32_t *enabled_buffers,
const struct pipe_vertex_buffer *src,
diff --git a/src/gallium/auxiliary/util/u_video.h b/src/gallium/auxiliary/util/u_video.h
index ddc00216105..9196afc11be 100644
--- a/src/gallium/auxiliary/util/u_video.h
+++ b/src/gallium/auxiliary/util/u_video.h
@@ -28,10 +28,6 @@
#ifndef U_VIDEO_H
#define U_VIDEO_H
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include "pipe/p_defines.h"
#include "pipe/p_video_enums.h"
@@ -40,6 +36,10 @@ extern "C" {
#include "util/u_debug.h"
#include "util/u_math.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
static inline enum pipe_video_format
u_reduce_video_profile(enum pipe_video_profile profile)
{