CUDA Toolkit 5.0 NSight build errors on Mac OS X ML

╄→гoц情女王★ 提交于 2019-12-11 10:47:44

问题


I have strange thing happened to my CUDA Toolkit 5.0. Few days ago both XCode and NSight Eclipse plugin lost ability to build even simplest CUDA related projects. XCode successfully building projects with custom build rule for C++ source files:

    nvcc "INPUT_FILE_NAME"

But console output shows that run failed

    error: executable doesn't exist: '/Users/geraldus/Library/Developer/Xcode/DerivedData/CUDA_Hello_World-gzfzqivvsmeamfghnovopxapkdsz/Build/Products/Debug/CUDA Hello World'
    error: failed to launch '/Users/geraldus/Library/Developer/Xcode/DerivedData/CUDA_Hello_World-gzfzqivvsmeamfghnovopxapkdsz/Build/Products/Debug/CUDA Hello World' -- SBTarget is invaliderror: failed to launch '/Users/geraldus/Library/Developer/Xcode/DerivedData/CUDA_Hello_World-gzfzqivvsmeamfghnovopxapkdsz/Build/Products/Debug/CUDA Hello World' -- SBTarget is invalid

And Eclipse NSight output always shows that .o file is missing.

    **** Build of configuration Release for project Simple CUDA RT ****

    make all 
    Building file: ../src/Simple CUDA RT.cu
    Invoking: NVCC Compiler
    nvcc -O3 -gencode arch=compute_20,code=sm_20 -gencode arch=compute_35,code=sm_35 -odir "src" -M -o "src/Simple CUDA RT.d" "../src/Simple CUDA RT.cu"
    nvcc -O3   "src/Simple CUDA RT.o" "../src/Simple CUDA RT.cu"
    i686-apple-darwin11-llvm-g++-4.2: src/Simple CUDA RT.o: No such file or directory
    make: *** [src/Simple CUDA RT.o] Error 1

    **** Build Finished ****

How can I fix it? Is it a bug or my incorrect actions?

UPDATE [10:03 UTC 6 NOV 2012]

I've tried to rebuild CUDA samples this way:

    cd /Developer/NVIDIA/CUDA-5.0/samples
    make clean
    make

Everything was built without errors, binaries were successfully generated and they works. But still the same situation with XCode and Eclipse (even after reinstalling Eclipse and CUDA Toolkit)


回答1:


This looks like a permissions issue. Verify the build folder (and all the files in it) are writable by the current user.

Update Turns out the actual problem with Nsight EE was spaces in the file name.



来源:https://stackoverflow.com/questions/13237371/cuda-toolkit-5-0-nsight-build-errors-on-mac-os-x-ml

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!