codeblocks for D2 on 64-bit Ubuntu 10.10
David Wang
osx.david at live.com
Sun Apr 10 19:50:22 PDT 2011
==================================================
== Forward by Frank (fkmiec at gmail.com)
== Posted at 2011/04/09 21:43 to digitalmars.D.ide
All:
I am attempting to learn D2 and needed to set up an IDE. From what
I
can see, CodeBlocks is the best we have at the moment. I had
trouble
getting it set up, so I wanted to share what I've done to make it
work. I'm sure it's not the "right" way, so anyone who knows
better,
please chime in.
Go to Settings -> Compiler and Debugger -> Other settings ->
Advanced
Options and delete all the linker commands (save them somewhere to
be
able to restore later, just in case) and change the compile single
file to object setting to:
$compiler -v $options $includes $file -of$exe_dir/$exe_name
You may also be able to specify dmd as the linker instead of gcc
and
have better luck ... I will try that later since I assume there is
an
advantage to linking in a separate step.
Also, under Settings -> Search Directories, add:
/usr/include/d/dmd/druntime
/usr/include/d/dmd/phobos
One last thing ... the command above is building 32-bit. I tested
adding -m64 and it worked fine and built a 64-bit executable. Test
by
executing "file {filename}.o" and you'll get output like:
TestD.o: ELF 64-bit LSB relocatable, x86-64, version 1 (GNU/Linux),
not stripped
This seems to work, but as I say, I'm brand new to D ... coming
from
Java where everything is dynamically linked and tool support is
excellent. Hope it helps some other newbies.
==================================================
For settings or CodeBlocks about the D program build, please view
the instructions:
For Windows:
http://wiki.codeblocks.org/index.php?
title=Installing_a_supported_compiler#Digital_Mars_D_Compiler_for_W
indows
For Linux:
http://wiki.codeblocks.org/index.php?
title=Installing_a_supported_compiler#Digital_Mars_D_Compiler_for_L
inux
More information about the Digitalmars-d-ide
mailing list