Alexy Khrabrov wrote:
So I got me a new shiny dmd for Mac, the Tango with D book, and went ahead to
compile something. What about Tango itself? Checked it out of svn, saw a dsss
directory. Got dsss of of svn, tried to compile that. The sad results are in:
http://www.dsource.org/forums/viewtopic.php?t=4490
Now what about starting off on a better footing? I mean, I have to chmod +x
dmd?! I need to make a statement of faith that it's executable? :)
Does anyone have a straightfoward writeup on what to do from the very beginning
-- in what sequence I get D, DSSS, Tango up and running? On a Mac, too! :)
Here's what I do to install DMD:
- unzip to ~/dmd
- sudo mkdir /opt/dmd-1.040 (or whatever)
- sudo ln -s /opt/dmd-1.040 /opt/dmd
- cd /opt/dmd
- sudo cp -r ~/dmd .
- sudo ln -s osx/bin
- sudo ln -s osx/lib
- cd bin
- sudo chmod a+x dmd obj2asm etc
Add /opt/dmd/bin to your path and you're ready to go. Now I install my
D import files to /usr/local/include/d, which requires changing dmd.conf
to something like the following:
DFLAGS=-I/usr/local/include/d -L-L/usr/local/lib -l...@p%/../lib
(I'm guessing a bit about having two link paths... I only use
/usr/local/lib)
Now DMD will look for import files only in /usr/local/include/d and for
lib files (hopefully) in /usr/local/lib and /opt/dmd/lib. When you
install Tango, copy the import files to /usr/local/include/d and the
library files to /usr/local/lib and you should be all set.
There's also a manual install doc on the Tango website you can follow,
but this should cover the basics. I run out of /usr/include/d because I
publish everything directly from SVN.