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:\MingGW\bin
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:\MinGw\bin
) and I do not know the equivalent of which in windows. Do I have forgotten an essential step ?
Thanks for your hel开发者_如何学编程p.
Try mingw32-make instead.
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).
Are you sure there is no make ? Once do "where make" to confirm this and check the entries you get under C:\mingW\bin. 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
精彩评论