symlink confusion
Joshua Judson Rosen
rozzin at hackerposse.com
Sat Nov 14 17:08:48 EST 2015
On 11/14/2015 04:29 PM, Bruce Labitt wrote:
>
> Original link: from http://askubuntu.com/questions/693145/installing-cuda-7-5-toolkit-on-ubuntu-15-10
>
> /I wanna share my experience on installing CUDA 7.5 (in order to use with Theano) on Ubuntu 15.10. /
>
> //
>
> 1.
>
> /I installed Ubuntu 15.10 and the video driver (352.41) from the
> "Additional Drivers" tab;/
>
> 2.
>
> /Installed few dependencies like //|nvidia-modprobe|//(fix
> permissions problems), and for the samples compiling
> //|freeglut3-dev libx11-dev libxmu-dev libxi-dev libglu1-mesa-dev|/
>
> 3.
>
> /And because it needs GCC 4.9: //|sudo apt-get install gcc-4.9
> g++-4.9|//, then made symlinks in //|/opt/compiler_cuda|//(created
> the folder with an arbitrary name of my choice) as follows://
> / /|$ ls -la /opt/compiler_cuda/|//
> / /|lrwxrwxrwx 1 root root 22 Nov 2 16:14 cc ->
> /opt/compiler_cuda/gcc|//
> / /|lrwxrwxrwx 1 root root 16 Nov 2 16:13 g++ -> /usr/bin/g++-4.9|//
> / /|lrwxrwxrwx 1 root root 16 Nov 2 16:12 gcc -> /usr/bin/gcc-4.9|//
> //Registered //|update-alternatives|//with://
> / /|sudo update-alternatives --install /usr/bin/gcc gcc
> /usr/bin/gcc-5 60 --slave /usr/bin/g++ g++ /usr/bin/g++-5|//
> / /|sudo update-alternatives --install /usr/bin/gcc gcc
> /usr/bin/gcc-4.9 50 --slave /usr/bin/g++ g++ /usr/bin/g++-4.9|//
> /
>
> 4.
>
> /Downloaded "runfile (local)" 15.04 version, from //CUDA 7.5
> Downloads <https://developer.nvidia.com/cuda-downloads>//; and
> installed with://
> / /|sudo sh cuda_7.5.18_linux.run --silent --toolkit --override|//
> / /|sudo sh cuda_7.5.18_linux.run --silent --samples --override|//
> //and appended in //|.bash_aliases|//(.bashrc reads it)://
> / /|export PATH=/usr/local/cuda-7.5/bin:$PATH|//
> / /|export LD_LIBRARY_PATH=/usr/local/cuda-7.5/lib64:$LD_LIBRARY_PATH|/
>
> 5.
>
> /Appended //|compiler-bindir = /opt/compiler_cuda|//in
> //|nvcc.profile|//, so nvcc can use it./
>
>
> I'm trying to do step 3. I have seen similar instructions in the past. I may have done something like this in the past, but, I am temporarily suffering from CRS. I believe this will work, although as you have stated, it may not be optimal. For Wily Ubuntu 15.10, the default gcc is 5.2. Nvidia is stuck at 4.9, hence the update alternatives command in step 3.
>
> Is there any reason step 3) won't work?
>
> To make the symlink |cc -> /opt/compiler_cuda/gcc, what is the command?
>
> Does *ln -s /usr/bin/cc /opt/compiler_cuda/gcc* do what the author states above? Or do I have it backwards?
Oh. Well, bearing in mind that this "cc" symlink itself is expected to
*reside in* /opt/compiler_cuda, the command that guy must have run is:
ln -s /opt/compiler_cuda/gcc /opt/compiler_cuda/cc
It would suffice to do:
ln -s gcc /opt/compiler_cuda/cc
It *might* even be less confusing.
--
"Don't be afraid to ask (λf.((λx.xx) (λr.f(rr))))."
More information about the gnhlug-discuss
mailing list