> The cases you have to look at are the ones with move-if-change. You > have to make sure that if the file does not change, none of the > dependencies are considered to have changed. > > For example in > > multilib.h: s-mlib; @true > s-mlib: $(srcdir)/genmultilib Makefile > ... > $(SHELL) $(srcdir)/../move-if-change tmp-mlib.h multilib.h > $(STAMP) s-mlib > > we need the property that if multilib.h changes, everything that > depends upon it gets rebuilt. If genmultilib or Makefile changes, we > must try rebuilding multilib.h. However, if multilib.h does not then > change, then things that depend upon multilib.h should not get rebuilt > for that reason. > > The @true is necessary so that make checks whether the timestamp of > multilib.h changed before deciding that it will rebuild things that > depend upon multilib.h. > > Can you restate your plan based on that, showing examples which use > move-if-change? Thanks. Unfortunately no :( but I think that I can document that :)
I will make a small example and add a comment to Makefile.in describing the use of stamps with mkconfig.sh and move-if-change. One small improvement would be to create the dependencies on s-gtype automatically. At least the Make-lang.in s wouldn't need to know about the stamps. Maybe I can implement this. > Ian Thank you very much, Rafael
