Symbolic linking confusion

Bruce Labitt bruce.labitt at myfairpoint.net
Wed Apr 17 21:17:31 EDT 2013


Just to add to the top posting madness :P

Derek was right.  Adding the -L/usr/lib/nvidia-current-updates to the 
make file did it.

The symbolic linking was a red herring.

For anyone who is interested, the makefile in question was
NVIDIA_GPU_Computing_SDK/C/common/common.mk

The fix was to change line 144 from
LINK     +=

to
LINK    += -L/usr/lib/nvidia-current-updates

Ubuntu 12.10, 3.5.0-27-generic x86_64
nvidia-cuda-toolkit installed


Thanks!  Now running CUDA demos...
-Bruce


On 04/16/2013 08:45 AM, Derek Atkins wrote:
> Or just add -L /usr/lib/nvidia-current-updates to your link line to 
> tell the linker where to look.  Your ls.so.conf change is for the 
> runtime linker..  you will need that too.
>
> -derek
>
> Sent from my HTC smartphone
>
> ----- Reply message -----
> From: "Greg Rundlett (freephile)" <greg at freephile.com>
> To: "Bruce Labitt" <bruce.labitt at myfairpoint.net>
> Cc: "GNHLUG" <gnhlug-discuss at mail.gnhlug.org>
> Subject: Symbolic linking confusion
> Date: Mon, Apr 15, 2013 10:18 PM
>
>
> You have it right
>
> On Apr 15, 2013 10:02 PM, "Bruce Labitt" <bruce.labitt at myfairpoint.net 
> <mailto:bruce.labitt at myfairpoint.net>> wrote:
>
>     Recently been playing with GPU computing.  I'm running Ubuntu
>     12.10 and installed the nvidia-cuda-toolkit package.  It seems
>     that the libs are in odd places.  Why does it matter?  Because I'd
>     like to build the GPU Computing SDK.  So I follow the instructions
>     in /usr/share/nvidia-cuda-toolkit,  down load the SDK and type make.
>
>     So it gets part way through and barfs because it can't find libcuda.
>
>     make[1]: Entering directory
>     `/home/bruce/NVIDIA_GPU_Computing_SDK/C/src/deviceQuery'
>     /usr/bin/ld: error: cannot find -lcuda
>
>     No problem, just edit ld.so.conf.d/cuda.conf add the locations,
>     ldconfig, and should be good to go.  Still can't find libcuda. 
>     Must be a link issue...
>
>     $ locate libcuda
>     /usr/lib/nvidia-current-updates/libcuda.so
>     /usr/lib/nvidia-current-updates/libcuda.so.1
>     /usr/lib/nvidia-current-updates/libcuda.so.304.88
>
>     $ sudo ldconfig -v
>     ...
>     /usr/lib/nvidia-current-updates:
>         libcuda.so.1 -> libcuda.so.304.88
>         libnvidia-tls.so.304.88 -> libnvidia-tls.so.304.88
>         libnvcuvid.so.1 -> libnvcuvid.so.304.88
>         libOpenCL.so.1 -> libOpenCL.so.1.0.0
>         libnvidia-cfg.so.1 -> libnvidia-cfg.so.304.88
>         libnvidia-ml.so.1 -> libnvidia-ml.so.304.88
>         libnvidia-opencl.so.1 -> libnvidia-opencl.so.304.88
>         libnvidia-glcore.so.304.88 -> libnvidia-glcore.so.304.88
>         libnvidia-wfb.so.1 -> libnvidia-wfb.so.304.88
>         libXvMCNVIDIA_dynamic.so.1 -> libXvMCNVIDIA.so.304.88
>         libGL.so.1 -> libGL.so.304.88
>         libnvidia-compiler.so.304.88 -> libnvidia-compiler.so.304.88
>
>     So do I just do
>     $ sudo ln -s libcuda.so.1 libcuda.so  ?  or the other way around ?
>
>     man ln is not very clear...
>
>     ln -s {target-filename} {symbolic-filename}
>
>     Which is really the target?  libcuda.so.1 ?  Did I get that right?
>
>     TIA,
>     Bruce
>
>
>     _______________________________________________
>     gnhlug-discuss mailing list
>     gnhlug-discuss at mail.gnhlug.org <mailto:gnhlug-discuss at mail.gnhlug.org>
>     http://mail.gnhlug.org/mailman/listinfo/gnhlug-discuss/
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.gnhlug.org/mailman/private/gnhlug-discuss/attachments/20130417/10fc4613/attachment.html 


More information about the gnhlug-discuss mailing list