aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2012-12-06 11:22:34 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2012-12-19 08:31:30 +0100
commit79ee7df8853c5d7085d87036420b6b388dda2595 (patch)
tree6f2b23fcb24e3af7137fdfe22f62ad2b79a46b5d
parent28ecbaeecb139a214f019207402a35d7b58aec0f (diff)
qapi: move inclusions of qemu-common.h from headers to .c files
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--qapi/opts-visitor.c1
-rw-r--r--qapi/qapi-types-core.h1
-rw-r--r--qapi/qapi-visit-core.c1
-rw-r--r--qemu-error.h2
-rw-r--r--scripts/qapi-commands.py1
-rw-r--r--scripts/qapi-visit.py1
-rw-r--r--tests/test-qmp-commands.c1
-rw-r--r--tests/test-qmp-input-strict.c1
-rw-r--r--tests/test-qmp-input-visitor.c1
-rw-r--r--tests/test-qmp-output-visitor.c1
-rw-r--r--tests/test-string-input-visitor.c1
-rw-r--r--tests/test-string-output-visitor.c1
-rw-r--r--tests/test-visitor-serialization.c2
13 files changed, 14 insertions, 1 deletions
diff --git a/qapi/opts-visitor.c b/qapi/opts-visitor.c
index e048b6c863..e3fd25446d 100644
--- a/qapi/opts-visitor.c
+++ b/qapi/opts-visitor.c
@@ -10,6 +10,7 @@
*
*/
+#include "qemu-common.h"
#include "opts-visitor.h"
#include "qemu-queue.h"
#include "qemu-option-internal.h"
diff --git a/qapi/qapi-types-core.h b/qapi/qapi-types-core.h
index f781fc3ab7..831df21ea7 100644
--- a/qapi/qapi-types-core.h
+++ b/qapi/qapi-types-core.h
@@ -14,7 +14,6 @@
#ifndef QAPI_TYPES_CORE_H
#define QAPI_TYPES_CORE_H
-#include "qemu-common.h"
#include "error.h"
#include "qerror.h"
diff --git a/qapi/qapi-visit-core.c b/qapi/qapi-visit-core.c
index 7a82b63766..300293999d 100644
--- a/qapi/qapi-visit-core.c
+++ b/qapi/qapi-visit-core.c
@@ -11,6 +11,7 @@
*
*/
+#include "qemu-common.h"
#include "qapi/qapi-visit-core.h"
#include "qapi/qapi-visit-impl.h"
diff --git a/qemu-error.h b/qemu-error.h
index 93d74b4a30..c902cc10de 100644
--- a/qemu-error.h
+++ b/qemu-error.h
@@ -13,6 +13,8 @@
#ifndef QEMU_ERROR_H
#define QEMU_ERROR_H
+#include <stdarg.h>
+
typedef struct Location {
/* all members are private to qemu-error.c */
enum { LOC_NONE, LOC_CMDLINE, LOC_FILE } kind;
diff --git a/scripts/qapi-commands.py b/scripts/qapi-commands.py
index 3c4678dbf1..2db0bf1e56 100644
--- a/scripts/qapi-commands.py
+++ b/scripts/qapi-commands.py
@@ -366,6 +366,7 @@ def gen_command_def_prologue(prefix="", proxy=False):
*
*/
+#include "qemu-common.h"
#include "qemu-objects.h"
#include "qapi/qmp-core.h"
#include "qapi/qapi-visit-core.h"
diff --git a/scripts/qapi-visit.py b/scripts/qapi-visit.py
index a360de719f..f1aabb3813 100644
--- a/scripts/qapi-visit.py
+++ b/scripts/qapi-visit.py
@@ -298,6 +298,7 @@ fdef.write(mcgen('''
*
*/
+#include "qemu-common.h"
#include "%(header)s"
''',
header=basename(h_file)))
diff --git a/tests/test-qmp-commands.c b/tests/test-qmp-commands.c
index dc3c507f2b..bf41034c62 100644
--- a/tests/test-qmp-commands.c
+++ b/tests/test-qmp-commands.c
@@ -1,4 +1,5 @@
#include <glib.h>
+#include "qemu-common.h"
#include "qemu-objects.h"
#include "test-qmp-commands.h"
#include "qapi/qmp-core.h"
diff --git a/tests/test-qmp-input-strict.c b/tests/test-qmp-input-strict.c
index f6df8cbe1e..86f24d821c 100644
--- a/tests/test-qmp-input-strict.c
+++ b/tests/test-qmp-input-strict.c
@@ -14,6 +14,7 @@
#include <glib.h>
#include <stdarg.h>
+#include "qemu-common.h"
#include "qapi/qmp-input-visitor.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
diff --git a/tests/test-qmp-input-visitor.c b/tests/test-qmp-input-visitor.c
index 8f5a509582..6568c9907c 100644
--- a/tests/test-qmp-input-visitor.c
+++ b/tests/test-qmp-input-visitor.c
@@ -13,6 +13,7 @@
#include <glib.h>
#include <stdarg.h>
+#include "qemu-common.h"
#include "qapi/qmp-input-visitor.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
diff --git a/tests/test-qmp-output-visitor.c b/tests/test-qmp-output-visitor.c
index 24a6359504..84b1f41894 100644
--- a/tests/test-qmp-output-visitor.c
+++ b/tests/test-qmp-output-visitor.c
@@ -12,6 +12,7 @@
#include <glib.h>
+#include "qemu-common.h"
#include "qapi/qmp-output-visitor.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
diff --git a/tests/test-string-input-visitor.c b/tests/test-string-input-visitor.c
index 5370e32041..36b3792980 100644
--- a/tests/test-string-input-visitor.c
+++ b/tests/test-string-input-visitor.c
@@ -13,6 +13,7 @@
#include <glib.h>
#include <stdarg.h>
+#include "qemu-common.h"
#include "qapi/string-input-visitor.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
diff --git a/tests/test-string-output-visitor.c b/tests/test-string-output-visitor.c
index 608f14a5de..afb557a00f 100644
--- a/tests/test-string-output-visitor.c
+++ b/tests/test-string-output-visitor.c
@@ -12,6 +12,7 @@
#include <glib.h>
+#include "qemu-common.h"
#include "qapi/string-output-visitor.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
diff --git a/tests/test-visitor-serialization.c b/tests/test-visitor-serialization.c
index b8ad16fc9e..a251f878e1 100644
--- a/tests/test-visitor-serialization.c
+++ b/tests/test-visitor-serialization.c
@@ -14,6 +14,8 @@
#include <stdlib.h>
#include <stdint.h>
#include <float.h>
+
+#include "qemu-common.h"
#include "test-qapi-types.h"
#include "test-qapi-visit.h"
#include "qemu-objects.h"