Minimize rebuilding

pull/425/head
Bill Somerville 2020-10-17 13:32:49 +01:00
rodzic d866d4dc33
commit d81a027063
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: D864B06D1E81618F
1 zmienionych plików z 6 dodań i 3 usunięć

Wyświetl plik

@ -106,9 +106,12 @@ testloc.sh:
hamlibdatetime.h: FORCE
echo "SHA=$(SHA)"
if test -x $(top_srcdir)/.git ; then \
echo "/* This date time is from the last non-merge commit to Hamlib. */" > $@ ;\
echo "#define HAMLIBDATETIME "\"$$(TZ=UTC git --git-dir=$(top_srcdir)/.git log --no-merges --date='format-local:%a %b %d %H:%M:%S %Y %z SHA=' --format='%cd' -n 1)$$(git --git-dir=$(top_srcdir)/.git log --no-merges | grep commit | head -n 1 | cut -c8-13)\" >> $@ ;\
cp -f $@ $(top_srcdir)/tests/$(@F) ;\
echo "/* This date time is from the last non-merge commit to Hamlib. */" > $@.tmp ;\
echo "#define HAMLIBDATETIME "\"$$(TZ=UTC git --git-dir=$(top_srcdir)/.git log --no-merges --date='format-local:%a %b %d %H:%M:%S %Y %z SHA=' --format='%cd' -n 1)$$(git --git-dir=$(top_srcdir)/.git log --no-merges | grep commit | head -n 1 | cut -c8-13)\" >> $@.tmp ;\
if test $$(diff $@.tmp $@) ; then \
mv $@.tmp $@ ;\
cp -f $@ $(top_srcdir)/tests/$(@F) ;\
fi \
fi
test -f $(top_srcdir)/tests/$(@F) || cp $(top_srcdir)/tests/$(@F).in $(top_srcdir)/tests/$(@F)
test -f $@ || cp $(top_srcdir)/tests/$(@F) $@