[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
missing --run/not run
From: |
Norman Gray |
Subject: |
missing --run/not run |
Date: |
Fri, 29 Aug 2003 22:56:50 +0100 |
Greetings,
We as a project have decided to go the route of checking
autotool-generated files into our CVS repository, and as a result are
discovering the full subtleties of the consequences of that, in
particular the issues concerning timestamps in checked-out files. I
think I've addressed this problem adequately (and I'm asking for advice
on that), but it might be that automake can fairly straightforwardly
help make this easier.
The problem is, of course, the `missing' script, and what happens when
a checked-out generated file apparently needs to be rebuilt on a
developer's machine. The `missing --run' mechanism works fine when the
locally-installed autoconf is sufficiently up-to-date to work, and also
when there is _no_ autoconf installed, however it can fail if there
_is_ a local autoconf, but it is too old to process the
configure.{in,ac} file correctly.
One of the solutions mentioned in the automake manual is to use a
script to simply update the timestamps of generated files, and mentions
that the GCC folk do this. I've looked at this script, and while it
surely works for them, it's not generic, and it's fragile. However,
this is essentially what the `missing' script does when it's invoked
without the --run option, which means that the problem turns into that
of how to suppress that option in the specific case when you know you
simply need to update timestamps. There seems to be two routes:
First is to write a wrapper for `make' which edits the Makefile with
"sed 's/missing *--run/missing /", then invokes make on that makefile.
This works for me, as far as I've been able to test it (always tricky
in these situations).
The second route is to have the Makefile include lines like
missing_run=--run
...
AUTOCONF = ${SHELL} /blah/blah/missing $(missing_run) autoconf
That works as usual when invoked as usual, but the command
make missing_run=
is effectively the update-the-timestamps script, and perfectly generic.
Since it never actually attempts to run
autoconf/automake/autoheader/etc, it is completely independent of the
versions which are or are not installed on the local machine. This
also works for me (with hand-hacking of the Makefile, admittedly,
rather than hacking local m4 macros)
So, questions:
Is this in fact a useful thing to do, or have I missed some obvious
showstopping problem?
If the second route is in fact useful, is this something it might be
handy to include in the Makefile that automake/autoconf generates? Or
is this really an autoconf question, and not an automake one? -- I'm a
little confused.
All the best,
Norman
--
----------------------------------------------------------------------
Norman Gray http://www.astro.gla.ac.uk/users/norman/
Physics and Astronomy, University of Glasgow address@hidden
- missing --run/not run,
Norman Gray <=