link error: undefined reference to 'cudaFree' ...

I first compiled a .cu file using -cuda option to a .cppfile and than built using gcc, but got
"undefined reference to ‘cudaFree’ and a bunch of other cuda* functions.
I already have -lcuda option for linking. Which other lib should I specify?


cudaFree symbol is defined in It should be located in /usr/local/cuda/lib with a default install.