How can I setup nvcc to use Visual C++ Express 2010 x64 from Windows SDK 7.1?

拜拜、爱过 提交于 2019-12-01 23:27:40

问题


I'm building 64-bit apps with Visual C++ Express 2010 extended with Windows SDK 7.1 (to add 64 bit compiler). When I use nvcc in 32-bits mode it works well. When I use it in 64-bits mode I get this error:

nvcc fatal   : Visual Studio configuration file '(null)' could not be found for installation at 'C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\x86_amd64/../../..'

What can I do to supply the correct files to nvcc?


回答1:


Ok, I've found solution. Nvcc is looking for vcvars64.bat file to be in Program Files\Microsoft Visual Studio 10.0\VC\bin\amd64, but it exists only in professional version of VS. You have to create it manually putting inside:
CALL setenv /x64



来源:https://stackoverflow.com/questions/8900617/how-can-i-setup-nvcc-to-use-visual-c-express-2010-x64-from-windows-sdk-7-1

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