[Mesa-dev] [PATCH 02/12] mesa: include stdio.h where needed

Brian Paul brianp at vmware.com
Wed Mar 4 18:18:34 PST 2015


Instead of relying on glapi.h or some other header to provide it.
---
 src/mesa/main/blit.c              | 1 +
 src/mesa/main/debug.c             | 1 +
 src/mesa/main/dlist.h             | 2 +-
 src/mesa/main/errors.c            | 1 +
 src/mesa/main/execmem.c           | 1 +
 src/mesa/main/framebuffer.c       | 2 +-
 src/mesa/main/imports.c           | 1 +
 src/mesa/main/texobj.c            | 1 +
 src/mesa/main/texstate.c          | 1 +
 src/mesa/main/varray.c            | 1 +
 src/mesa/main/version.c           | 1 +
 src/mesa/math/m_vector.c          | 1 +
 src/mesa/program/prog_statevars.c | 1 +
 src/mesa/tnl/t_draw.c             | 2 ++
 src/mesa/tnl/t_vb_render.c        | 1 +
 src/mesa/tnl/t_vertex.c           | 1 +
 src/mesa/vbo/vbo_exec_array.c     | 1 +
 src/mesa/vbo/vbo_exec_draw.c      | 1 +
 src/mesa/vbo/vbo_rebase.c         | 1 +
 src/mesa/vbo/vbo_save_loopback.c  | 1 +
 src/mesa/vbo/vbo_split_copy.c     | 2 ++
 src/mesa/x86/gen_matypes.c        | 2 ++
 22 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/blit.c b/src/mesa/main/blit.c
index 2898723..0694466 100644
--- a/src/mesa/main/blit.c
+++ b/src/mesa/main/blit.c
@@ -28,6 +28,7 @@
  */
 
 #include <stdbool.h>
+#include <stdio.h>
 
 #include "context.h"
 #include "enums.h"
diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c
index 4522114..eda4937 100644
--- a/src/mesa/main/debug.c
+++ b/src/mesa/main/debug.c
@@ -23,6 +23,7 @@
  * OTHER DEALINGS IN THE SOFTWARE.
  */
 
+#include <stdio.h>
 #include "mtypes.h"
 #include "attrib.h"
 #include "colormac.h"
diff --git a/src/mesa/main/dlist.h b/src/mesa/main/dlist.h
index 6189632..a121467 100644
--- a/src/mesa/main/dlist.h
+++ b/src/mesa/main/dlist.h
@@ -32,7 +32,7 @@
 #ifndef DLIST_H
 #define DLIST_H
 
-
+#include <stdio.h>
 #include "main/mtypes.h"
 
 
diff --git a/src/mesa/main/errors.c b/src/mesa/main/errors.c
index 33c1730..8ffbf41 100644
--- a/src/mesa/main/errors.c
+++ b/src/mesa/main/errors.c
@@ -29,6 +29,7 @@
 
 
 #include <stdarg.h>
+#include <stdio.h>
 #include "errors.h"
 #include "enums.h"
 #include "imports.h"
diff --git a/src/mesa/main/execmem.c b/src/mesa/main/execmem.c
index 7267cf8..3a13385 100644
--- a/src/mesa/main/execmem.c
+++ b/src/mesa/main/execmem.c
@@ -31,6 +31,7 @@
  */
 
 
+#include <stdio.h>
 #include "imports.h"
 
 
diff --git a/src/mesa/main/framebuffer.c b/src/mesa/main/framebuffer.c
index 5df1ecc..4f7736a 100644
--- a/src/mesa/main/framebuffer.c
+++ b/src/mesa/main/framebuffer.c
@@ -29,7 +29,7 @@
  * ushorts, uints, etc.
  */
 
-
+#include <stdio.h>
 #include "glheader.h"
 #include "imports.h"
 #include "blend.h"
diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c
index 752cf5a..a7ffe22 100644
--- a/src/mesa/main/imports.c
+++ b/src/mesa/main/imports.c
@@ -42,6 +42,7 @@
  * OTHER DEALINGS IN THE SOFTWARE.
  */
 
+#include <stdio.h>
 #include <stdarg.h>
 #include "c99_math.h"
 #include "imports.h"
diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c
index d5aa620..e018ab9 100644
--- a/src/mesa/main/texobj.c
+++ b/src/mesa/main/texobj.c
@@ -28,6 +28,7 @@
  */
 
 
+#include <stdio.h>
 #include "bufferobj.h"
 #include "colortab.h"
 #include "context.h"
diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c
index 78ae7d2..0a7f983 100644
--- a/src/mesa/main/texstate.c
+++ b/src/mesa/main/texstate.c
@@ -28,6 +28,7 @@
  * Texture state handling.
  */
 
+#include <stdio.h>
 #include "glheader.h"
 #include "bufferobj.h"
 #include "colormac.h"
diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c
index 3db9e06..42e7f89 100644
--- a/src/mesa/main/varray.c
+++ b/src/mesa/main/varray.c
@@ -24,6 +24,7 @@
  */
 
 
+#include <stdio.h>
 #include <inttypes.h>  /* for PRId64 macro */
 
 #include "glheader.h"
diff --git a/src/mesa/main/version.c b/src/mesa/main/version.c
index 4951891..8e0c3ef 100644
--- a/src/mesa/main/version.c
+++ b/src/mesa/main/version.c
@@ -23,6 +23,7 @@
  */
 
 
+#include <stdio.h>
 #include "imports.h"
 #include "mtypes.h"
 #include "version.h"
diff --git a/src/mesa/math/m_vector.c b/src/mesa/math/m_vector.c
index ff42396..831f953 100644
--- a/src/mesa/math/m_vector.c
+++ b/src/mesa/math/m_vector.c
@@ -26,6 +26,7 @@
  * New (3.1) transformation code written by Keith Whitwell.
  */
 
+#include <stdio.h>
 
 #include "main/glheader.h"
 #include "main/imports.h"
diff --git a/src/mesa/program/prog_statevars.c b/src/mesa/program/prog_statevars.c
index 4cde744..57b25a7 100644
--- a/src/mesa/program/prog_statevars.c
+++ b/src/mesa/program/prog_statevars.c
@@ -29,6 +29,7 @@
  */
 
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/context.h"
 #include "main/blend.h"
diff --git a/src/mesa/tnl/t_draw.c b/src/mesa/tnl/t_draw.c
index be3f059..60265d6 100644
--- a/src/mesa/tnl/t_draw.c
+++ b/src/mesa/tnl/t_draw.c
@@ -25,6 +25,8 @@
  *    Keith Whitwell <keithw at vmware.com>
  */
 
+#include <stdio.h>
+
 #include "main/glheader.h"
 #include "main/bufferobj.h"
 #include "main/condrender.h"
diff --git a/src/mesa/tnl/t_vb_render.c b/src/mesa/tnl/t_vb_render.c
index a090c48..4960ac0 100644
--- a/src/mesa/tnl/t_vb_render.c
+++ b/src/mesa/tnl/t_vb_render.c
@@ -38,6 +38,7 @@
  */
 
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/context.h"
 #include "main/enums.h"
diff --git a/src/mesa/tnl/t_vertex.c b/src/mesa/tnl/t_vertex.c
index 90b97a0..369d6d9 100644
--- a/src/mesa/tnl/t_vertex.c
+++ b/src/mesa/tnl/t_vertex.c
@@ -25,6 +25,7 @@
  *    Keith Whitwell <keithw at vmware.com>
  */
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/context.h"
 #include "main/colormac.h"
diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c
index 8a36618..3ea775c 100644
--- a/src/mesa/vbo/vbo_exec_array.c
+++ b/src/mesa/vbo/vbo_exec_array.c
@@ -26,6 +26,7 @@
  * 
  **************************************************************************/
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/context.h"
 #include "main/state.h"
diff --git a/src/mesa/vbo/vbo_exec_draw.c b/src/mesa/vbo/vbo_exec_draw.c
index fa5eba9..91f2ca4 100644
--- a/src/mesa/vbo/vbo_exec_draw.c
+++ b/src/mesa/vbo/vbo_exec_draw.c
@@ -25,6 +25,7 @@
  *    Keith Whitwell <keithw at vmware.com>
  */
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/bufferobj.h"
 #include "main/compiler.h"
diff --git a/src/mesa/vbo/vbo_rebase.c b/src/mesa/vbo/vbo_rebase.c
index 82a0b8e..b06df4a 100644
--- a/src/mesa/vbo/vbo_rebase.c
+++ b/src/mesa/vbo/vbo_rebase.c
@@ -46,6 +46,7 @@
  * of zero.
  */
 
+#include <stdio.h>
 #include "main/glheader.h"
 #include "main/imports.h"
 #include "main/mtypes.h"
diff --git a/src/mesa/vbo/vbo_save_loopback.c b/src/mesa/vbo/vbo_save_loopback.c
index 8c93ae8..7410f18 100644
--- a/src/mesa/vbo/vbo_save_loopback.c
+++ b/src/mesa/vbo/vbo_save_loopback.c
@@ -25,6 +25,7 @@
  * 
  **************************************************************************/
 
+#include <stdio.h>
 #include "main/context.h"
 #include "main/glheader.h"
 #include "main/enums.h"
diff --git a/src/mesa/vbo/vbo_split_copy.c b/src/mesa/vbo/vbo_split_copy.c
index ca752e8..d1107dd 100644
--- a/src/mesa/vbo/vbo_split_copy.c
+++ b/src/mesa/vbo/vbo_split_copy.c
@@ -29,6 +29,8 @@
 /* Split indexed primitives with per-vertex copying.
  */
 
+#include <stdio.h>
+
 #include "main/glheader.h"
 #include "main/bufferobj.h"
 #include "main/imports.h"
diff --git a/src/mesa/x86/gen_matypes.c b/src/mesa/x86/gen_matypes.c
index 1e904aa..18ffb72 100644
--- a/src/mesa/x86/gen_matypes.c
+++ b/src/mesa/x86/gen_matypes.c
@@ -35,6 +35,8 @@
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS
 #endif
+
+#include <stdio.h>
 #include <inttypes.h>
 
 #include "main/glheader.h"
-- 
1.9.1



More information about the mesa-dev mailing list