aboutsummaryrefslogtreecommitdiff
path: root/tests/qapi-schema/qapi-schema-test.out
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2019-03-01 16:40:48 +0100
committerMarkus Armbruster <armbru@redhat.com>2019-03-05 14:43:11 +0100
commit709395f8f627808175307f0c298ce71614fa67d0 (patch)
tree6b4741f70ae41f46617e9e5c34dfa7e6e346028a /tests/qapi-schema/qapi-schema-test.out
parentdddee4d7ba3c0992a32f805c02cb612775dfba54 (diff)
qapi: Fix code generation for sub-modules in other directories
The #include directives to pull in sub-modules use file names relative to the main module. Works only when all modules are in the same directory, or the main module's output directory is in the compiler's include path. Use relative file names instead. The dummy variable we generate to avoid empty .o files has an invalid name for sub-modules in other directories. Fix that. Both messed up in commit 252dc3105fc "qapi: Generate separate .h, .c for each module". Escaped testing because tests/qapi-schema-test.json doesn't cover sub-modules in other directories, only tests/qapi-schema/include-relpath.json does, and we generate and compile C code only for the former, not the latter. Fold the latter into the former. This would have caught the mistakes fixed in this commit. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20190301154051.23317-5-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'tests/qapi-schema/qapi-schema-test.out')
-rw-r--r--tests/qapi-schema/qapi-schema-test.out9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/qapi-schema/qapi-schema-test.out b/tests/qapi-schema/qapi-schema-test.out
index 97f671ca5f..baba4c8384 100644
--- a/tests/qapi-schema/qapi-schema-test.out
+++ b/tests/qapi-schema/qapi-schema-test.out
@@ -176,6 +176,15 @@ object UserDefNativeListUnion
case string: q_obj_strList-wrapper
case sizes: q_obj_sizeList-wrapper
case any: q_obj_anyList-wrapper
+include include/sub-module.json
+module include/sub-module.json
+include sub-sub-module.json
+module sub-sub-module.json
+enum Status
+ member good
+ member bad
+ member ugly
+module qapi-schema-test.json
command user_def_cmd None -> None
gen=True success_response=True boxed=False oob=False preconfig=False
object q_obj_user_def_cmd1-arg