www.digitalmars.com         C & C++   DMDScript  

D.gnu - MinGW Release. D2.058 x86-64 20120428

reply Daniel Green <venix1 gmail.com> writes:
** Fixes, previous unresolved _Dmodule_ref **

Please post all issues in D.gnu or on GDC's site 
https://bitbucket.org/goshawk/gdc

Due to the use of a newer runtime than TDM64-GCC it is **recommended** 
to install a copy specifically for GDC.

Features
  **ALPHA** As in, D2.058 support is still new.
  * D2.058
  * Debug information available using gnu-debuglink.
  * Removed D1(Did anyone use this featuer?).
    * Due to current system breaking with repository changes and D1
      being discontinued at the end of the year.
  * binutils with TLS patches
  * mingw-w64-runtime with TLS and stdio fixes.
  * GCC 4.6.1 with TLS patches

Installation instructions:

1. Download and install TDM MinGW64
2. Extract the downloaded archive into the base of the newly installed 
TDM install.

If you've done this before, you can just do step 2.

MinGW64 installer
http://tdm-gcc.tdragon.net/

GDC binary
https://bitbucket.org/goshawk/gdc/downloads/gcc-4.6.1-tdm64-1-gdc-7e1a98da2769-20120428-D2.058.7z

Known issues:
  * May break TDM64 C++.
  * Field-less structs will throw a null this exception.  When formatted 
by std.format.  runnable/test23.d
Apr 28 2012
next sibling parent reply Dmitry Olshansky <dmitry.olsh gmail.com> writes:
On 28.04.2012 21:08, Daniel Green wrote:
 ** Fixes, previous unresolved _Dmodule_ref **

Nice, it works so far :) And where as previous version promptly segfaulted on my regex benchmark this one goes through. And the compiled binary performance is not bad either: Small test - searching for all \S+ \S+ (rough "email") in 40Mb of man-like text. dmd: 5.48sec gdc: 3.30sec Cool, surely gone use it side by side with dmd. P.S. Command line options: dmd -O -release -noboundscheck gdc -Ofast -frelease -- Dmitry Olshansky
Apr 28 2012
next sibling parent reply Daniel Green <venix1 gmail.com> writes:
On 4/30/2012 6:18 AM, Manu wrote:
 I guess the etc.c... libs didn't make the cut :(

It was sort of an intermittent release, to get it out and tested. To update the lib status, zlib is already part of libgphobos2.a. If you inspect the library you'll see it's object files. If you're having specific zlib errors, you should share them. sqlite.o is easy enough to build and can be put into libgphobos.a. Being public domain helps, I'll add it to the build process. Curl is the only tricky one. It actually has configuration options and probably dependencies. Is there a list of what features D requires curl to support?
Apr 30 2012
parent reply Daniel Green <venix1 gmail.com> writes:
On 4/30/2012 2:49 PM, Manu wrote:
     I also built sqlite, but it's complaining with lots of:

     C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
     `D4demu5tools8sqlitedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9ErrorCode':
     D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined reference
     to `sqlite3_exec'
     C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
     `D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv':
     D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined reference
     to `sqlite3_close'
     C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
     `D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9ErrorCode':
     D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined reference
     to `sqlite3_open'
     etc...


     Any ideas?

Build order? binutils isn't smart(purposefully so?) when it comes to symbol resolution. The symbol must be declared after it is used. I would check the -v output and see where your library is in relation to the object file.
     Here's how I built sqlite, in case I did something wrong:
     gcc -c sqlite3.c -m64 -O3  -> sqlite3.o
     ar rs libsqlite.a sqlite3.o    -> sqlite.a

This would save you the need to add -lsqlite and ensure that phobos symbols are properly resolved as well. As Iain suggested, this may be what GDC will start doing. ar q libgphobos2.a sqlite3.o Here's the size with -O2, -O3 for 32 and 64 bit. -rw-r--r-- 1 venix Administrators 742K Apr 30 23:23 sqlite3-m32-03. -rw-r--r-- 1 venix Administrators 565K Apr 30 23:21 sqlite3-m32.o -rw-r--r-- 1 venix Administrators 755K Apr 30 23:30 sqlite3-m64-03. -rw-r--r-- 1 venix Administrators 579K Apr 30 23:32 sqlite3-m64.o
 Actually, I just tried -m64 and the _Dmodule_ref errors were all gone...
 switched back to -m32 and they were back again...
 User error? What are they about?

_Dmodule_ref. In the last release, they reorganized some module initialization code causing GDC/MinGW to not use define/use _Dmodule_ref initialization. Currently, there is an issue with multilib building on MinGW. I had to manually compile and extract libphobos for the release. It's possible I missed something.
Apr 30 2012
parent Daniel Green <venix1 gmail.com> writes:
On 5/1/2012 1:53 AM, Iain Buclaw wrote:
 no _Dmodule_ref would probably mean no object_.d was compiled in.

In D2.058, the _Dmodule_ref code was moved to minfo.d. I didn't properly move the GNU specific stuff on the first build, problem didn't surface until I compiled it with MinGW. They reduced it to OSX, Posix for including _Dmodule_ref. Which is why linux didn't exhibit the same problems. I added it back but there's a chance the 32-bit library wasn't updated properly.
May 01 2012
prev sibling next sibling parent Iain Buclaw <ibuclaw ubuntu.com> writes:
On 30 April 2012 16:33, Daniel Green <venix1 gmail.com> wrote:
 On 4/30/2012 6:18 AM, Manu wrote:
 I guess the etc.c... libs didn't make the cut :(

It was sort of an intermittent release, to get it out and tested. To update the lib status, zlib is already part of libgphobos2.a. =A0If yo=

 inspect the library you'll see it's object files. =A0If you're having spe=

 zlib errors, you should share them.

 sqlite.o is easy enough to build and can be put into libgphobos.a. Being
 public domain helps, I'll add it to the build process.

 Curl is the only tricky one. =A0It actually has configuration options and
 probably dependencies. =A0Is there a list of what features D requires cur=

 support?

SQLite comes as a single source file if I recall correctly, and could be added to the libphobos build folder under libphobos/sqlite. In future when (or if) shared libraries are supported, can remove the source file and have these as dependencies for building libphobos, which are linked in during compilation of libgphobos.so --=20 Iain Buclaw *(p < e ? p++ : p) =3D (c & 0x0f) + '0';
Apr 30 2012
prev sibling next sibling parent Manu <turkeyman gmail.com> writes:
--20cf3074d75840c32d04bee98fdd
Content-Type: text/plain; charset=UTF-8

On 30 April 2012 18:40, Iain Buclaw <ibuclaw ubuntu.com> wrote:

 On 30 April 2012 16:33, Daniel Green <venix1 gmail.com> wrote:
 On 4/30/2012 6:18 AM, Manu wrote:
 I guess the etc.c... libs didn't make the cut :(

It was sort of an intermittent release, to get it out and tested. To update the lib status, zlib is already part of libgphobos2.a. If you inspect the library you'll see it's object files. If you're having

 zlib errors, you should share them.

 sqlite.o is easy enough to build and can be put into libgphobos.a. Being
 public domain helps, I'll add it to the build process.

 Curl is the only tricky one.  It actually has configuration options and
 probably dependencies.  Is there a list of what features D requires curl

 support?

SQLite comes as a single source file if I recall correctly, and could be added to the libphobos build folder under libphobos/sqlite. In future when (or if) shared libraries are supported, can remove the source file and have these as dependencies for building libphobos, which are linked in during compilation of libgphobos.so

I seem to be getting a lot of these with the latest build trying to build a windows project (Daniel: the same repo I referred to in that bug report) c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(ti_Aint.o): In function `rt.typeinfo.ti_Aint._D2rt8typeinfo7ti_Aint9__modinitFZv': C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: undefined reference to `_Dmodule_ref' C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: undefined reference to `_Dmodule_ref' c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(conv.o): In function `std.conv._D3std4conv9__modinitFZv': C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../../gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_ref' C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../../gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_ref' etc... I also built sqlite, but it's complaining with lots of: C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function `D4demu5tools8sqlitedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9ErrorCode': D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined reference to `sqlite3_exec' C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function `D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv': D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined reference to `sqlite3_close' C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function `D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9ErrorCode': D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined reference to `sqlite3_open' etc... Any ideas? Here's how I built sqlite, in case I did something wrong: gcc -c sqlite3.c -m64 -O3 -> sqlite3.o ar rs libsqlite.a sqlite3.o -> sqlite.a --20cf3074d75840c32d04bee98fdd Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div class=3D"gmail_extra"><div class=3D"gmail_quote">On 30 April 2012 18:4= 0, Iain Buclaw <span dir=3D"ltr">&lt;<a href=3D"mailto:ibuclaw ubuntu.com" = target=3D"_blank">ibuclaw ubuntu.com</a>&gt;</span> wrote:<br><blockquote c= lass=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;= padding-left:1ex"> <div class=3D"HOEnZb"><div class=3D"h5">On 30 April 2012 16:33, Daniel Gree= n &lt;<a href=3D"mailto:venix1 gmail.com">venix1 gmail.com</a>&gt; wrote:<b= r> &gt; On 4/30/2012 6:18 AM, Manu wrote:<br> &gt;&gt;<br> &gt;&gt; I guess the etc.c... libs didn&#39;t make the cut :(<br> &gt;<br> &gt;<br> &gt; It was sort of an intermittent release, to get it out and tested.<br> &gt;<br> &gt; To update the lib status, zlib is already part of libgphobos2.a. =C2= =A0If you<br> &gt; inspect the library you&#39;ll see it&#39;s object files. =C2=A0If you= &#39;re having specific<br> &gt; zlib errors, you should share them.<br> &gt;<br> &gt; sqlite.o is easy enough to build and can be put into libgphobos.a. Bei= ng<br> &gt; public domain helps, I&#39;ll add it to the build process.<br> &gt;<br> &gt; Curl is the only tricky one. =C2=A0It actually has configuration optio= ns and<br> &gt; probably dependencies. =C2=A0Is there a list of what features D requir= es curl to<br> &gt; support?<br> <br> </div></div>SQLite comes as a single source file if I recall correctly, and= could<br> be added to the libphobos build folder under libphobos/sqlite.<br> <br> In future when (or if) shared libraries are supported, can remove the<br> source file and have these as dependencies for building libphobos,<br> which are linked in during compilation of libgphobos.so<br></blockquote><di= v><br></div><div>I seem to be getting a lot of these with the latest build = trying to build a windows project (Daniel: the same repo I referred to in t= hat bug report)</div> <div><br></div><div><div>c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1= /../../../../lib32/libgphobos2.a(ti_Aint.o): In function `rt.typeinfo.ti_Ai= nt._D2rt8typeinfo7ti_Aint9__modinitFZv&#39;:</div><div>C:\crossdev\gdc64\v2= \build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1= /libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: undefined reference to `_Dm= odule_ref&#39;</div> <div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime= /../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: un= defined reference to `_Dmodule_ref&#39;</div><div>c:/mingw64/bin/../lib/gcc= /x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(conv.o): In funct= ion `std.conv._D3std4conv9__modinitFZv&#39;:</div> <div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../..= /gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_ref&#39= ;</div><div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../.= ./../../gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_= ref&#39;</div> </div><div>etc...</div><div><br></div><div><br></div><div>I also built sqli= te, but it&#39;s complaining with lots of:</div><div><br></div><div><div>C:= \Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function `D4demu5tools8sq= litedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9ErrorCode&#39;:</div> <div>D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined reference t= o `sqlite3_exec&#39;</div><div>C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCi= c.o: In function `D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv&#39;:</div><div> D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined reference to `sq= lite3_close&#39;</div><div>C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o:= In function `D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9E= rrorCode&#39;:</div> <div>D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined reference t= o `sqlite3_open&#39;</div></div><div>etc...</div><div><br></div><div><br></= div><div>Any ideas?</div><div><br></div><div>Here&#39;s how I built sqlite,= in case I did something wrong:</div> <div>gcc -c sqlite3.c -m64 -O3 =C2=A0-&gt; sqlite3.o</div><div>ar rs libsql= ite.a sqlite3.o =C2=A0 =C2=A0-&gt; sqlite.a</div></div></div> --20cf3074d75840c32d04bee98fdd--
Apr 30 2012
prev sibling next sibling parent Manu <turkeyman gmail.com> writes:
--20cf3074d7583f470e04bee9c123
Content-Type: text/plain; charset=UTF-8

On 30 April 2012 18:33, Daniel Green <venix1 gmail.com> wrote:

 sqlite.o is easy enough to build and can be put into libgphobos.a. Being
 public domain helps, I'll add it to the build process.

libsqlite is quite big, perhaps it would be better to have the script create a lib beside phobos instead of in it? DMD supplies this as a separate lib, although theirs is about 1/3rd the size of the one I built for some reason :/ Curl is the only tricky one. It actually has configuration options and
 probably dependencies.  Is there a list of what features D requires curl to
 support?

I suspect the doc may reveal which features are available: http://dlang.org/phobos/etc_c_curl.html (looks like it covers basically everything) Is there a standard set of features for some 'standard' binary distribution? Most linux '-dev' packages seem to include binary libs for easy access, there must be a standard used there... I had trouble building curl, but I will be using all 3 currently existing etc.c libs in my app. --20cf3074d7583f470e04bee9c123 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div class=3D"gmail_extra"><div class=3D"gmail_quote">On 30 April 2012 18:3= 3, Daniel Green <span dir=3D"ltr">&lt;<a href=3D"mailto:venix1 gmail.com" t= arget=3D"_blank">venix1 gmail.com</a>&gt;</span> wrote:<br><blockquote clas= s=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;pad= ding-left:1ex"> <div class=3D"im">sqlite.o is easy enough to build and can be put into libg= phobos.a. Being public domain helps, I&#39;ll add it to the build process.<= /div></blockquote><div><br></div><div>libsqlite is quite big, perhaps it wo= uld be better to have the script create a lib beside phobos instead of in i= t?</div> <div>DMD supplies this as a separate lib, although theirs is about 1/3rd th= e size of the one I built for some reason :/</div><div><br></div><div><br><= /div><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-le= ft:1px #ccc solid;padding-left:1ex"> Curl is the only tricky one. =C2=A0It actually has configuration options an= d probably dependencies. =C2=A0Is there a list of what features D requires = curl to support?</blockquote><div><br></div><div>I suspect the doc may reve= al which features are available:=C2=A0<a href=3D"http://dlang.org/phobos/et= c_c_curl.html">http://dlang.org/phobos/etc_c_curl.html</a>=C2=A0(looks like= it covers basically everything)</div> <div>Is there a standard set of features for some &#39;standard&#39; binary= distribution? Most linux &#39;-dev&#39; packages seem to include binary li= bs for easy access, there must be a standard used there...</div><div><br> </div><div>I had trouble building curl, but I will be using all 3 currently= existing etc.c libs in my app.</div></div></div> --20cf3074d7583f470e04bee9c123--
Apr 30 2012
prev sibling next sibling parent Manu <turkeyman gmail.com> writes:
--485b3918ac2055bc7504beeac2f5
Content-Type: text/plain; charset=UTF-8

On 30 April 2012 21:24, Manu <turkeyman gmail.com> wrote:
 I seem to be getting a lot of these with the latest build trying to build
 a windows project (Daniel: the same repo I referred to in that bug report)

 c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(ti_Aint.o):
 In function `rt.typeinfo.ti_Aint._D2rt8typeinfo7ti_Aint9__modinitFZv':
 C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1:
 undefined reference to `_Dmodule_ref'
 C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1:
 undefined reference to `_Dmodule_ref'
 c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(conv.o):
 In function `std.conv._D3std4conv9__modinitFZv':
 C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../../gcc-4.6.1/libphobos/std/conv.d:1:
 undefined reference to `_Dmodule_ref'
 C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../../gcc-4.6.1/libphobos/std/conv.d:1:
 undefined reference to `_Dmodule_ref'
 etc...


 I also built sqlite, but it's complaining with lots of:

 C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
 `D4demu5tools8sqlitedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9ErrorCode':
 D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined reference to
 `sqlite3_exec'
 C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
 `D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv':
 D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined reference to
 `sqlite3_close'
 C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
 `D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9ErrorCode':
 D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined reference to
 `sqlite3_open'
 etc...


 Any ideas?

 Here's how I built sqlite, in case I did something wrong:
 gcc -c sqlite3.c -m64 -O3  -> sqlite3.o
 ar rs libsqlite.a sqlite3.o    -> sqlite.a

Actually, I just tried -m64 and the _Dmodule_ref errors were all gone... switched back to -m32 and they were back again... User error? What are they about? --485b3918ac2055bc7504beeac2f5 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div class=3D"gmail_extra"><div class=3D"gmail_quote">On 30 April 2012 21:2= 4, Manu <span dir=3D"ltr">&lt;<a href=3D"mailto:turkeyman gmail.com" target= =3D"_blank">turkeyman gmail.com</a>&gt;</span> wrote:<blockquote class=3D"g= mail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-l= eft:1ex"> <div class=3D"gmail_extra"><div class=3D"gmail_quote"><div>I seem to be get= ting a lot of these with the latest build trying to build a windows project= (Daniel: the same repo I referred to in that bug report)</div> <div><br></div><div><div>c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.6.1= /../../../../lib32/libgphobos2.a(ti_Aint.o): In function `rt.typeinfo.ti_Ai= nt._D2rt8typeinfo7ti_Aint9__modinitFZv&#39;:</div><div>C:\crossdev\gdc64\v2= \build\x86_64-w64-mingw32\32\libphobos\libdruntime/../../../../../gcc-4.6.1= /libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: undefined reference to `_Dm= odule_ref&#39;</div> <div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos\libdruntime= /../../../../../gcc-4.6.1/libphobos/libdruntime/rt/typeinfo/ti_Aint.d:1: un= defined reference to `_Dmodule_ref&#39;</div><div>c:/mingw64/bin/../lib/gcc= /x86_64-w64-mingw32/4.6.1/../../../../lib32/libgphobos2.a(conv.o): In funct= ion `std.conv._D3std4conv9__modinitFZv&#39;:</div> <div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../../../..= /gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_ref&#39= ;</div><div>C:\crossdev\gdc64\v2\build\x86_64-w64-mingw32\32\libphobos/../.= ./../../gcc-4.6.1/libphobos/std/conv.d:1: undefined reference to `_Dmodule_= ref&#39;</div> </div><div>etc...</div><div><br></div><div><br></div><div>I also built sqli= te, but it&#39;s complaining with lots of:</div><div><br></div><div><div>C:= \Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function `D4demu5tools8sq= litedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9ErrorCode&#39;:</div> <div>D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined reference t= o `sqlite3_exec&#39;</div><div>C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCi= c.o: In function `D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv&#39;:</div> <div> D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined reference to `sq= lite3_close&#39;</div><div>C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o:= In function `D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9E= rrorCode&#39;:</div> <div>D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined reference t= o `sqlite3_open&#39;</div></div><div>etc...</div><div><br></div><div><br></= div><div>Any ideas?</div><div><br></div><div>Here&#39;s how I built sqlite,= in case I did something wrong:</div> <div>gcc -c sqlite3.c -m64 -O3 =C2=A0-&gt; sqlite3.o</div><div>ar rs libsql= ite.a sqlite3.o =C2=A0 =C2=A0-&gt; sqlite.a</div></div></div> </blockquote></div><br></div><div class=3D"gmail_extra">Actually, I just tr= ied -m64 and the=C2=A0<span style>_Dmodule_ref errors were all gone... swit= ched back to -m32 and they were back again...</span></div><div class=3D"gma= il_extra"> <span style>User error? What are they about?</span></div> --485b3918ac2055bc7504beeac2f5--
Apr 30 2012
prev sibling next sibling parent Iain Buclaw <ibuclaw ubuntu.com> writes:
On 1 May 2012 05:37, Daniel Green <venix1 gmail.com> wrote:
 On 4/30/2012 2:49 PM, Manu wrote:
 =A0 =A0I also built sqlite, but it's complaining with lots of:

 =A0 =A0C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function

 =A0`D4demu5tools8sqlitedb8SQLiteDB6AttachMFAxaAxaZE4demu5tools5error9Err=


 =A0 =A0D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:57: undefined refere=


 =A0 =A0to `sqlite3_exec'
 =A0 =A0C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function
 =A0 =A0`D4demu5tools8sqlitedb8SQLiteDB5CloseMFZv':
 =A0 =A0D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:46: undefined refere=


 =A0 =A0to `sqlite3_close'
 =A0 =A0C:\Users\MANUEV~1\AppData\Local\Temp\cclkNCic.o: In function

 =A0`D4demu5tools8sqlitedb8SQLiteDB4OpenMFAxaZE4demu5tools5error9ErrorCod=


 =A0 =A0D:\Projects\SuperEmu/Source/Tools/SQLiteDB.d:34: undefined refere=


 =A0 =A0to `sqlite3_open'
 =A0 =A0etc...


 =A0 =A0Any ideas?

Build order? =A0binutils isn't smart(purposefully so?) when it comes to s=

 resolution. =A0The symbol must be declared after it is used. =A0I would c=

 the -v output and see where your library is in relation to the object fil=

 =A0 =A0Here's how I built sqlite, in case I did something wrong:
 =A0 =A0gcc -c sqlite3.c -m64 -O3 =A0-> sqlite3.o
 =A0 =A0ar rs libsqlite.a sqlite3.o =A0 =A0-> sqlite.a

This would save you the need to add -lsqlite and ensure that phobos symbo=

 are properly resolved as well. =A0As Iain suggested, this may be what GDC=

 start doing.

 ar q libgphobos2.a sqlite3.o

 Here's the size with -O2, -O3 for 32 and 64 bit.
 -rw-r--r-- 1 venix Administrators 742K Apr 30 23:23 sqlite3-m32-03.
 -rw-r--r-- 1 venix Administrators 565K Apr 30 23:21 sqlite3-m32.o
 -rw-r--r-- 1 venix Administrators 755K Apr 30 23:30 sqlite3-m64-03.
 -rw-r--r-- 1 venix Administrators 579K Apr 30 23:32 sqlite3-m64.o


 Actually, I just tried -m64 and the _Dmodule_ref errors were all gone...
 switched back to -m32 and they were back again...
 User error? What are they about?

DMD/Windows uses minit for module initialization. =A0GDC uses _Dmodule_re=

 =A0In the last release, they reorganized some module initialization code
 causing GDC/MinGW to not use define/use _Dmodule_ref initialization.

 Currently, there is an issue with multilib building on MinGW. =A0I had to
 manually compile and extract libphobos for the release. =A0It's possible =

 missed something.

no _Dmodule_ref would probably mean no object_.d was compiled in. --=20 Iain Buclaw *(p < e ? p++ : p) =3D (c & 0x0f) + '0';
Apr 30 2012
prev sibling parent Manu <turkeyman gmail.com> writes:
--20cf3005dcc89a28ef04befab4be
Content-Type: text/plain; charset=UTF-8

On 1 May 2012 17:31, Daniel Green <venix1 gmail.com> wrote:

 On 5/1/2012 1:53 AM, Iain Buclaw wrote:

 no _Dmodule_ref would probably mean no object_.d was compiled in.

In D2.058, the _Dmodule_ref code was moved to minfo.d. I didn't properly move the GNU specific stuff on the first build, problem didn't surface until I compiled it with MinGW. They reduced it to OSX, Posix for including _Dmodule_ref. Which is why linux didn't exhibit the same problems. I added it back but there's a chance the 32-bit library wasn't updated properly.

No problem, I only depend on x64 for the time being, so it's no problem to use that :) --20cf3005dcc89a28ef04befab4be Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div class=3D"gmail_extra"><div class=3D"gmail_quote">On 1 May 2012 17:31, = Daniel Green <span dir=3D"ltr">&lt;<a href=3D"mailto:venix1 gmail.com" targ= et=3D"_blank">venix1 gmail.com</a>&gt;</span> wrote:<br><blockquote class= =3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padd= ing-left:1ex"> <div class=3D"im">On 5/1/2012 1:53 AM, Iain Buclaw wrote:<br> <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p= x #ccc solid;padding-left:1ex"> no _Dmodule_ref would probably mean no object_.d was compiled in.<br> </blockquote> <br></div> In D2.058, the _Dmodule_ref code was moved to minfo.d. =C2=A0I didn&#39;t p= roperly move the GNU specific stuff on the first build, problem didn&#39;t = surface until I compiled it with MinGW.<br> <br> They reduced it to OSX, Posix for including _Dmodule_ref. =C2=A0Which is wh= y linux didn&#39;t exhibit the same problems.<br> <br> I added it back but there&#39;s a chance the 32-bit library wasn&#39;t upda= ted properly.<br> </blockquote></div><br></div><div class=3D"gmail_extra">No problem, I only = depend on x64 for the time being, so it&#39;s no problem to use that :)</di= v> --20cf3005dcc89a28ef04befab4be--
May 01 2012
prev sibling parent Manu <turkeyman gmail.com> writes:
--20cf306677dbdcf89304bee39b97
Content-Type: text/plain; charset=UTF-8

I guess the etc.c... libs didn't make the cut :(

On 28 April 2012 22:35, Dmitry Olshansky <dmitry.olsh gmail.com> wrote:

 On 28.04.2012 21:08, Daniel Green wrote:

 ** Fixes, previous unresolved _Dmodule_ref **

Nice, it works so far :) And where as previous version promptly segfaulted on my regex benchmark this one goes through. And the compiled binary performance is not bad either: Small test - searching for all \S+ \S+ (rough "email") in 40Mb of man-like text. dmd: 5.48sec gdc: 3.30sec Cool, surely gone use it side by side with dmd. P.S. Command line options: dmd -O -release -noboundscheck gdc -Ofast -frelease -- Dmitry Olshansky

--20cf306677dbdcf89304bee39b97 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div class=3D"gmail_extra">I guess the etc.c... libs didn&#39;t make the cu= t :(</div><div class=3D"gmail_extra"><br><div class=3D"gmail_quote">On 28 A= pril 2012 22:35, Dmitry Olshansky <span dir=3D"ltr">&lt;<a href=3D"mailto:d= mitry.olsh gmail.com" target=3D"_blank">dmitry.olsh gmail.com</a>&gt;</span=
 wrote:<br>

x #ccc solid;padding-left:1ex"><div class=3D"im">On 28.04.2012 21:08, Danie= l Green wrote:<br> <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p= x #ccc solid;padding-left:1ex"> ** Fixes, previous unresolved _Dmodule_ref **<br> </blockquote> <br></div> Nice, it works so far :)<br> <br> And where as previous version promptly segfaulted on my regex benchmark thi= s one goes through. And the compiled binary performance is not bad either:<= br> <br> Small test - searching for all \S+ \S+ (rough &quot;email&quot;) in 40Mb of= man-like text.<br> <br> dmd: 5.48sec<br> gdc: 3.30sec<br> <br> Cool, surely gone use it side by side with dmd.<br> <br> P.S. Command line options:<br> dmd -O -release -noboundscheck<br> gdc -Ofast -frelease<span class=3D"HOEnZb"><font color=3D"#888888"><br> <br> -- <br> Dmitry Olshansky<br> </font></span></blockquote></div><br></div> --20cf306677dbdcf89304bee39b97--
Apr 30 2012