nvcc not found, but only when using sudo
- by dsp_099
I can't get ANYTHING working on linux. I'm trying to compile CudaMiner.
sudo make:
ypt-jane.o `test -f 'scrypt-jane.cpp' || echo './'`scrypt-jane.cpp
mv -f .deps/cudaminer-scrypt-jane.Tpo .deps/cudaminer-scrypt-jane.Po
nvcc -g -O2 -Xptxas "-abi=no -v" -arch=compute_10 --maxrregcount=64 --ptxas-options=-v -I./compat/jansson -o salsa_kernel.o -c salsa_kernel.cu
/bin/bash: nvcc: command not found
make[2]: *** [salsa_kernel.o] Error 127
make[2]: Leaving directory `/var/progs/CudaMiner'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/progs/CudaMiner'
make: *** [all] Error 2
So, kind of interesting:
nvcc:
nvcc fatal : No input files specified; use option --help for more information
Whereas
sudo nvcc:
sudo: nvcc: command not found
Huh??
I have identical exports listed in ~/.bashrc AND /etc/bash.bashrc. (Nvcc is located in: /usr/local/cuda-5.0/bin/nvcc)
I also tried changing the current path, to no avail:
$ sudo bash -c 'echo $PATH'
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
$ PATH=$PATH:/usr/local/cuda-5.0/bin/nvcc
$ sudo bash -c 'echo $PATH'
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Thanks in advance!