Browse files

trace: rebuild generated-events.o when configuration changes

Make sure to rebuild generated-events.o when ./configure options change.
This prevents linker errors when a stale generated-events.o gets linked
with code compiled against fresh headers.  For example, try building
with ./configure --enable-trace-backend=stderr followed by ./configure

Signed-off-by: Stefan Hajnoczi <>
  • Loading branch information...
1 parent c6f18b9 commit a7373b1f61d106ef5c9710eb56e942f513dc512d Stefan Hajnoczi committed Mar 8, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 trace/Makefile.objs
@@ -11,7 +11,7 @@ $(obj)/generated-events.h-timestamp: $(SRC_PATH)/trace-events
< $< > $@," GEN $(patsubst %-timestamp,%,$@)")
@cmp -s $@ $(patsubst %-timestamp,%,$@) || cp $@ $(patsubst %-timestamp,%,$@)
-$(obj)/generated-events.c: $(obj)/generated-events.c-timestamp
+$(obj)/generated-events.c: $(obj)/generated-events.c-timestamp $(BUILD_DIR)/config-host.mak
$(obj)/generated-events.c-timestamp: $(SRC_PATH)/trace-events
$(call quiet-command,$(TRACETOOL) \
--format=events-c \

0 comments on commit a7373b1

Please sign in to comment.