Date: Wed, 2 Dec 1998 11:10:57 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: Gorton Zhao cc: djgpp AT delorie DOT com Subject: Re: Question to DJGPP on Win NT4 In-Reply-To: <742lt6$l7v$1@newton2.pacific.net.sg> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com On Wed, 2 Dec 1998, Gorton Zhao wrote: > I am using DJGPP at a DOS box under Windows NT 4.0 (workstation). I use > 'echo' in the makefile to convert very long command to a file, then compile > the source. Why do you at all need that trick? DJGPP programs can pass long command lines to each other, so make.exe can invoke the compiler (assuming the compiler is gcc) without any help or intermediate files. > $(DEPDIR)/%.dep : $(PSOSBSP)/%.c $(DEPDIR) $(OBJDIR) > djecho -o $(TEMPX)/$*.cmd " " -c $< -o $(OBJDIR)/$*.o -MD $(CFLAGS) > $(CPPFLAGS) > $(CC) -via $(TEMPX)/$*.cmd You need to quote the entire text that you want `echo' to write to the file. Otherwise, it treats the arguments that begin with -, like -c, as switches. Use something like this: djecho -o $(TEMPX)/$*.cmd " -c $< -o $(OBJDIR)/$*.o -MD $(CFLAGS) $(CPPFLAGS)" Btw, why did you need to rename echo into djecho?