From: Nick Bowler Date: Thu, 29 Sep 2011 00:03:35 +0000 (-0400) Subject: Update timestamps on generated header files before distributing them. X-Git-Tag: v1~93 X-Git-Url: https://git.draconx.ca/gitweb/cdecl99.git/commitdiff_plain/02c94c5f947854e94b1748837dc7277cd1106806 Update timestamps on generated header files before distributing them. Otherwise we risk breaking VPATH builds from the tarball, as make may attempt to regenerate the headers. --- diff --git a/Makefile.am b/Makefile.am index 7c2099b..de6c066 100644 --- a/Makefile.am +++ b/Makefile.am @@ -120,6 +120,15 @@ uninstall-mo: src/scan.c src/scan.h: src/scan.stamp src/parse.c src/parse.h: src/parse.stamp +# The flex/bison rules refrain from updating unchanged headers for the +# convenience of developers, but the headers must be distributed with +# up-to-date timestamps, otherwise make will try to update them in a fresh +# VPATH build. +dist-hook: update-headers +update-headers: + touch -c '$(distdir)/src/scan.h' + touch -c '$(distdir)/src/parse.h' + # Supporting rules for bison/flex. BISON_V = $(BISON_V_$(V))