Global Library Export

What is the proper way to export the CUDA libraries and bins to “all users” without having to utilize the “.bashrc” method?

The “.bashrc” method is causing some issues for me. Also I tried “/etc/environment” but that has not exactly helped much.


Edit /etc/ or add a new file to /etc/ and rerun ldconfig afterwards

Thank You!

How about the binarys? Where would I set those? env?

local binaries usually live in /usr/local/bin and that path should be in the PATH envvar by default.

/etc/environment looks like the right place. Just make sure you didn’t mess up too much with it. Here is mine:

cat /etc/environment

You have to re-login in order for it to work. Upon fresh login:

echo $PATH
nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2013 NVIDIA Corporation
Built on Sat_Mar_15_02:05:29_PDT_2014
Cuda compilation tools, release 6.0, V6.0.1