nvcc fatal : Failed to detect host compiler properties.

Hello,
May I please know what action to take in order to solve this problem
“nvcc fatal : Failed to detect host compiler properties.”

Machine is running on linux x86_64 Ubuntu 12.04
NVIDIA Corporation GT200GL [Tesla C1060 / M1060]
CUDA 7.0 and gcc 4.6

Thank you

Check if /usr/local/cuda/bin/gcc link is correct if it exists or purge and reinstall cuda.

yes I did link it to cuda/bin. but its not working.

yes I did link it to cuda/bin. but its not working.