On Tue, May 26, 2009 at 9:45 AM, Anthony Shipman <a...@iinet.net.au> wrote: > I've tried the example in section 3.8 Overriding Part of Another Makefile. > i.e. > > foo: > frobnicate > foo > > %: force > �...@$(MAKE) -f Makefile $@ > > force: ; > > The command 'make foo' results in > > make[1]: Makefile: No such file or directory > make[1]: *** No rule to make target `Makefile'. Stop. > make: *** [GNUmakefile] Error 2
The paragraph just above the example says this: ---- For example, if you have a makefile called `Makefile' that says how to make the target `foo' (and other targets), you can write a makefile called `GNUmakefile' that contains: ---- I.e., you *first* must have a file "Makefile" in the current directory. The error message you got says that you don't have that, so of course the example doesn't work. Since you don't have a Makefile already, why are you trying to use an example for overriding an existing makefile? > An implicit rule search is performed for the target GNUmakefile. This is not > expected. While GNU make will automatically try to rebuild its makefile, that's both A) completely expected, and B) not at all related the error message you quoted. Philip Guenther _______________________________________________ Bug-make mailing list Bug-make@gnu.org http://lists.gnu.org/mailman/listinfo/bug-make