OS X El Capitan上的CUDA链接错误 [英] CUDA linking error on OS X El Capitan

查看:57
本文介绍了OS X El Capitan上的CUDA链接错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试为指示安装TensorFlow的CUDA和cuDNN.TensorFlow页面.一切正常,直到我执行以下操作:

I've been trying to install CUDA and cuDNN for TensorFlow as instructed on the TensorFlow page. Everything works until I do the following:

$ cp -r /usr/local/cuda/samples ~/cuda-samples
$ pushd ~/cuda-samples
$ make

然后我得到以下错误:

clang++  -rpath /Developer/NVIDIA/CUDA-7.5/lib -L/Developer/NVIDIA/CUDA-7.5/lib -framework CUDA -o clock_nvrtc clock.o  -lnvrtc
ld: framework not found CUDA
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [clock_nvrtc] Error 1
make: *** [0_Simple/clock_nvrtc/Makefile.ph_build] Error 2

我的问题当然是什么原因导致了错误,以及如何解决该错误.我以前安装了CUDA 7.5,然后安装了8.0.整个CUDA(及其安装)对我来说只是一个黑匣子.我只是想让它与TensorFlow一起使用.

My question of course is what's causing the error, and how to fix it. I had previously installed CUDA 7.5, and then I installed 8.0. The whole of CUDA (and its installation) is just a black box to me; I'm just trying to get it to work with TensorFlow.

谢谢!

推荐答案

在终端中运行以下命令-

Run the following in your terminal -

xcode-select --install

然后尝试再次运行 make .

在NVidia论坛上看到答案- https://devtalk.nvidia.com/default/topic/628298/cuda-samples-on-mac-os-x-mavericks-10-9-matrixmuldrv/

Saw the answer on an NVidia forum - https://devtalk.nvidia.com/default/topic/628298/cuda-samples-on-mac-os-x-mavericks-10-9-matrixmuldrv/

此快速入门指南-http://docs.nvidia.com/cuda/cuda-quick-start-guide/index.html#axzz4YvZYOZc0

这篇关于OS X El Capitan上的CUDA链接错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆