www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Windows GDC and libgcc_s_sjlj-1.dll

reply Andre Tampubolon <andre lc.vlsm.org> writes:
I just tried GDC on Windows, and I found out that the executables
created are linked into libgcc_s_sjlj-1.dll. Will it be possible to get
rid of the dependency on this DLL?
Jul 20 2011
parent reply Kagamin <spam here.lot> writes:
Andre Tampubolon Wrote:

 I just tried GDC on Windows, and I found out that the executables
 created are linked into libgcc_s_sjlj-1.dll. Will it be possible to get
 rid of the dependency on this DLL?

Yes, there's a static version of libgcc, you should play with ld a bit.
Jul 21 2011
parent reply Daniel Green <venix1 gmail.com> writes:
On 7/21/2011 6:44 AM, Kagamin wrote:
 Andre Tampubolon Wrote:

 I just tried GDC on Windows, and I found out that the executables
 created are linked into libgcc_s_sjlj-1.dll. Will it be possible to get
 rid of the dependency on this DLL?

Yes, there's a static version of libgcc, you should play with ld a bit.

Jul 21 2011
parent reply Daniel Green <venix1 gmail.com> writes:
On 7/21/2011 6:52 PM, Daniel Green wrote:
 On 7/21/2011 6:44 AM, Kagamin wrote:
 Andre Tampubolon Wrote:

 I just tried GDC on Windows, and I found out that the executables
 created are linked into libgcc_s_sjlj-1.dll. Will it be possible to get
 rid of the dependency on this DLL?

Yes, there's a static version of libgcc, you should play with ld a bit.


http://gcc.gnu.org/onlinedocs/gcc-4.5.3/gcc/Link-Options.html#Link-Options
Jul 21 2011
parent reply Andre Tampubolon <andre lc.vlsm.org> writes:
-static-libgcc didn't work

gdc dhello.d -o dhello -static-libgcc
c:/mingw/bin/../lib/gcc/mingw32/4.5.2/../../../../mingw32/bin/ld.exe:
cannot find -lgcc_eh
c:/mingw/bin/../lib/gcc/mingw32/4.5.2/../../../../mingw32/bin/ld.exe:
cannot find -lgcc_eh
collect2: ld returned 1 exit status

:(

On 22-Jul-11 5:55 AM, Daniel Green wrote:
 On 7/21/2011 6:52 PM, Daniel Green wrote:
 On 7/21/2011 6:44 AM, Kagamin wrote:
 Andre Tampubolon Wrote:

 I just tried GDC on Windows, and I found out that the executables
 created are linked into libgcc_s_sjlj-1.dll. Will it be possible to get
 rid of the dependency on this DLL?

Yes, there's a static version of libgcc, you should play with ld a bit.


http://gcc.gnu.org/onlinedocs/gcc-4.5.3/gcc/Link-Options.html#Link-Options

-- - Andre Tampubolon -
Jul 21 2011
parent reply Daniel Green <venix1 gmail.com> writes:
On 7/21/2011 11:16 PM, Andre Tampubolon wrote:
 -static-libgcc didn't work

 gdc dhello.d -o dhello -static-libgcc
 c:/mingw/bin/../lib/gcc/mingw32/4.5.2/../../../../mingw32/bin/ld.exe:
 cannot find -lgcc_eh
 c:/mingw/bin/../lib/gcc/mingw32/4.5.2/../../../../mingw32/bin/ld.exe:
 cannot find -lgcc_eh
 collect2: ld returned 1 exit status

 :(

My copy behaves the same way. I think it may be due to a patch I didn't apply during the build process. I am recompiling with that patch applied. I'll post back when it's done.
Jul 22 2011
parent Daniel Green <venix1 gmail.com> writes:
On 7/22/2011 5:36 PM, Daniel Green wrote:
 My copy behaves the same way. I think it may be due to a patch I didn't
 apply during the build process. I am recompiling with that patch
 applied. I'll post back when it's done.

patch included have been uploaded. https://bitbucket.org/goshawk/gdc/downloads/
Jul 23 2011