Mail Archives: djgpp/1997/08/25/05:45:06
On 19 Aug 1997, Paul Derbyshire wrote:
> then, users can use "make nocpp" to avoid trying to compile "setup" if
> they haven't installed, and don't want, c++.
If this is at all a problem, then the Makefile could just look for itself
whether iostream.h (or whatever fails there) is installed, with a command
like this:
command.com /c if exist $(patsubst /,\\,${DJDIR})\lang\cxx\iostream.h ..
etc. Put something instead of the dots, so it will make a difference.
For example, you could invoke this command with the $(shell) function and
let it say "echo YES" if the header exists, then test with `ifeq' that
$(shell) returns YES. If it doesn't, you could invoke "make nocpp"
recursively. Anyway, something along these lines.
I don't believe that telling users to type "make nocpp" will be a
solution, since they will have to read about that in order to know ;-)
(Note: the "command.com /c" thing is deliberate, so this works even if
$(SHELL) points to Bash or some such.)
- Raw text -