* [Qemu-devel] [PATCH][Tracing] Fix for make parallelization.
@ 2010-06-28 12:32 Prerna Saxena
2010-06-28 13:46 ` [Qemu-devel] " Stefan Hajnoczi
0 siblings, 1 reply; 3+ messages in thread
From: Prerna Saxena @ 2010-06-28 12:32 UTC (permalink / raw)
To: Stefan Hajnoczi; +Cc: Maneesh Soni, Ananth Narayan, qemu-devel
[PATCH] Restore parallel building
This is based on :
http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/tracing
Signed-off-by: Prerna Saxena <prerna@linux.vnet.ibm.com>
---
Makefile | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/Makefile b/Makefile
index e64e397..de9b175 100644
--- a/Makefile
+++ b/Makefile
@@ -138,7 +138,9 @@ trace.h: $(SRC_PATH)/trace-events
trace.c: $(SRC_PATH)/trace-events
$(call quiet-command,sh $(SRC_PATH)/tracetool --$(TRACE_BACKEND) -c < $< > $@," GEN $@")
-trace.o: trace.c
+trace.o: trace.c trace.h
+
+simpletrace.o: simpletrace.c trace.h
######################################################################
--
1.6.2.5
--
Prerna Saxena
Linux Technology Centre,
IBM Systems and Technology Lab,
Bangalore, India
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Qemu-devel] Re: [PATCH][Tracing] Fix for make parallelization.
2010-06-28 12:32 [Qemu-devel] [PATCH][Tracing] Fix for make parallelization Prerna Saxena
@ 2010-06-28 13:46 ` Stefan Hajnoczi
2010-06-28 14:00 ` Stefan Hajnoczi
0 siblings, 1 reply; 3+ messages in thread
From: Stefan Hajnoczi @ 2010-06-28 13:46 UTC (permalink / raw)
To: Prerna Saxena; +Cc: Maneesh Soni, Ananth Narayan, qemu-devel
On Mon, Jun 28, 2010 at 06:02:37PM +0530, Prerna Saxena wrote:
> [PATCH] Restore parallel building
> This is based on :
> http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/tracing
>
> Signed-off-by: Prerna Saxena <prerna@linux.vnet.ibm.com>
Dependencies are not quite right yet:
$ make distclean
$ ./configure --trace-backend=simple
$ make V=1 trace.o
sh /home/stefanha/qemu/tracetool --simple -c < /home/stefanha/qemu/trace-events > trace.c
sh /home/stefanha/qemu/tracetool --simple -h < /home/stefanha/qemu/trace-events > trace.h
gcc -I/home/stefanha/qemu/slirp -Werror -m64 -fstack-protector-all -Wold-style-definition -Wold-style-declaration -I. -I/home/stefanha/qemu -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wendif-labels -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -MMD -MP -MT trace.o -MF ./trace.d -O2 -g -c -o trace.o trace.c
In file included from trace.h:6,
from trace.c:2:
qemu-common.h:5:25: error: config-host.h: No such file or directory
In file included from trace.h:6,
from trace.c:2:
qemu-common.h:61: error: redefinition of ‘struct iovec’
make: *** [trace.o] Error 1
I have applied it for now, however, because the implicit dependencies issue affects all of QEMU and was not caused by tracing code:
http://repo.or.cz/w/qemu/stefanha.git/commitdiff/e47a997579086dd585534da610e76f23f9c04b87
Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] Re: [PATCH][Tracing] Fix for make parallelization.
2010-06-28 13:46 ` [Qemu-devel] " Stefan Hajnoczi
@ 2010-06-28 14:00 ` Stefan Hajnoczi
0 siblings, 0 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2010-06-28 14:00 UTC (permalink / raw)
To: Stefan Hajnoczi; +Cc: qemu-devel, Maneesh Soni, Ananth Narayan, Prerna Saxena
On Mon, Jun 28, 2010 at 2:46 PM, Stefan Hajnoczi
<stefanha@linux.vnet.ibm.com> wrote:
> On Mon, Jun 28, 2010 at 06:02:37PM +0530, Prerna Saxena wrote:
>> [PATCH] Restore parallel building
>> This is based on :
>> http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/tracing
>>
>> Signed-off-by: Prerna Saxena <prerna@linux.vnet.ibm.com>
>
> Dependencies are not quite right yet:
>
> $ make distclean
> $ ./configure --trace-backend=simple
> $ make V=1 trace.o
> sh /home/stefanha/qemu/tracetool --simple -c < /home/stefanha/qemu/trace-events > trace.c
> sh /home/stefanha/qemu/tracetool --simple -h < /home/stefanha/qemu/trace-events > trace.h
> gcc -I/home/stefanha/qemu/slirp -Werror -m64 -fstack-protector-all -Wold-style-definition -Wold-style-declaration -I. -I/home/stefanha/qemu -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wendif-labels -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -MMD -MP -MT trace.o -MF ./trace.d -O2 -g -c -o trace.o trace.c
> In file included from trace.h:6,
> from trace.c:2:
> qemu-common.h:5:25: error: config-host.h: No such file or directory
> In file included from trace.h:6,
> from trace.c:2:
> qemu-common.h:61: error: redefinition of ‘struct iovec’
> make: *** [trace.o] Error 1
>
> I have applied it for now, however, because the implicit dependencies issue affects all of QEMU and was not caused by tracing code:
Can someone explain how the build system uses dependency rules? From
what I can tell the dependencies are generated during compilation. In
rules.mak:
# Flags for dependency generation
QEMU_DGFLAGS += -MMD -MP -MT $@ -MF $(*D)/$(*F).d
%.o: %.c
$(call quiet-command,$(CC) $(QEMU_CFLAGS) $(QEMU_DGFLAGS)
$(CFLAGS) -c -o $@ $<," CC $(TARGET_DIR)$@")
I would have expected one pass to build dependencies, then the
dependency rules are sourced into make, then the code is built. Isn't
it too late to generate dependencies when compiling the object file?
It looks like GENERATED_HEADERS is used to add explicit dependencies
on config-host.h and config-target.h. trace.o should depend on
$(GENERATED_HEADERS).
Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-06-28 14:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-28 12:32 [Qemu-devel] [PATCH][Tracing] Fix for make parallelization Prerna Saxena
2010-06-28 13:46 ` [Qemu-devel] " Stefan Hajnoczi
2010-06-28 14:00 ` Stefan Hajnoczi
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).