
21 Oct
2008
21 Oct
'08
10:33 p.m.
Hi Wolfgang,
--- a/Makefile +++ b/Makefile @@ -368,6 +368,10 @@ $(VERSION_FILE): @( printf '#define U_BOOT_VERSION "U-Boot %s%s"\n' "$(U_BOOT_VERSION)" \ '$(shell $(CONFIG_SHELL) $(TOPDIR)/tools/setlocalversion $(TOPDIR))' \ ) > $@.tmp
@( printf '#define U_BOOT_DATE "%s"\n' '$(shell date +"%b %d %C%y")' \
) >> $@.tmp
@( printf '#define U_BOOT_TIME "%s"\n' '$(shell date +"%T")' \
@cmp -s $@ $@.tmp && rm -f $@.tmp || mv -f $@.tmp $@) >> $@.tmp
Please do not do this here. Use a separate target instead.
As you can see, we take care NOT to create a new VERSION_FILE for each build, but only when it eally changed. Your change forces it to change with each build, which we tried to avoid.
How does a $(TIMESTAMP_FILE) target of $(obj)include/timestamp_autogenerated.h sound? An include/timestamp.h file would also be added which includes included/timestamp_autogenerated.h.
Best, Peter