On Tue, Jun 28, 2011 at 06:53:01PM +0200, Lluís wrote: > Signed-off-by: Lluís Vilanova <vilan...@ac.upc.edu> > --- > .gitignore | 2 > Makefile | 1 > Makefile.objs | 4 - > scripts/tracetool | 2 > simpletrace.c | 355 > ----------------------------------------------------- > simpletrace.h | 48 ------- > trace/simple.c | 355 > +++++++++++++++++++++++++++++++++++++++++++++++++++++ > trace/simple.h | 48 +++++++ > vl.c | 2 > 9 files changed, 410 insertions(+), 407 deletions(-) > delete mode 100644 simpletrace.c > delete mode 100644 simpletrace.h > create mode 100644 trace/simple.c > create mode 100644 trace/simple.h > > diff --git a/.gitignore b/.gitignore > index 08013fc..b1db525 100644 > --- a/.gitignore > +++ b/.gitignore > @@ -2,6 +2,8 @@ config-devices.* > config-all-devices.* > config-host.* > config-target.* > +trace/*.d > +trace/*.o
These are not needed, the *.d and *.o rules already cover them. > trace.h > trace.c > trace-dtrace.h > diff --git a/Makefile b/Makefile > index b3ffbe2..fe01145 100644 > --- a/Makefile > +++ b/Makefile > @@ -170,6 +170,7 @@ clean: > rm -Rf .libs > rm -f slirp/*.o slirp/*.d audio/*.o audio/*.d block/*.o block/*.d > net/*.o net/*.d fsdev/*.o fsdev/*.d ui/*.o ui/*.d > rm -f qemu-img-cmds.h > + rm -f trace/*.o trace/*.d > rm -f trace.c trace.h trace.c-timestamp trace.h-timestamp > rm -f trace-dtrace.dtrace trace-dtrace.dtrace-timestamp > rm -f trace-dtrace.h trace-dtrace.h-timestamp > diff --git a/Makefile.objs b/Makefile.objs > index cea15e4..9a67374 100644 > --- a/Makefile.objs > +++ b/Makefile.objs > @@ -355,14 +355,14 @@ trace-dtrace.lo: trace-dtrace.dtrace > $(call quiet-command,libtool --mode=compile --tag=CC dtrace -o $@ -G -s > $<, " lt GEN trace-dtrace.o") > endif > > -simpletrace.o: simpletrace.c $(GENERATED_HEADERS) > +trace/simple.o: trace/simple.c $(GENERATED_HEADERS) > > ifeq ($(TRACE_BACKEND),dtrace) > trace-obj-y = trace-dtrace.o > else > trace-obj-y = trace.o > ifeq ($(TRACE_BACKEND),simple) > -trace-obj-y += simpletrace.o > +trace-obj-y += trace/simple.o Once more files are added into trace/ it will be useful to use the "nested" approach that the makefiles use elsewhere (e.g. block-nested-y). It avoids having to specify "trace/" for each object file in the directory. Stefan