Error compiling CUDA from Command Prompt

前端 未结 6 1324
面向向阳花
面向向阳花 2020-12-05 06:15

I\'m trying to compile a cuda test program on Windows 7 via Command Prompt, I\'m this command:

nvcc test.cu

But all I get is this error:<

6条回答
  •  情歌与酒
    2020-12-05 06:55

    I see that this is an old question but I recently got this error on my Visual Studio 2012 when I tried to build my CUDA project. Apparently I had changed my CUDA project to the Nov 2012 pack, changing it back to the v110 that it usually is by default fixed this error.

    In Visual Studio, left click on the CUDA project, ->properties->Configuration Properties-> General -> Platform toolset, and choose: Visual Studio 2012 (v110).

    I could probably get it to work with the Nov 2012 pack, but the CUDA code does not use any of the additional functions of that pack, so it is not necessary. (That pack contains the variadic templates for C++11.)

提交回复
热议问题