delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2012/06/19/12:22:23

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
X-Recipient: djgpp AT delorie DOT com
Message-ID: <4FE0A729.9030007@iki.fi>
Date: Tue, 19 Jun 2012 19:22:01 +0300
From: Andris Pavenis <andris DOT pavenis AT iki DOT fi>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120605 Thunderbird/13.0
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: Re: gcc-4.7.X and native Ada compiler for DJGPP
References: <4FDC5D93 DOT 2040204 AT iki DOT fi> <9907f873-af2f-4b2d-8b77-59ade8f3fc0b AT googlegroups DOT com>
In-Reply-To: <9907f873-af2f-4b2d-8b77-59ade8f3fc0b@googlegroups.com>
Reply-To: djgpp AT delorie DOT com

On 06/17/2012 03:48 AM, rugxulo AT gmail DOT com wrote:
> Hi,
>
> On Saturday, June 16, 2012 5:18:59 AM UTC-5, Andris Pavenis wrote:
>>
>> I'm getting the following when trying to bootstrap gcc-4.7.1 for DJGPP
>> with Ada compiler enabled:
>>
>> error: "system.ads" has restriction No_Implicit_Dynamic_Code
>> error: but the following files violate this restriction:
>> error:   "make.adb"
>> error:   "makeutl.adb"
>> error:   "prj.adb"
>> error:   "prj-env.adb"
>> error:   "prj-conf.adb"
>> error:   "prj-nmsc.adb"
>> make.exe[3]: *** [b_gnatm.adb] Error 5
>> make.exe[3]: Leaving directory `g:/build.gcc/gcc/ada/tools'
>> make.exe[2]: *** [gnattools-native] Error 2
>> make.exe[2]: Leaving directory `g:/build.gcc/gnattools'
>> make.exe[1]: *** [all-gnattools] Error 2
>> make.exe[1]: Leaving directory `g:/build.gcc'
>> make.exe: *** [bootstrap] Error 2
>>
>> Do anybody know how to fix that? I do not know Ada well enough for that
>> (or more exactly my knowledge about Ada language is close to
>> non-existent). I had the same problem also with gcc-4.7.0. This was the
>> reason why DJGPP port of Ada compiler was left out for GCC-4.7.0.
>
> I don't know Ada either. A quick Google search shows this:
>
> http://gcc.gnu.org/onlinedocs/gnat_rm/No_005fImplicit_005fDynamic_005fCode.html
>
> They seem to want to (mostly) avoid "trampolines" that require executable stack code because DEP under Windows doesn't like that. (Though I doubt DOS has the same concerns.)
>
> Anyways, a comparison of system.ads from GCC 4.1.2 and 4.6.3 shows that the former didn't have such a pragma enabled at all. I would be surprised if just removing that magically fixed it, but you could try it!
>
> "
> pragma Restrictions (No_Implicit_Dynamic_Code);
> --  We want to avoid trampolines in the compiler, so it can be used in systems
> --  which prevent execution of code on the stack, e.g. in windows environments
> --  with DEP (Data Execution Protection) enabled.
> "

Thanks.

Does not really matter for DJGPP. So had to create own copy of system.ads instead of
using generic version.

Andris



- Raw text -


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