make problem with mingw

I have a small problem with make and mingw. I usually use Linux and I am not really familiar with windows way of doing.

C:MingGWbin is in my path (I can launch directly g++ or sh by the windows command line) but when I try to type make I have the following error :

make: g++: command not found

I do not know which make is use (no make in C:MinGwbin ) and I do not know the equivalent of which in windows. Do I have forgotten an essential step ?

Thanks for your help.


Use this command to find out which one you're running:

for %i in (make.exe) do @echo. %~$PATH:i

It's basically the equivalent of which for Windows, assuming you know the extension. If you want a script that will check all extensions, you can find it here.


As pointed out in a comment by Chris, latter versions of Windows (Vista, 2003 Server, and Win7, I think) actually have a real equivalent called where , which may be better. Those of us still stuck back on XP can use the command above (or the big script at the other end of that link).


尝试使用mingw32-make。


Are you sure there is no make ? Once do "where make" to confirm this and check the entries you get under C:mingWbin. Hopefully you will get a entry mingw-32-make.exe or something like that.

All you need to do is rename (better create a copy and rename) this exe as make.exe and if you have already added the environment variable of this path then you may now be able to issue make command happily under mingw.

The same is already done for g++,gcc, etc. They might have conveniently left make the way it is. Hope this helps

链接地址: http://www.djcxy.com/p/30272.html

上一篇: 如何使用节点调试带有断点的Gruntfile

下一篇: 与明暗有关的问题