2014-12-22 12 views
0

我已經升級到優勝美地,但新的gcc4.9如何在優勝美地上設置CUDA?

gcc: warning: couldn’t understand kern.osversion ‘14.0.0 
gcc: warning: couldn’t understand kern.osversion ‘14.0.0 
In file included from /Developer/NVIDIA/CUDA-5.0/bin/../include/cuda_runtime.h:59:0, 
       from <command-line>:0: 
/Developer/NVIDIA/CUDA-5.0/bin/../include/host_config.h:82:2: error: #error -- unsupported GNU version! gcc 4.7 and up are not supported! 
#error -- unsupported GNU version! gcc 4.7 and up are not supported! 

我使用的是舊GeForce9400M但司機正在nvcc不喜歡。 這是DEVICEQUERY編譯NVCC 5.0:

CUDA Device Query (Runtime API) version (CUDART static linking) 

Detected 1 CUDA Capable device(s) 

Device 0: "GeForce 9400M" 
    CUDA Driver Version/Runtime Version   6.5/5.0 

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 6.5, CUDA Runtime Version = 5.0, NumDevs = 1, Device0 = GeForce 9400M 

這是DEVICEQUERY與NVCC 6.5編譯:

dyld: Library not loaded: @rpath/libcudart.dylib 
    Referenced from: /Developer/NVIDIA/CUDA-5.0/samples/1_Utilities/deviceQuery/./deviceQuery 
    Reason: Incompatible library version: deviceQuery requires version 1.1.0 or later, but libcudart.dylib provides version 0.0.0 
Trace/BPT trap: 5 

我應該怎樣設置優勝美地使用CUDA?

+0

你試圖做的事情是行不通的。 CUDA 5.0與Yosemite不兼容,也沒有提供CUDA 5.0所需的主機工具鏈的Xcode/SDK版本。 – talonmies

+0

NVIDIA表示,驅動程序對具有SM1.x的舊一代GPU的支持已被棄用。按照這些說明https://devtalk.nvidia.com/default/topic/627626/cuda-setup-and-installation/cuda-driver-on-mac-os-mavericks/post/4138126/#4138126我的驅動程序仍然有效。你認爲我可以在Yosemite上使用SM1.x的CUDA 6.5嗎? – ilciavo

+0

只需在4.9下安裝gcc 4.7,並將符號鏈接'gcc'改爲4.7,或將'nvcc'配置爲使用4.7與'-ccbin'。 –

回答

0

解決方案:

1)安裝CUDAToolkit6.0

2)降級CUDAdriver到4.2.10,

3)升級CUDAdriver到6.5 ONLY !!! ...

我仍然收到警告nvcc警告:'compute_10'和'sm_10'體系結構已被棄用,並可能在未來版本中刪除。

我問這在NVIDIA的教程,答案是「硬件更新」

因此,我將保持6.5工具包或新的更新了。