delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2006/11/21/11:45:09

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
Date: Tue, 21 Nov 2006 16:44:50 +0000
From: Mark Carter <me AT prviacy DOT net>
User-Agent: Thunderbird 1.5.0.8 (Windows/20061025)
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Re: make djgpp predefined variables, and some sundry questions
References: <4562f5df$0$49206$14726298 AT news DOT sunsite DOT dk> <200611211623 DOT kALGNQPQ023619 AT envy DOT delorie DOT com>
In-Reply-To: <200611211623.kALGNQPQ023619@envy.delorie.com>
Lines: 46
Message-ID: <45632d03$0$49206$14726298@news.sunsite.dk>
Organization: SunSITE.dk - Supporting Open source
NNTP-Posting-Host: 195.11.82.139
X-Trace: news.sunsite.dk DXC=60j7fA2eZ<l^Yj[LZVmDVlYSB=nbEKnkkoCW_eh^cDdkjL[>INFcKQfYgV8WBR]I\lNnCfUiZIN[m\4We8a3OZHmJ[geNBHW9ki=84M=CUo?kj
X-Complaints-To: staff AT sunsite DOT dk
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

DJ Delorie wrote:
>> It's no longer a pressing issue, but a question worth asking anyway: 
>> what DJGPP-relevant variables are predefined by make?
> 
> If you mean #defines, you can use __DJGPP__ to detect that you're
> using DJGPP, or __GNUC__ for gcc in general.
> 
> You can loko for the ${DJGPP} environment variable being set within
> make if you need to detect it there.  Or check MAKE_VERSION, or look
> for ${CC} being gcc.

Yes - this is what I was looking for. Thanks.

I managed to get a simple curses proggy working, which is nice ;) There 
are so many compilers to choose from, it's difficult to choose. In the 
past I've tried things like mingw and cygwin. They all have their pros 
and cons, I guess.


> 
>> Also, a bit lazy, I know, but are there any libraries available for 
>> processing files one line at a time,
> 
> The C library does that.  Use fgets().

D'oh!
> 
>> and is there a date/time library 
>> for calculating the day of the week,
> 
> Likewise, use mktime() and localtime()
> 
>> and other such useful calendar functions?
> 
> localtime() again.

Thanks for the reply.


I have been using DJGPP occasionally since the late 90's - although I 
don't touch C much, as you might have gathered. I've had a little snoop 
at some of the stuff in v2tk. Some of it looks quite interesting, like 
the jpeg and zlib library. I'm something of a fan of precompiled files - 
not being too enthused of the various configuration wonks that 
inevitably arise when you try to port stuff to different 
platforms/compilers.

- Raw text -


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