title: Eclipse CDT -- program "make" cannot be found (win7, mingw, msys installed)
body: <p>I'm running Eclipse Juno with CDT on Windows 7. Have installed MinGW with msys and set up my PATH. If I just run <code>cmd.exe</code> and type <code>make</code>, it runs the msys <code>make.exe</code>:</p>
  
  <pre><code>C:\Users\dev&gt;make
  make: *** No targets specified and no makefile found.  Stop.
  
  C:\Users\dev&gt;echo %PATH%
  C:\Program Files (x86)\Windows Resource Kits\Tools\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\MySQL\MySQL Server 5.5\bin;C:\Program Files (x86)\php;C:\Program Files (x86)\libtidy\bin;C:\Program Files\7-Zip;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Java\jdk1.7.0\bin;C:\Program Files (x86)\apache-ant-1.8.4\bin;C:\Program Files\TortoiseHg\;C:\Program Files (x86)\Windows Resource Kits\Tools\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\MySQL\MySQL Server 5.5\bin;C:\Program Files (x86)\php;C:\Program Files (x86)\libtidy\bin;C:\Program Files\7-Zip;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Java\jdk1.7.0\bin;C:\Program Files (x86)\apache-ant-1.8.4\bin;C:\Program Files\TortoiseHg\;C:\Program Files (x86)\MinGW\bin;C:\Program Files (x86)\MinGW\msys\1.0\bin
  </code></pre>
  
  <p>So far so good. But even after restarting Eclipse (even rebooting Windows!), CDT gives me the following error message when I try to make the simple "Hello World" C program:</p>
  
  <pre><code>Program "make" not found in PATH
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/1mCbM.png" alt="Eclipse errors output"></p>
  
  <p>The funny thing is, if I run the following Java code from Eclipse...</p>
  
  <pre><code>import java.io.BufferedReader;
  import java.io.InputStreamReader;
  
  public class Temp {
      public static void main(String[] args) {
          System.out.println(System.getenv("PATH"));
          try {
              String line;
              Process p = Runtime.getRuntime().exec("make");
              BufferedReader input =
                new BufferedReader
                  (new InputStreamReader(p.getErrorStream()));
              while ((line = input.readLine()) != null) {
                  System.out.println(line);
              }
              input.close();
            }
            catch (Exception err) {
              err.printStackTrace();
            }
      }
  }
  </code></pre>
  
  <p>...I get exactly the output I would expect, namely:</p>
  
  <pre><code>C:\Program Files (x86)\Windows Resource Kits\Tools\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\MySQL\MySQL Server 5.5\bin;C:\Program Files (x86)\php;C:\Program Files (x86)\libtidy\bin;C:\Program Files\7-Zip;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Java\jdk1.7.0\bin;C:\Program Files (x86)\apache-ant-1.8.4\bin;C:\Program Files\TortoiseHg\;C:\Program Files (x86)\MinGW\bin;C:\Program Files (x86)\MinGW\msys\1.0\bin
  make: *** No targets specified and no makefile found.  Stop.
  </code></pre>
  
  <p>Why can't Eclipse CDT find <code>make</code> when everybody else can!?</p>