ftp.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2011/07/26/07:02:35

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
X-Recipient: djgpp AT delorie DOT com
Message-ID: <4E2E9EBE.6090708@iki.fi>
Date: Tue, 26 Jul 2011 14:02:22 +0300
From: Andris Pavenis <andris DOT pavenis AT iki DOT fi>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20110707 Thunderbird/5.0
MIME-Version: 1.0
To: Ozkan Sezer <sezeroz AT gmail DOT com>
CC: djgpp AT delorie DOT com
Subject: Re: DJGPP_MINOR no longer defined?
References: <CAA2C=vAhTVc9f3coSdkT_r_fpXo0miZjCCQ1w+Bo6Gmv+t3Upg AT mail DOT gmail DOT com> <4E2E5269 DOT 70402 AT iki DOT fi> <CAA2C=vAzOz1fSHXHsXpa39WVsctdpGBfMPwM_FwpCmMdrKyw9Q AT mail DOT gmail DOT com> <CAA2C=vA+6Td-ZG=-GOaXdwOuXwgS9jCMCa3woMVmVPYh4ogdYw AT mail DOT gmail DOT com> <4E2E8B14 DOT 2060204 AT iki DOT fi> <CAA2C=vA3MkR-YF=Z1hvnqKA5ZRRGXh_9BmCGkjpE+d1f1VyExQ AT mail DOT gmail DOT com>
In-Reply-To: <CAA2C=vA3MkR-YF=Z1hvnqKA5ZRRGXh_9BmCGkjpE+d1f1VyExQ@mail.gmail.com>
Reply-To: djgpp AT delorie DOT com

On 07/26/2011 12:48 PM, Ozkan Sezer wrote:
> On Tue, Jul 26, 2011 at 12:38 PM, Andris Pavenis<andris DOT pavenis AT iki DOT fi>  wrote:
>> On 07/26/2011 12:33 PM, Ozkan Sezer wrote:
>>> On Tue, Jul 26, 2011 at 8:51 AM, Ozkan Sezer<sezeroz AT gmail DOT com>    wrote:
>>>> On Tue, Jul 26, 2011 at 8:36 AM, Andris Pavenis<andris DOT pavenis AT iki DOT fi>
>>>>   wrote:
>>>>> On 07/26/2011 01:02 AM, Ozkan Sezer wrote:
>>>>>> I use __DJGPP_MINOR__ to understand whether I have djgpp>=2.04 or not.
>>>>>> In more recent versions of gcc, specifically starting with gcc>=4.3.0,
>>>>>> DJGPP_MINOR is no longer defined and djgpp.ver is no longer generated.
>>>>>> Is there a specific reason?  (If this is a well known thing, sorry.)
>>>>> You have to include sys/version.h or some other header which includes it
>>>>> to get DJGPP_MINOR
>>>>>
>>>> I know that.  However, gcc-3.x and gcc<= 4.2.x already did that by
>>>> itself and defined the macro, which is no longer the case with gcc>=
>>>> 4.3.x
>>>>
>>> Specifically, the t-djgpp change, i.e.:
>>>
>>> --- t-djgpp~1   2005-05-28 12:36:36.000000000 +0000
>>> +++ t-djgpp     2005-05-28 18:58:38.000000000 +0000
>>> @@ -1,2 +1,10 @@
>>>   # Location of DJGPP's header directory.
>>>   NATIVE_SYSTEM_HEADER_DIR=$(DJDIR)/include
>>> +
>>> +# We should have djgpp.ver before we can compile anything
>>> +EXTRA_PARTS += djgpp.ver
>>> +# djgpp.ver is needed for compilation, so we need it also here
>>> +EXTRA_PASSES += djgpp.ver
>>> +
>>> +djgpp.ver:
>>> +       echo '#include<sys/version.h>'>djgpp.ver
>>>
>>> ... is no longer being done.  And the old djgpp.h change of:
>>>
>>>   #define CPP_SPEC "-remap %{posix:-D_POSIX_SOURCE} \
>>> -  -imacros %s../include/sys/version.h"
>>> +  %{!nostdinc:-imacros %sdjgpp.ver}"
>>>
>>> ... just turned into this:
>>>
>>> -#define CPP_SPEC "-remap %{posix:-D_POSIX_SOURCE} \
>>> -  -imacros %s../include/sys/version.h"
>>> +#define CPP_SPEC "-remap %{posix:-D_POSIX_SOURCE}"
>>>
>>> ... eliminating the djgpp.ver mechanism.
>>>
>>> Any specific reasons?
>>>
>> Now I remember why I removed it:
>>
>> including sys/version.h this way did not work properly in GCC
>> build process any more (in some cases it was not found at
>> all)
> Hmm, IIRC, sys/version.h is a djgpp>= 2.02 thing.  Would that
> be the reason?  If that is the case, a configury trick maybe???
>
No. In some conditions xgcc.exe did not find djgpp.ver while
bootstrapping gcc and as result I got build error.

I have not tried with newer versions any more though.

Also versions before 2.03 are not expected to be used with new
GCC versions.



- Raw text -


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