From: Peter Verthez Date: Sun, 20 Oct 2002 13:42:44 +0000 (+0000) Subject: Re-added (using GNU make anyway). X-Git-Url: https://git.dlugolecki.net.pl/?a=commitdiff_plain;h=435400ad65aed40472353d3816ca95249a8f61a7;p=gedcom-parse.git Re-added (using GNU make anyway). --- diff --git a/Makefile.inc b/Makefile.inc new file mode 100644 index 0000000..dd724ba --- /dev/null +++ b/Makefile.inc @@ -0,0 +1,23 @@ +## File to include in other Makefile's, defining common commands and rules +# $Id$ +# $Name$ + +define replace-VERSION + cd $(distdir); \ + for file in $(VERSIONED_FILES); do \ + sed 's/\@VERSION\@/${VERSION}/' $$file > $$file.new; \ + rm $$file; \ + mv $$file.new $$file; \ + done +endef + +%.tabgen.h: %.tab.h + if [ ! -r $(srcdir)/$@ ] ; \ + then \ + touch $(srcdir)/$@; \ + fi + if ! diff -q $< $(srcdir)/$@ > /dev/null; \ + then \ + rm $(srcdir)/$@; \ + cp $(srcdir)/$< $(srcdir)/$@; \ + fi