Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Here are quick copy&paste instructions to install the newest DMD and Tango:

These instructions install DMD 1.065.
But you can try any higher version.
See the Digitalmars download site.

You have to be root for these instructions.

unzip dmd.1*.zip
mkdir /opt/dmd
cp -r dmd/osx/* /opt/dmd/
chmod a+x /opt/dmd/bin/dmd
export PATH=/opt/dmd/bin:$PATH
svn co
cd trunk/
./build/bin/osx32/bob -vu -r=dmd -c=dmd .
cp libtango.a /opt/dmd/lib/libtango.a
mkdir /opt/dmd/import
cp -r object.di tango /opt/dmd/import/

Change the content of /opt/dmd/bin/dmd.conf to:


DFLAGS=-I%@P%/../import -I%@P%/../import/tango/core/vendor -L-L%@P%/../lib  -version=Tango -defaultlib=tango -debuglib=tango -version=osx

Create a main.d file:

module main;


void main(char[][] args)
   Stdout("Hello World").newline;

Compile and run it:

dmd main.d
Hello World

Done. :-)


  • Put "export PATH=/opt/dmd/bin:$PATH" into your ~/.bashrc file to have dmd available in every console.
  • You can take zlib and other libs from the Tango bundle and copy it to your /opt/dmd/lib folder.


rm -rf /opt/dmd/