delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2011/12/01/23:48:16

X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f
X-Recipient: djgpp-workers AT delorie DOT com
Message-ID: <4ED85600.8080400@iki.fi>
Date: Fri, 02 Dec 2011 06:37:20 +0200
From: Andris Pavenis <andris DOT pavenis AT iki DOT fi>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:8.0) Gecko/20111115 Thunderbird/8.0
MIME-Version: 1.0
To: djgpp-workers AT delorie DOT com
Subject: Re: dxe and gcc 4.6.1 difficulties.
References: <201108141841 DOT 15711 DOT juan DOT guerrero AT gmx DOT de> <CAA-ihx-4uFH7LmmwiMBe0WZEKp+dp5ECrXJAVwoGNqXfWKQEcA AT mail DOT gmail DOT com>
In-Reply-To: <CAA-ihx-4uFH7LmmwiMBe0WZEKp+dp5ECrXJAVwoGNqXfWKQEcA@mail.gmail.com>
Reply-To: djgpp-workers AT delorie DOT com

On 12/02/2011 12:28 AM, Rugxulo wrote:
> Hi,
>
> On Sun, Aug 14, 2011 at 11:41 AM, Juan Manuel Guerrero
> <juan DOT guerrero AT gmx DOT de>  wrote:
>>
>> I have tried to compile the beta version of Lua using gcc 4.6.1
>> and using DXE3 support to allow the loading of modules at runtime.
>> I get the error message below when Lua tries to load a module at runtime:
>>
>> [snip]
>> Computes the sin and cos values 0, 30, 60 and 90 degrees.
>> src/lua.exe: djgpp/libtest1.lua:13: attempt to call global 'sin_function' (a nil value)
>> stack traceback:
>>         djgpp/libtest1.lua:13: in main chunk
>>         [C]: in ?
>> ___register_frame_info: unresolved symbol in DXE module.
>> ___deregister_frame_info: unresolved symbol in DXE module.
>> ___register_frame_info: unresolved symbol in DXE module.
>> ___deregister_frame_info: unresolved symbol in DXE module.
>> make.exe: *** [test_djgpp] Error 1

It means that GCC generates some additional symbols which are later
not found. May be it is possible to avoid them by specifying
some additional GCC command line parameters.

One can try using nm.exe and assembler output of GCC to see where
these symbols appear and can something be improved by using
different GCC command line options.

Additionally these symbols should perhaps be searched from
the executable which loads DXE. Could something like that
possible?

>>
>> If I replace gcc 4.6.1 with gcc 4.4.5 or gcc 4.5.3 everthing works as expected.
>> Any suggestions, or can gcc 4.6.1 not be used with DXE?
>
> Not sure, but I did confirm this "bug" (and with 4.6.2 also).
>
> I recently discovered that GCC 4.6.x versions have some weird
> differences. For instance, I'm not sure (and heavily doubt) they were
> compiled with "stock" DJGPP, at least verified in /beta/ versions
> (which I normally prefer for silly reasons). Could it be a bug in CVS
> versions or something clashing in mixing? Dunno ....
>
> gcc.exe from 4.6.1:
>
> $Id: stub.asm built 06/28/100 11:15:04 by djasm $
>
> gcc.exe from 4.6.2:
>
> $Id: stub.asm built 2011-10-28 22:28:16 by djasm $
>
It is only caused by build of stubify used. Unfortunately
the default stack size 512K is insufficient for building GCC.
Therefore I rebuilt stubify increasing stack size in assembler
code to 1536K. Different IDs shows that I have used different builds
of stubify. Used libc.a versions used is as expected for both builds
- from DJGPP v2.03r2
- fresh CVS version
for corresponding builds. stub of both is taken from CVS version.

Andris

- Raw text -


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