Building Qt with MinGW fails

If building Qt or Qt programs fails with something like the following errors:

  1. _cd tools\moc && c:/MinGW/bin/mingw32-make.exe_
  2. _/usr/bin/sh: cd: toolsmoc: No such file or directory_

Make sure sh.exe is not in your path. make will use sh.exe instead of Windows’ standard shell if sh.exe is in the path. Unfortunately sh.exe does not understand Windows-style paths and discards the ‘’ separator. There’s not much Qt can do to work around this make feature. Both Cygwin and MSYS provide sh.exe. Avoid MSYS while building Qt or Qt programs.

No comments

Write a comment

Sorry, you must be logged in to post a comment.