Allegro.cc - Online Community

Allegro.cc Forums » Installation, Setup & Configuration » Mingw make doesn't find internal commands

This thread is locked; no one can reply to it. rss feed Print
Mingw make doesn't find internal commands
Audric
Member #907
January 2001

I've just realized that all the makefiles I try to run fail on shell commands like:

copy srcfname dstfname
del fname

It's weird, because all compiler commands (gcc, ar, etc.) work perfectly, it's only the instruction for windows' command interpreter that fail.

The message is "copy: command not found" or "del: command not found" when I use make.
I just downloaded the latest mingw32-make, it gives the same errors with a slightly more verbose message, saying something about the "CreateProcess (...) failed".

It may be related to the command interpreter. I normally use 4DOS.COM, but I also tried running make on COMMAND.COM, with variable COMSPEC=C:\COMMAND.COM : It makes no difference.

My current workaround is to manually call the faulty commands since they are few, I considered creating a COPY.EXE and DEL.EXE but it feels a bit silly ;D I'd rather understand what's happening.

(edit: Aaah I forgot to mark this post as a question, no cookies, sorry :-[)

GullRaDriel
Member #3,861
September 2003
avatar

$(RM)
$(CP) ?

Edit: fixed syntax

Edit 2:
Post your makefile. I was able to use $(CP) because I defined it before.

"Code is like shit - it only smells if it is not yours"
Allegro Wiki, full of examples and articles !!

Audric
Member #907
January 2001

Yesterday it was on my first-time compilation of JGMOD (makefile) on Mingw.

(By the way I don't understand if a Mingw makefile should use bash commands (rm include/lib.h) or the DOS syntax (del include\lib.h)

GullRaDriel
Member #3,861
September 2003
avatar

Your path variable is perhaps fucked up, because I use copy in my makefile, like you along with mingw32-make with no problem.

"Code is like shit - it only smells if it is not yours"
Allegro Wiki, full of examples and articles !!

Audric
Member #907
January 2001

Path was apparently ok, I made sure to leave only paths relevant to MSYS and checked "mingw32-make --v".
I guess I somehow crushed my MSYS installation... :-/ It's probably a bad idea to keep on the same machine DJGPP, MSVC, Cygwin, MSYS, and Mingw's gcc.

GullRaDriel
Member #3,861
September 2003
avatar

It for sure is confusing !

"Code is like shit - it only smells if it is not yours"
Allegro Wiki, full of examples and articles !!

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Quote:

It may be related to the command interpreter. I normally use 4DOS.COM, but I also tried running make on COMMAND.COM, with variable COMSPEC=C:\COMMAND.COM : It makes no difference.

Shouldn't you be using cmd.exe instead of command.com? I thought command.com was only for compatibility purposes?

Go to: