2016-04-29 68 views
0

我已經安裝GCC-4.7,GCC-4.8,GCC-4.9CUDA 7.0抱怨不支持GCC 4.9

當我嘗試這樣做:

luarocks install cutorch 

我得到一個錯誤:

In file included from /usr/include/cuda_runtime.h:59:0, 
       from <command-line>:0: 
/usr/include/host_config.h:82:2: error: #error -- unsupported GNU version! gcc 4.9 and up are not supported! 
#error -- unsupported GNU version! gcc 4.9 and up are not supported! 

我發現了一個similar problem

但是當我嘗試運行命令:

nvcc --compiler-bindir /usr/bin/gcc-4.7 

我得到一個錯誤:

nvcc fatal: No input files specified; use option --help for more information 

我新安裝了Linux天前。請幫我

回答

2

安裝之前運行以下命令:

export CXX=/usr/bin/g++-4.8 
export CC=/usr/bin/gcc-4.8 

這應該設置編譯器GCC-4.8的編譯。