qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Markus Armbruster <armbru@redhat.com>
To: qemu-devel@nongnu.org
Cc: stefanha@redhat.com, Pierrick Bouvier <pierrick.bouvier@linaro.org>
Subject: [PULL 12/13] qapi: make all generated files common
Date: Wed, 28 May 2025 20:31:50 +0200	[thread overview]
Message-ID: <20250528183151.2839034-13-armbru@redhat.com> (raw)
In-Reply-To: <20250528183151.2839034-1-armbru@redhat.com>

From: Pierrick Bouvier <pierrick.bouvier@linaro.org>

Monolithic files (qapi_nonmodule_outputs) can now be compiled just
once, so we can remove qapi_util_outputs logic.
This removes the need for any specific_ss file.

Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Message-ID: <20250522190542.588267-13-pierrick.bouvier@linaro.org>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
---
 qapi/meson.build | 23 ++++-------------------
 1 file changed, 4 insertions(+), 19 deletions(-)

diff --git a/qapi/meson.build b/qapi/meson.build
index 7582c2b5bc..3b035aea33 100644
--- a/qapi/meson.build
+++ b/qapi/meson.build
@@ -85,8 +85,7 @@ qapi_nonmodule_outputs = [
   'qapi-emit-events.c', 'qapi-emit-events.h',
 ]
 
-# First build all sources
-qapi_util_outputs = [
+qapi_outputs = qapi_nonmodule_outputs + [
   'qapi-builtin-types.c', 'qapi-builtin-visit.c',
   'qapi-builtin-types.h', 'qapi-builtin-visit.h',
 ]
@@ -109,20 +108,17 @@ foreach module : qapi_all_modules
       'qapi-commands-@0@.trace-events'.format(module),
     ]
   endif
-  qapi_util_outputs += qapi_module_outputs
+  qapi_outputs += qapi_module_outputs
 endforeach
 
 qapi_files = custom_target('shared QAPI source files',
-  output: qapi_util_outputs + qapi_nonmodule_outputs,
+  output: qapi_outputs,
   input: [ files('qapi-schema.json') ],
   command: [ qapi_gen, '-o', 'qapi', '-b', '@INPUT0@' ],
   depend_files: [ qapi_inputs, qapi_gen_depends ])
 
-# Now go through all the outputs and add them to the right sourceset.
-# These loops must be synchronized with the output of the above custom target.
-
 i = 0
-foreach output : qapi_util_outputs
+foreach output : qapi_outputs
   if output.endswith('.h')
     genh += qapi_files[i]
   endif
@@ -132,14 +128,3 @@ foreach output : qapi_util_outputs
   util_ss.add(qapi_files[i])
   i = i + 1
 endforeach
-
-foreach output : qapi_nonmodule_outputs
-  if output.endswith('.h')
-    genh += qapi_files[i]
-  endif
-  if output.endswith('.trace-events')
-    qapi_trace_events += qapi_files[i]
-  endif
-  specific_ss.add(when: 'CONFIG_SYSTEM_ONLY', if_true: qapi_files[i])
-  i = i + 1
-endforeach
-- 
2.48.1



  parent reply	other threads:[~2025-05-28 18:35 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-28 18:31 [PULL 00/13] QAPI patches patches for 2025-05-28 Markus Armbruster
2025-05-28 18:31 ` [PULL 01/13] qapi: expose rtc-reset-reinjection command unconditionally Markus Armbruster
2025-05-28 18:31 ` [PULL 02/13] qapi: expand docs for SEV commands Markus Armbruster
2025-05-28 18:31 ` [PULL 03/13] qapi: make SEV commands unconditionally available Markus Armbruster
2025-05-28 18:31 ` [PULL 04/13] qapi: expose query-gic-capability command unconditionally Markus Armbruster
2025-05-28 18:31 ` [PULL 05/13] qapi: make SGX commands unconditionally available Markus Armbruster
2025-05-28 18:31 ` [PULL 06/13] qapi: make Xen event " Markus Armbruster
2025-05-28 18:31 ` [PULL 07/13] qapi: remove the misc-target.json file Markus Armbruster
2025-05-28 18:31 ` [PULL 08/13] qapi: Make CpuModelExpansionInfo::deprecated-props optional and generic Markus Armbruster
2025-05-28 18:31 ` [PULL 09/13] qapi: make most CPU commands unconditionally available Markus Armbruster
2025-05-28 18:31 ` [PULL 10/13] qapi: make s390x specific " Markus Armbruster
2025-05-28 18:31 ` [PULL 11/13] qapi: remove qapi_specific_outputs from meson.build Markus Armbruster
2025-05-28 18:31 ` Markus Armbruster [this message]
2025-05-28 18:31 ` [PULL 13/13] qapi: use imperative style in documentation Markus Armbruster
2025-05-29 14:56 ` [PULL 00/13] QAPI patches patches for 2025-05-28 Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250528183151.2839034-13-armbru@redhat.com \
    --to=armbru@redhat.com \
    --cc=pierrick.bouvier@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).