returning the sorted set of sources in _Automoc::__call__ actually returns a list sorted on object pointers
Originally reported by Danny Valente:
in the method _Automoc::call, a sorted set of sources are returned from the emitter. The call to "sorted" is done on a set of Entry objects however.
A cmp argument is needed to be passed to the sorted function in order to sort on the file names correctly instead.
Changing the line to this:
return (target, sorted(set(out_sources), lambda x,y: cmp(str(x),str(y))))
fixes the poblem.
Otherwise, the scons builds again because the dependencies order has changed in most cases.