linux - Library error when building a make file for a CUDA program -


i trying build makefile in linux. code goes makefile follows:

nvcc = /usr/local/cuda/bin/nvcc  cudapath = /usr/local/cuda  nvccflags = -i$(cudapath)/include  lflags = -l$(cudapath)/lib64 -lcuda -lcudart -lm  vectoradd:     $(nvcc) $(nvccflags) $(lflags) -o vectoradd vectoradd.cu 

so when type "make"

i following error:

enter image description here

how rid of , build make file?

since you're using nvcc don't need lflags , nvccflags definitions. nvcc knows how find automatically.

but if want fix it, rid of space @ end of cuda path definition:

cudapath = /usr/local/cuda                            ^ there space here, delete 

Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -