GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
I expected an include directive to behave exactly as if the contents of the
included file was inline in the Makefile. But I'm seeing a case where it's
not.
I'm wondering if I'm doing something wrong, having the wrong expectations,
or it's a bug.
As the following shows, when using an include, I get an extra "Nothing to
be done for `all'." At least, I wasn't expecting it.
It's almost like, after processing the include, and performing the action,
make reinvokes itself.
Oh. Just did a test, and if I put a dummy command in for all:
all: second-all
:
Then it works as expected.
Comments?
Thanks,
mrc
nexus@thune[2:16pm]/usr/src/.sbuild(788) cat Makefile
all: second-all
include foo.mak
second-all: $(ALL)
nexus@thune[2:17pm]/usr/src/.sbuild(789) cat foo.mak
ALL+=foo.mak
foo.mak: foo.src
touch foo.mak
nexus@thune[2:18pm]/usr/src/.sbuild(790) touch foo.src
nexus@thune[2:18pm]/usr/src/.sbuild(791) make
touch foo.mak
make: Nothing to be done for `all'.
nexus@thune[2:19pm]/usr/src/.sbuild(795) cat Makefile.2
all: second-all
ALL+=foo.mak
foo.mak: foo.src
touch foo.mak
second-all: $(ALL)
nexus@thune[2:19pm]/usr/src/.sbuild(796) !tou
touch foo.src
nexus@thune[2:19pm]/usr/src/.sbuild(797) make -f Makefile.2
touch foo.mak
--
Mike Castle Life is like a clock: You can work constantly
[EMAIL PROTECTED] and be right all the time, or not work at all
www.netcom.com/~dalgoda/ and be right at least twice a day. -- mrc
We are all of us living in the shadow of Manhattan. -- Watchmen
_______________________________________________
Bug-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-make