Date: Sun, 19 Mar 2000 08:01:52 +0600 (LKT) From: Kalum Somaratna aka Grendel X-Sender: root AT darkstar DOT grendel DOT net To: djgpp AT delorie DOT com Subject: Re: Compiling with DJGPP.... how can I speed it? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com Errors-To: dj-admin AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Sat, 18 Mar 2000, Damian Yerrick wrote: > On Sat, 18 Mar 2000 21:25:59 +0200, "Tero Laitinen" > wrote: > > >Hi. How can I speed up compilation process in DJGPP? I have coded one game > >over 10000 lines and it takes a *long* time to compile..... Should I move > >some code to a library or something? > > Just split it up among several .c files and then: > gcc -c main.c > gcc -c ai.c > gcc -c control.c > gcc *.o -lalleg -o foo.exe > > Only issue the gcc -c commands for files that have changed. > GNU make will handle this for you very nicely. well the FAQ says that on a p-166 1000 lines of source code persecond can be compiled using -O2. So it follows that on a p-166 your 10000 line program would take about 10 secs to compile. a long time indeed. But if your machine is better there might be some other reason for the slow down, like maybe not enough memory so that gcc starts paging etc. So could you please just post the output of go32-v2.exe. Also the FAQ section 7.1 has info about slow compiling etc, you might wnat to take a look at it. Grendel Hi, I'm a signature virus. plz set me as your signature and help me spread :)