Rename your static makefile to something different, and generate the makefile as you normally would with the Autotools, outputting makefile or Makefile, not Makefile.test.
This is solved by not naming your Automake-generated makefile anything other than one of the recognized filename patterns, "makefile" (all lowercase) being the first and most portable. I just tried the same thing, and all it does is $(MAKE) $(AM_MAKEFLAGS) all-recursive
, which expands to make all-recursive
for me.
In other words, Automake cannot handle the concept of makefiles with alternate filenames, mainly because in order to generate the correct code, it would need to know about them. Since it doesn't (and possibly cannot), it is forced to assume a default makefile filename.
The ability to rename an input/output filename probably was not meant for this. It was created, if you can infer the reason from the manual's example, due to the DOS limitation of the 8.3 filename; config.h.in isn't a valid filename, so you must map the input file generating config.h to config.hin for example. Using it to rename the makefile generated from Makefile.in or whatever filename you used obviously doesn't work.
I hope this helps.