delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1993/10/11/13:35:07

Date: Mon, 11 Oct 93 13:30:10 -0400
From: DJ Delorie <dj AT ctron DOT com>
To: kunst AT prl DOT philips DOT nl
Cc: davis AT pacific DOT mps DOT ohio-state DOT edu, djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Re: gcc call too long (>128)

> This is what I use inside my makefiles. It's simple, and works !
> (The only limitation is that you have to have a separate 
> directory for each program you want to compile and link.)
>
> OBJS = a.o b.o c.o d.o e.o f.o g.o
>
> prog.lnk: $(OBJS)
>         -del prog.lnk
>         for %o in (*.o) do echo %o >>prog.lnk   # MS-DOS batch language
>
> prog: prog.lnk
> 	gcc -o prog @prog.lnk -lm 

Since go32 knows about wildcards, you could have just as easily done
this:

	prog : $(OBJS)
		gcc -o prog *.o -lm



- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019