0
votes

I have few queries regarding makefiles for MSVC. I want to create makefiles which will compile my project on Visual C++ compiler. One thing I found in the web named "nmake" which is said to be the makefiles for MSVC(correct me if I am wrong).

So, I introduced myself with nmake and compiled a single source file successfully with this. But the issue is, I need to run this nmake file using command prompt of visual studio. I haven't found a way to use the file in normal command prompt. Is it really possible?

Suppose, I don't have a visual studio installed. I have only the visual C++ compiler. Then how I will be able to compile my projects using nmake?

One Additional question, if I have only visual C++ compiler installed(like the old compilers eg. microsoft visual C++ 2005), then is it certain that I will get nmake command on this?

Thanks in advance.

1
If you're using only command-line tools without VS then you're probably better off using GCC. Using nmake and cl outside of VS is possible, but why make things harder for yourself? Also VC2005 is very old, you'd be missing out on C++11 support. - Dai
Actually it is a requirement. We should use Visual C++ compilers rather than GCC. - Naseef Chowdhury

1 Answers

0
votes

Solved! Answering myself, so that if anyone intend to compile makefiles using nmake for Visual C++ compiler.

Yes, it is compiles in older version of visual C++ also. I have tested and it works fine. But it may cause problems when some properties are use of latest visual C++ compiler. Because you will not find those properties in older version of C++ compiler. Otherwise it is quite OK.