On 16/06/21 11:16, Gerd Hoffmann wrote:
I was almost giving up... but it looks like the result of
extract_all_objects(recursive: true) can be passed to custom_target(). Then
you can match it after compile_commands.json's "output" key.
Seems the custom_target commands do not land in compile_comm
On Tue, Jun 15, 2021 at 03:35:44PM +0200, Paolo Bonzini wrote:
> On 15/06/21 15:07, Gerd Hoffmann wrote:
> > > Hmm, looks like I actually need both. Seems there is no easy way to get
> > > the cflags out of a source_set to construct a cpp command line. Pulling
> > > this out of compile_commands.j
On 15/06/21 15:07, Gerd Hoffmann wrote:
Hmm, looks like I actually need both. Seems there is no easy way to get
the cflags out of a source_set to construct a cpp command line. Pulling
this out of compile_commands.json with jq works though.
Well, easy until I look at target-specific modules whe
> > > A Python script could parse compile_commands.json, add -E -DQEMU_MODINFO
> > > to
> > > the command-line option, and look in the output for the metadata.
> >
> > Hmm, worth trying, although I guess it would be easier to code this up
> > straight in meson.build and pull the information you n
On Tue, Jun 15, 2021 at 06:54:41AM +0200, Gerd Hoffmann wrote:
> > > Problem with that approach is that it doesn't work for module
> > > dependencies ...
> > >
> > > Comments on the idea? Suggestions for the module dependency problem?
> > > Could maybe libbfd be used to find module (symbol) depen
On Tue, Jun 15, 2021 at 06:49:15AM +0200, Gerd Hoffmann wrote:
> Hi,
>
> > Another possibility to eschew .o parsing is to add something like this to
> > the sources
> >
> > #ifdef QEMU_MODINFO
> > #define MODULE_METADATA(key, value) \
> >=<>= MODINFO key value
> > #else
> > #define MODULE_M
> > Problem with that approach is that it doesn't work for module
> > dependencies ...
> >
> > Comments on the idea? Suggestions for the module dependency problem?
> > Could maybe libbfd be used to find module (symbol) dependencies
> > automatically without writing a full dynamic linker?
>
> Is
Hi,
> Another possibility to eschew .o parsing is to add something like this to
> the sources
>
> #ifdef QEMU_MODINFO
> #define MODULE_METADATA(key, value) \
>=<>= MODINFO key value
> #else
> #define MODULE_METADATA(key, value)
> #endif
>
> MODULE_METADATA("opts", "spice")
>
> A Python sc
On Mon, Jun 14, 2021 at 05:01:59PM +0200, Gerd Hoffmann wrote:
> Hi,
>
> > > softmmu_mods and block_mods are both lists already, so this sets a
> > > nested list and I wonder if it confuses meson ? eg do you need
> > >
> > > input: softmmu_mods + block_mods
> >
> > No, that should be fine.
Hi,
> > softmmu_mods and block_mods are both lists already, so this sets a
> > nested list and I wonder if it confuses meson ? eg do you need
> >
> > input: softmmu_mods + block_mods
>
> No, that should be fine. Perhaps it's because the inputs are not part of
> the command? You can check
On 14/06/21 10:34, Paolo Bonzini wrote:
- modinfo.json needs to be disabled on non-ELF platforms (x86, Windows).
One alternative is to use libbfd instead of including an ELF parser.
- If modinfo.json has to be installed, you need to build modinfo for the
build machine in order to support cro
On 10/06/21 15:13, Daniel P. Berrangé wrote:
On Thu, Jun 10, 2021 at 03:04:24PM +0200, Gerd Hoffmann wrote:
Hi Paolo,
+if config_host.has_key('CONFIG_MODULES')
+ qemu_modinfo = executable('qemu-modinfo', files('qemu-modinfo.c') + genh,
+ dependencies: [glib, qe
On Thu, Jun 10, 2021 at 03:04:24PM +0200, Gerd Hoffmann wrote:
> Hi Paolo,
>
> > +if config_host.has_key('CONFIG_MODULES')
> > + qemu_modinfo = executable('qemu-modinfo', files('qemu-modinfo.c') +
> > genh,
> > + dependencies: [glib, qemuutil], install:
> > have_t
Hi Paolo,
> +if config_host.has_key('CONFIG_MODULES')
> + qemu_modinfo = executable('qemu-modinfo', files('qemu-modinfo.c') + genh,
> + dependencies: [glib, qemuutil], install:
> have_tools)
> + custom_target('modinfo.json',
> + input: [ softmmu_m
Scan .modinfo sections of qemu modules,
write module metadata to modinfo.json.
Signed-off-by: Gerd Hoffmann
---
qemu-modinfo.c | 270 +
meson.build| 11 ++
2 files changed, 281 insertions(+)
create mode 100644 qemu-modinfo.c
diff --git a/qem
15 matches
Mail list logo