DMD, Wine and MinGW

ketmar via Digitalmars-d digitalmars-d at puremagic.com
Sun Jan 18 10:10:43 PST 2015


On Sun, 18 Jan 2015 17:32:28 +0000
Joakim via Digitalmars-d <digitalmars-d at puremagic.com> wrote:

> I used dmd under Wine years ago and didn't have a problem 
> building a small utility, no recent use though.
the strange thing is that is sometimes works... once in a while it is
able to build "hello.d", but most of the time it crashing. as it
crashing with "-c" and even with "-c -o-", i assume that this is a
subtle bug in dmd. but to debug it i first have to build it with
MinGW. ;-)

> > 3. does anybody thought about allowing each dmd version to 
> > create all
> > kind of object files on any platform, and how much is this 
> > wanted?
> 
> Yes, Rainer had a pull that started dmd along this path by 
> changing the command-line options, but Walter didn't want dmd to 
> give any indication that cross-compiling was supported without 
> the rest of the work done so he vetoed it:
> 
> https://github.com/D-Programming-Language/dmd/pull/3542
ah, i see. this is more ambitious that what i want. ;-) i talked about
merely changing the output object file formats, so one can specify if
dmd will output OMF, or COFF, or...

> Yes, dmd generates 32-bit COFF right now and I'm sure you can 
> find a cross-linker that will work.
if i made dmd itself work under Wine. ;-) actually, optlink has no
problems with wine, and it's ok for me.

> You can install Win7 for four months without a license, whether 
> in a VM or spare partition.  I've done that before, sometimes 
> wiping and installing on top after four months to start the timer 
> again. ;) Maybe Win8 allows the same, or you can test on the 
> Win10 Preview.
alas, they want too much memory and HDD space. %-(

for now i think that i will simply fallback to C for my needs (hate it!
hate it! oh, how much i hate it now! ;-).

p.s. i managed to sucessfully compile "hello world" with MinGW-built
dmd.exe on my mate's windows box. there was a bug with "%lld" and
"%llu" which MinGW doesn't support, but after i fixed that with macro
hackery, my "hello.exe" says "hi!" to me. ;-)

yet it still not working under wine. but now i'm at least sure that it
works, so i can try to debug that crash.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20150118/72855b14/attachment.sig>


More information about the Digitalmars-d mailing list