Stefan Hajnoczi writes:

> On Sat, Apr 14, 2012 at 12:19:08AM +0200, Lluís Vilanova wrote:
>> trace.h-timestamp: $(SRC_PATH)/trace-events $(BUILD_DIR)/config-host.mak
>> -    $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/tracetool.py 
>> --format=h --backend=$(TRACE_BACKEND) < $< > $@,"  GEN   trace.h")
>> -    @cmp -s $@ trace.h || cp $@ trace.h
>> +    $(call tracetool-gen,h,$(TRACE_BACKEND))
>> +    $(call tracetool-ci)

> Here I don't think it's worth introducing an abstraction.  While there
> is a pattern I think the abstraction actually hides what is going on
> rather than being useful.  The macros are hiding output generation, I
> find that especially troubling because you can't really tell what is
> going to happen.  It's clearer to leave these statements open coded.

I just thought it was excessively verbose. Would it work for you making it more
explicit?

     $(call tracetool-gen,$<,$@,h,$(TRACE_BACKEND))
     $(call tracetool-ci,$@)


The main points bugging me were:

* use of "quiet-command" plus explicit quiet compilation string (" GEN
  whatever").
* use of "$(PYTHON) $(SRC_PATH)/scripts/tracetool.py".


If not, I'll just drop it and instead simply replace calls to tracetool with
"$(TRACETOOL)".


Lluis

-- 
 "And it's much the same thing with knowledge, for whenever you learn
 something new, the whole world becomes that much richer."
 -- The Princess of Pure Reason, as told by Norton Juster in The Phantom
 Tollbooth

Reply via email to