On Thu, Jun 23, 2011 at 4:51 PM, Nick Bowler <nbow...@elliptictech.com> wrote: > On 2011-06-23 16:25 -0400, Jie Zhang wrote: >> > With Posix make Makefiles, it would be doable with some more work, but >> > automake doesn't. With GNU make extensions used in the Makefile.am, it >> > is almost impossible without implementing a large set of GNU make >> > extension parsing in automake as well. >> > >> With my limited Makefile knowledge, I thought it was enough to look >> one line ahead to see if the next line started with a $.RECIPEPREFIX. >> If yes, this rule has a recipe, if no, this rule is only for >> dependence. > > Nope. One counterexample with POSIX makefiles is that they can have > rules with commands entirely on one line. For instance > > foo: ; echo hello > $@ > But this can be handled without look ahead.
Jie