title: Exact same command line produces error in Make yet succeeds if run from shell
body: <p>I have a problem that I just can't wrap my head around. I have a minimal example makefile that is supposed to compile a very simple .c file into an executable program.</p>
  
  <p>When I run <strong>make</strong>, the compiler starts compiling and then produces an error message </p>
  
  <blockquote>
    <p>"T:\printOffsets.c:10:21: error: bootIfc.h: No such file or
    directory"</p>
  </blockquote>
  
  <p>Then I copy the exact same command line <strong>make</strong> is using to build the target and run it directly in the same Windows command shell instance, and suddenly compilation succeeds without errors!! The command line is (path names simplified):</p>
  
  <blockquote>
    <p>T:\perl\c\bin\gcc.exe T:\printOffsets.c -IT:\include\ -o
    D:\printOffsets.exe</p>
  </blockquote>
  
  <p>How do I know? Well, <strong>make</strong> prints the command line before it executes it, so I simply copy&amp;paste from the shell.</p>
  
  <p>I don't get it! How is this possible?? How can the exact same command work on the shell and fail if launched from within a Makefile??</p>
  
  <p>I'm using GNU Make 3.82 on Windows 7, by the way.</p>