0
votes

So I'm trying to compile a C project I downloaded using nmake, however I don't know why it isn't working. There's a PATHS.mak file whose contents are:

PATH=C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin
INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include
LIB=C:\Program Files (x86)\Microsoft Visual Studio 14.0\lib

I'm using the Visual Studio Developer Command Prompt to do it. I go the place where the .mak file is and run nmake, however the error I get is:

    cl -c -nologo -WX -W3 -Oax2 -I C:\Program Files (x86)\Microsoft Visual S
    tudio 14.0\VC\include -I C:\Users\..\Desktop\School\GERBIL02\src -I C:\Users\..\Desktop\School\GERBIL02\src\engine -Zi C:\Users\..\Desktop\School\GERBIL02
\src\engine\engine.c /FoC:\Users\..\Desktop\School\GERBIL02\ship\engine
'cl' is not recognized as an internal or external command,
 operable program or batch file.
 NMAKE : fatal error U1077: 'cl' : return code '0x1'
 Stop.

I've seen something about running a vcvarsall.bat file, but I'm unable to find the file, and I'm not sure if it is applicable. Anyone know why it won't work? Thanks

1
Do you have Visual Studio 14? - melpomene
Yes, I have it installed. - TLF
Are there any errors when when you first open the Command prompt window? What happens when you type cl at the command prompt? - Brian Tompsett - 汤莱恩
There are no errors when I open the Developer Command Prompt for VS 2015 (which I think I'm supposed to be using). Typing cl causes an error where it says cl is not an internal/external command, operable program or batch file. - TLF

1 Answers

0
votes

I had this problem, in my case it was because Visual Studio was installed with C# but C++ isn't actually installed by default and so I had to run the VS setup again to choose C++. Might not be your issue, but just thought I'd mention in case.