FWIW, this is problem is caused by infinite recursion. The first invocation in the OBJDIR has the correct path to the Makefile, since it was invoked from the source directory and CURDIR points to the source. But when the make command is invoked a second time, from OBJDIR, CURDIR points to OBJDIR as it should.
Doug -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Doug Konrad Sent: January-22-14 11:41 AM To: [email protected] Cc: [email protected] Subject: RE: Is -C @ magical? Paul, This has become a moot problem for me - when I came across this, I was trying to work around another problem, which I have fixed. Thanks for your attention to this. Doug -----Original Message----- From: Doug Konrad Sent: January-21-14 1:19 PM To: Doug Konrad; [email protected] Cc: [email protected] Subject: RE: Is -C @ magical? Paul, I missed one of your questions - the embedded space in the error message was accidently added by me when obscuring the path. Doug -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Doug Konrad Sent: January-21-14 1:13 PM To: [email protected] Cc: [email protected] Subject: RE: Is -C @ magical? Paul, I changed the path to ``/.../some/other/path`` to obscure details I shouldn't publicize. I did make one change - I removed a $(TOP). Here is a more accurate representation: MAKETARGET = $(MAKE) --no-print-directory -C $(TOP)/.../some/other/path -f $(CURDIR)/Makefile \ SRCDIR=$(CURDIR) $(MAKECMDGOALS) I placed an echo of $(TOP)/.../some/other/path immediately prior to the invocation of MAKETARGET and that path matched the path in the error message exactly. $(TOP) contains only ``/home/vmuser/Work/software-internal`` . Doug -----Original Message----- From: Paul Smith [mailto:[email protected]] Sent: January-21-14 12:27 PM To: Doug Konrad Cc: [email protected] Subject: Re: Is -C @ magical? On Tue, 2014-01-21 at 20:08 +0000, Doug Konrad wrote: > Paul, > > If I use the MAKETARGET line as I entered it in my email, everything works as > it should. However, if I edit the line to be: > > MAKETARGET = $(MAKE) --no-print-directory -C /.../some/other/path -f > $(CURDIR)/Makefile \ > SRCDIR=$(CURDIR) $(MAKECMDGOALS) > > Then I get > > make[3]: *** No rule to make target `/.../some/other/path /Makefile'. Stop. > > It seems that $(CURDIR)/Makefile is pointing somewhere else. Is the error message above verbatim, including the embedded space in the pathname after "path" and before "/Makefile"? That's ultra-bizarre. Can you provide a reproducible case (cut down)? You're really just replacing the $@ with a simple explicit path exactly as you show above? No quoting, make variables, etc.? Can you also paste the recursive make command that make is invoking? You might have to remove the "@" so it will be printed. That should definitely be illuminating. _______________________________________________ Help-make mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-make _______________________________________________ Help-make mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-make _______________________________________________ Help-make mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-make
