In the manual section "Automatic Remaking", the following rule is suggested:
config.h: stamp-h
stamp-h: config.h.in config.status
./config.status
This actually doesn't work so well. It should be
config.h: stamp-h ;
stamp-h: config.h.in config.status
./config.status
If you look at the makefiles generated by Automake, it agrees.
I have attached a small test case. Here is what happens if you write
the rules the first way:
$ touch config.status
$ make
./config.status
$ make
cc -c -o test.o test.c
Here is what happens if you write the rules the second way:
$ touch config.status
$ make
./config.status
cc -c -o test.o test.c
This is with GNU Make 3.81.
The rule for config.h.in: stamp-h.in is probably similarly affected, but
I don't have verification for that.
make-testcase.tar.gz
Description: application/compressed-tar
