www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - dmd or gdc install on Ubuntu AMD64

reply =?UTF-8?B?RnJhbsOnb2lzLVhhdmllcg==?= Pineau <fxpineau gmail.com> writes:
Someone can help?
I try to install dmd on Ubuntu with an AMD64.
When compiling my first prog, i have the error:
/usr/bin/ld: skipping incompatible /usr/lib/libpthread.a
when searching for -lpthread
/usr/bin/ld: cannot find -lpthread
I have found an explanation on: "http://www.digitalmars.com/d/archives/digitalmars/D/learn/64_bit_linux_7259.html" Thus I have decided to install gdc. The http://gdcgnu.sourceforge.net/ .deb package can't help. It's only for Intel proc. I have downloaded the archive: "gdc-0.23-x86_64-linux-gcc-4.1.1.tar.bz2" from sourceforge but I d'ont realy know what to do with it. I d'ont know what arguments I should use when configuring gcc... I have tried
configure -prefix=/usr/local/gcc-4.1 --enable-languages=c,d,c++
But when doing:
make install
I have an error saying:
/bin/sh ../mkinstalldirs /usr/local/gcc-4.1 /usr/local/gcc-4.1
cd: 5: can't cd to ./fixincludes
I'am not an expert so please, if someone succeed installing dmd or gdc on an AMD64 Ubuntu... Thanks.
Jun 12 2007
parent reply Frits van Bommel <fvbommel REMwOVExCAPSs.nl> writes:
François-Xavier Pineau wrote:
 I have downloaded the archive:
 "gdc-0.23-x86_64-linux-gcc-4.1.1.tar.bz2"
 from sourceforge but I d'ont realy know what to do with it.
 I d'ont know what arguments I should use when configuring gcc...
 I have tried
 configure -prefix=/usr/local/gcc-4.1 --enable-languages=c,d,c++
But when doing:
 make install
I have an error saying:
 /bin/sh ../mkinstalldirs /usr/local/gcc-4.1 /usr/local/gcc-4.1
 cd: 5: can't cd to ./fixincludes
I'am not an expert so please, if someone succeed installing dmd or gdc on an AMD64 Ubuntu...
That's a binary package, so there's no need to configure. Just unpack it somewhere and optionally make sure its bin/ directory is in your $PATH. I found it very convenient :). (DMD's a bit trickier to install on AMD64; like I said in the thread you linked, the only way I got it to work was in a 32-bit chroot)
Jun 12 2007
next sibling parent reply =?UTF-8?B?RnJhbsOnb2lzLVhhdmllcg==?= Pineau <fxpineau gmail.com> writes:
Frits van Bommel wrote:

 François-Xavier Pineau wrote:
 I have downloaded the archive:
 "gdc-0.23-x86_64-linux-gcc-4.1.1.tar.bz2"
 from sourceforge but I d'ont realy know what to do with it.
 I d'ont know what arguments I should use when configuring gcc...
 I have tried
 configure -prefix=/usr/local/gcc-4.1 --enable-languages=c,d,c++
But when doing:
 make install
I have an error saying:
 /bin/sh ../mkinstalldirs /usr/local/gcc-4.1 /usr/local/gcc-4.1
 cd: 5: can't cd to ./fixincludes
I'am not an expert so please, if someone succeed installing dmd or gdc on an AMD64 Ubuntu...
That's a binary package, so there's no need to configure. Just unpack it somewhere and optionally make sure its bin/ directory is in your $PATH. I found it very convenient :). (DMD's a bit trickier to install on AMD64; like I said in the thread you linked, the only way I got it to work was in a 32-bit chroot)
Hummm! Yeap! It's very more convenient like this... Sorry for having disturbing for such a simple task... I wanted to follow the install describe on http://dgcc.sourceforge.net/gdc/install.html (ok, no excuse ;) ) It works now, thanks! Just a question: with dmd it seams possible to execute a .d file like a script with: It is possible with gdc too?? I'am just able to compile using: gdmd myprog.d
Jun 13 2007
parent Frits van Bommel <fvbommel REMwOVExCAPSs.nl> writes:
François-Xavier Pineau wrote:
 Just a question:
 with dmd it seams possible to execute a .d file like a script with:

If you add " -run" at the end, yes.
 It is possible with gdc too??
 I'am just able to compile using:
  gdmd myprog.d
Not directly AFAIK. But the source to rdmd is floating around here somewhere, and IIRC at least one of bud/build and rebuild has this functionality built-in (as well as their main purpose of automatically handling imported modules, allowing you to also do this for multi-module programs).
Jun 13 2007
prev sibling parent Jason House <jason.james.house gmail.com> writes:
Frits van Bommel wrote:
 (DMD's a bit trickier to install on AMD64; like I said in the thread you 
 linked, the only way I got it to work was in a 32-bit chroot)
I tried to do this recently and failed to get it right. Doing this kind of thing makes me nervous that I'll screw up my system. What's the right way to do it? I found http://ubuntuforums.org/showthread.php?t=24575 Through step 3 seemed to work flawlessly (when modified for Feisty). Step 4 appeared to work, even if I didn't understand the nuiances of what it was doing, but then in step 5, apt-get wasn't working. I tried to see if I could get away without that kind of stuff and just use DMD, but I didn't have the right packages installed and needed to add more. Rather than get them all manually, I'd like to be able to use the built-in packaging utilities.
Jun 30 2007