We have an application where the version number (for the purposes of
creating a dist tarball) is determined by grepping for $Revision $ in
the toplevel ChangeLog. Because this is not a static value, it means we
can't just set VERSION when running automake, since a commit could cause
it to bump without regenerating any Makefiles or such. So at the moment
our "dist" tarballs are named "foo-0" (and contain files in a foo-0
directory), instead of the proper version.
I've looked at using the dist-hook but it seems that at that point the
distdir has already been created and it's too late to rename it.
Is there any way of setting this value of VERSION for the "dist" rule at
runtime?