title: GCC compiler error on Windows XP
body: <p>I'm getting a totally bizzare error trying to compile a C program using GCC. Here is the batch file I am using:</p>
  
  <pre><code>echo Now compiling, assembling, and linking the core:
  nasm -f aout -o start.o start.asm
  
  gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-functions -nostdinc -fno-builtin -I./include -c -o consoleio.o consoleio.c
  gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-functions -nostdinc -fno-builtin -I./include -c -o core.o core.c
  gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-functions -nostdinc -fno-builtin -I./include -c -o system.o system.c
  
  ld -T link.ld -o core.bin start.o core.o system.o consoleio.o
  echo Done!
  
  concat.py
  
  pause
  </code></pre>
  
  <p>Here are the error messages I am receiving when trying to run this code. All files are in the same directory, yes the PATH variable is set up correctly:</p>
  
  <pre><code>C:\Simple\core&gt;build.bat
  
  C:\Simple\core&gt;echo Now compiling, assembling, and linking the core:
  Now compiling, assembling, and linking the core:
  
  C:\Simple\core&gt;nasm -f aout -o start.o start.asm
  
  C:\Simple\core&gt;gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-func
  tions -nostdinc -fno-builtin -I./include -c -o consoleio.o consoleio.c
  The system cannot execute the specified program.
  
  C:\Simple\core&gt;gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-func
  tions -nostdinc -fno-builtin -I./include -c -o core.o core.c
  
  C:\Simple\core&gt;gcc -Wall -O -fstrength-reduce -fomit-frame-pointer -finline-func
  tions -nostdinc -fno-builtin -I./include -c -o system.o system.c
  The system cannot execute the specified program.
  
  C:\Simple\core&gt;ld -T link.ld -o core.bin start.o core.o system.o consoleio.o
  c:/djgpp/bin/ld.exe: system.o: No such file: No such file or directory (ENOENT)
  
  C:\Simple\core&gt;echo Done!
  Done!
  
  C:\Simple\core&gt;concat.py
  Traceback (most recent call last):
    File "C:\Simple\core\concat.py", line 12, in &lt;module&gt;
      with open("core.bin", "rb") as core:
  IOError: [Errno 2] No such file or directory: 'core.bin'
  </code></pre>
  
  <p>Now, the interesting thing is the gcc command, which is the issue I'm having. (The other issues seem to be cascading from this.) When compiling core.c, the GCC command works just fine and great, and produces a .o file as expected. When attempting to compile system.c or consoleio.c, GCC fails, but in a very unexpected way: it appears as though windows cannot run the program. This makes <strong>zero</strong> sense to me. I've tried any number of things, including running these commands myself outside the window. Something about core.c is just special, and I can't figure out what the difference is. I literally copied that line and changed the filenames to create the other two lines that are failing.</p>
  
  <p>So, in short, HELP. I'm using DJGPP and GCC on windows XP, along with a python script at the end that should tie everything together. (This all worked when the project was a single source file, but attempting to split the file into separate files has caused this strange error.)</p>
  
  <p>Thanks.</p>
  
  <p>PS: Yes, we <em>are</em> using a batch file, and I know that makes some of you cringe. However, I'd really like to understand this error before moving on to a makefile if possible. ^_^</p>
  
  <p>EDIT:  The accepted answer was indeed our problem, although the issue was with DJGPP, not Windows. (Windows doesn't seem to have a command limit.) The solution was to compile with MinGW instead of DJGPP, which fixed the issue right away. Thanks guys!</p>