From: Stefan Hajnoczi <stefanha@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
"Lluís Vilanova" <vilanova@ac.upc.edu>,
"Anthony Liguori" <aliguori@amazon.com>
Subject: [Qemu-devel] [PULL 3/6] Adapt Makefiles to the new LTTng ust interface
Date: Wed, 19 Feb 2014 16:45:56 +0100 [thread overview]
Message-ID: <1392824759-7093-4-git-send-email-stefanha@redhat.com> (raw)
In-Reply-To: <1392824759-7093-1-git-send-email-stefanha@redhat.com>
From: Mohamad Gebai <mohamad.gebai@gmail.com>
Add generation of new files for LTTng ust.
Signed-off-by: Mohamad Gebai <mohamad.gebai@polymtl.ca>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
Makefile | 5 +++++
trace/Makefile.objs | 25 +++++++++++++++++++++++++
2 files changed, 30 insertions(+)
diff --git a/Makefile b/Makefile
index 807054b..a443cd4 100644
--- a/Makefile
+++ b/Makefile
@@ -57,6 +57,11 @@ GENERATED_HEADERS += trace/generated-tracers-dtrace.h
endif
GENERATED_SOURCES += trace/generated-tracers.c
+ifeq ($(TRACE_BACKEND),ust)
+GENERATED_HEADERS += trace/generated-ust-provider.h
+GENERATED_SOURCES += trace/generated-ust.c
+endif
+
# Don't try to regenerate Makefile or configure
# We don't generate any of them
Makefile: ;
diff --git a/trace/Makefile.objs b/trace/Makefile.objs
index 3b88e49..d321946 100644
--- a/trace/Makefile.objs
+++ b/trace/Makefile.objs
@@ -1,6 +1,30 @@
# -*- mode: makefile -*-
######################################################################
+# Auto-generated event descriptions for LTTng ust code
+
+ifeq ($(TRACE_BACKEND),ust)
+$(obj)/generated-ust-provider.h: $(obj)/generated-ust-provider.h-timestamp
+$(obj)/generated-ust-provider.h-timestamp: $(SRC_PATH)/trace-events
+ $(call quiet-command,$(TRACETOOL) \
+ --format=ust-events-h \
+ --backend=$(TRACE_BACKEND) \
+ < $< > $@," GEN $(patsubst %-timestamp,%,$@)")
+ @cmp -s $@ $(patsubst %-timestamp,%,$@) || cp $@ $(patsubst %-timestamp,%,$@)
+
+$(obj)/generated-ust.c: $(obj)/generated-ust.c-timestamp $(BUILD_DIR)/config-host.mak
+$(obj)/generated-ust.c-timestamp: $(SRC_PATH)/trace-events
+ $(call quiet-command,$(TRACETOOL) \
+ --format=ust-events-c \
+ --backend=$(TRACE_BACKEND) \
+ < $< > $@," GEN $(patsubst %-timestamp,%,$@)")
+ @cmp -s $@ $(patsubst %-timestamp,%,$@) || cp $@ $(patsubst %-timestamp,%,$@)
+
+$(obj)/generated-events.h: $(obj)/generated-ust-provider.h
+$(obj)/generated-events.c: $(obj)/generated-ust.c
+endif
+
+######################################################################
# Auto-generated event descriptions
$(obj)/generated-events.h: $(obj)/generated-events.h-timestamp
@@ -77,5 +101,6 @@ util-obj-$(CONFIG_TRACE_DEFAULT) += default.o
util-obj-$(CONFIG_TRACE_SIMPLE) += simple.o
util-obj-$(CONFIG_TRACE_STDERR) += stderr.o
util-obj-$(CONFIG_TRACE_FTRACE) += ftrace.o
+util-obj-$(CONFIG_TRACE_UST) += generated-ust.o
util-obj-y += control.o
util-obj-y += generated-tracers.o
--
1.8.5.3
next prev parent reply other threads:[~2014-02-19 15:46 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-19 15:45 [Qemu-devel] [PULL 0/6] Tracing patches Stefan Hajnoczi
2014-02-19 15:45 ` [Qemu-devel] [PULL 1/6] Fix configure script for LTTng 2.x Stefan Hajnoczi
2014-02-19 15:45 ` [Qemu-devel] [PULL 2/6] Modified the tracetool framework " Stefan Hajnoczi
2014-02-19 15:45 ` Stefan Hajnoczi [this message]
2014-02-19 15:45 ` [Qemu-devel] [PULL 4/6] Update documentation for LTTng ust tracing Stefan Hajnoczi
2014-02-19 15:45 ` [Qemu-devel] [PULL 5/6] Add ust generated files to .gitignore Stefan Hajnoczi
2014-02-19 15:45 ` [Qemu-devel] [PULL 6/6] trace-events: Fix typo in "offset" Stefan Hajnoczi
2014-02-19 16:01 ` [Qemu-devel] [PULL 0/6] Tracing patches Lluís Vilanova
2014-02-20 10:24 ` Stefan Hajnoczi
2014-02-21 14:46 ` Peter Maydell
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=1392824759-7093-4-git-send-email-stefanha@redhat.com \
--to=stefanha@redhat.com \
--cc=aliguori@amazon.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=vilanova@ac.upc.edu \
/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).