On 09/17/2013 07:12 PM, Burton, Ross wrote:
On 17 September 2013 03:03, Robert Yang <[email protected]> wrote:
I don't think that the commit you mentioned is a correct fix, he changed:

gen/gtypes.h _gen/gtypes-body.h: _gen/stable-spec.xml

To:

gen/gtypes.h: _gen/gtypes-body.h
         @:
gen/gtypes-body.h: _gen/stable-spec.xml

Now if we run "make gen/gtypes.h gen/gtypes-body.h", the gen/gtypes-body.h
will only run once, this is incorrect.

But the Python script used in the second rule generates *both* files,

Ah, yes, thanks, what's your opinion on my patch ? Is it OK or should it be
re-worked ? I think that this fix is simple and easy to understand.

// Robert

which is why the current rules in telepathy-mission-control are
incorrect:

~/Local/mess/37/telepathy-mission-control/src
$ ls _gen/gtypes*
_gen/gtypes-body.h  _gen/gtypes.h

~/Local/mess/37/telepathy-mission-control/src
$ rm _gen/gtypes* -f

~/Local/mess/37/telepathy-mission-control/src
$ make _gen/gtypes.h
/usr/bin/python ../tools/glib-gtypes-generator.py \
_gen/mcd.xml _gen/gtypes mc

~/Local/mess/37/telepathy-mission-control/src
$ ls _gen/gtypes*
_gen/gtypes-body.h  _gen/gtypes.h

The anti-pattern of:

foo bar:
   this-script-generates-both-files.sh

is wrong in parallel builds.

Ross


_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Reply via email to