Skip to contentSkip to conversation

tracing: install trace events file only if necessary

PATCH Superseded [email protected] 2 participants 6 messages Mar 26, 2023 – Mar 27, 2023 Arm/Amlogic Meson SoC support

v1 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tracing: install trace events file only if necessary

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +1 -1
index 8e80be895c..3fb41c97a4 100644
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,
                                  install_dir: qemu_datadir)
 
 if 'ust' in get_option('trace_backends')
Signature · 1 line
2.31.1
#1 lore raw
Quoted 14 lines · On Sun, Mar 26, 2023 at 06:04:46PM -0300, [email protected] wrote:

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +0 -0
index 8e80be895c..3fb41c97a4 100644

trace/meson.build trace_events_all = custom_target('trace-events-all', · line 67

Quoted 5 lines
trace/meson.build +1 -1
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,

Trace events are used by our command line tools too qemu-img, qemu-io, qemu-nbd, qemu-pr-helper, qemu-storage-daemon.

What build scenario are you seeing that does NOT want the trace events
to be present ? If there is any, then I might even call that situation
a bug, as we want trace events to be available as a debugging mechanism for everything we build.

With regards,
Daniel

Signature · 3 lines
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|
#2 lore raw
Quoted 25 lines · Daniel P. Berrangé
Quoted 14 lines · On Sun, Mar 26, 2023 at 06:04:46PM -0300, [email protected] wrote:

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +0 -0
index 8e80be895c..3fb41c97a4 100644

trace/meson.build trace_events_all = custom_target('trace-events-all', · line 67

Quoted 5 lines
trace/meson.build +1 -1
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,

Trace events are used by our command line tools too qemu-img, qemu-io, qemu-nbd, qemu-pr-helper, qemu-storage-daemon.

Quoted 4 lines

What build scenario are you seeing that does NOT want the trace events
to be present ? If there is any, then I might even call that situation
a bug, as we want trace events to be available as a debugging mechanism for everything we build.

I'm aiming for an embedded system or a VM image that only needs qemu-ga, in which qemu is built with --enable-trace-backends=nop.

Signature · 4 lines
Carlos Santos
Senior Software Maintenance Engineer
Red Hat
[email protected]    T: +55-11-3534-6186
#3 lore raw
Quoted 26 lines · Carlos Santos
Quoted 25 lines · Daniel P. Berrangé
Quoted 14 lines · On Sun, Mar 26, 2023 at 06:04:46PM -0300, [email protected] wrote:

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +0 -0
index 8e80be895c..3fb41c97a4 100644

trace/meson.build trace_events_all = custom_target('trace-events-all', · line 67

Quoted 5 lines
trace/meson.build +1 -1
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,

Trace events are used by our command line tools too qemu-img, qemu-io, qemu-nbd, qemu-pr-helper, qemu-storage-daemon.

Quoted 7 lines
Quoted 4 lines

What build scenario are you seeing that does NOT want the trace events
to be present ? If there is any, then I might even call that situation
a bug, as we want trace events to be available as a debugging mechanism for everything we build.

I'm aiming for an embedded system or a VM image that only needs qemu-ga, in which qemu is built with --enable-trace-backends=nop.

How about

install: get_option('trace_backends') != 'nop'

?

With regards,
Daniel

Signature · 3 lines
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|
#4 lore raw
Quoted 33 lines · Daniel P. Berrangé
Quoted 31 lines · Carlos Santos
Quoted 29 lines · Daniel P. Berrangé
Quoted 14 lines · On Sun, Mar 26, 2023 at 06:04:46PM -0300, [email protected] wrote:

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +0 -0
index 8e80be895c..3fb41c97a4 100644

trace/meson.build trace_events_all = custom_target('trace-events-all', · line 67

Quoted 5 lines
trace/meson.build +1 -1
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,

Trace events are used by our command line tools too qemu-img, qemu-io, qemu-nbd, qemu-pr-helper, qemu-storage-daemon.

What build scenario are you seeing that does NOT want the trace events
to be present ? If there is any, then I might even call that situation
a bug, as we want trace events to be available as a debugging mechanism for everything we build.

Quoted 8 lines
Quoted 2 lines

I'm aiming for an embedded system or a VM image that only needs qemu-ga, in which qemu is built with --enable-trace-backends=nop.

How about

install: get_option('trace_backends') != 'nop'

?

That would be perfect :-)

Signature · 4 lines
Carlos Santos
Senior Software Maintenance Engineer
Red Hat
[email protected]    T: +55-11-3534-6186
#5 lore raw
Quoted 44 lines · Carlos Santos
Quoted 33 lines · Daniel P. Berrangé
Quoted 31 lines · Carlos Santos
Quoted 29 lines · Daniel P. Berrangé
Quoted 14 lines · On Sun, Mar 26, 2023 at 06:04:46PM -0300, [email protected] wrote:

From: Carlos Santos <[email protected]>

It is required only if linux-user, bsd-user or system emulator is built.

---
 trace/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace/meson.build +0 -0
index 8e80be895c..3fb41c97a4 100644

trace/meson.build trace_events_all = custom_target('trace-events-all', · line 67

Quoted 5 lines
trace/meson.build +1 -1
@@ -64,7 +64,7 @@ trace_events_all = custom_target('trace-events-all',
                                  input: trace_events_files,
                                  command: [ 'cat', '@INPUT@' ],
                                  capture: true,
-                                 install: true,
+                                 install: have_linux_user or have_bsd_user or have_system,

Trace events are used by our command line tools too qemu-img, qemu-io, qemu-nbd, qemu-pr-helper, qemu-storage-daemon.

What build scenario are you seeing that does NOT want the trace events
to be present ? If there is any, then I might even call that situation
a bug, as we want trace events to be available as a debugging mechanism for everything we build.

Quoted 8 lines
Quoted 2 lines

I'm aiming for an embedded system or a VM image that only needs qemu-ga, in which qemu is built with --enable-trace-backends=nop.

How about

install: get_option('trace_backends') != 'nop'

?

Quoted 7 lines

That would be perfect :-)

--
Carlos Santos
Senior Software Maintenance Engineer
Red Hat
[email protected] T: +55-11-3534-6186

I submitted an updated patch. Thanks.

Signature · 4 lines
Carlos Santos
Senior Software Maintenance Engineer
Red Hat
[email protected]    T: +55-11-3534-6186