Hi CompilerGuru,
Your idea about make changing -I"..." to "-I..." is right. I am using GNU make 3.80. The solution to the problem was to keep sh.exe out of my path (distributed with a lot of gcc-based toolchains). Here's what I found...
Now I'm using piper.exe, it's a lot easier to debug what's going on:
D:\freescale\Devel_with_makefile>make -d test
Must remake target `test'.
"c:/Program Files/Freescale/CodeWarrior for HC08 V5.1/prog/piper.exe" "c:/Progra
m Files/Freescale/CodeWarrior for HC08 V5.1/prog/chc08.exe" -WStdoutOn -Ansi -Is
rc/CSP/908ey16 -Isrc -I"c:/Program Files/Freescale/CodeWarrior for HC08 V5.1/lib
/hc08c/include" src/main.c -ObjN=%n.o
CreateProcess(c:\winavr\utils\bin\sh.exe,c:/winavr/utils/bin/sh.exe -c "\"c:/Pro
gram Files/Freescale/CodeWarrior for HC08 V5.1/prog/piper.exe\" \"c:/Program Fil
es/Freescale/CodeWarrior for HC08 V5.1/prog/chc08.exe\" -WStdoutOn -Ansi -Isrc/C
SP/908ey16 -Isrc -I\"c:/Program Files/Freescale/CodeWarrior for HC08 V5.1/lib/hc
08c/include\" src/main.c -ObjN=%n.o",...)
Putting child 0x00993d88 (test) PID 10054448 on the chain.
Live child 0x00993d88 (test) PID 10054448
FATAL C50: Input file '-Ic:/Program Files/Freescale/CodeWarrior for HC08 V5.1/li
b/hc08c/include' not found
*** command line: '-WStdoutOn -Ansi -Isrc/CSP/908ey16 -Isrc "-Ic:/Program Files/
Freescale/CodeWarrior for HC08 V5.1/lib/hc08c/include" src/main.c -ObjN=%n.o' **
*
HC08 Compiler: *** Error occurred while processing! ***
Reaping losing child 0x00993d88 PID 10054448
make: *** [test] Error 1
Removing child 0x00993d88 PID 10054448 from chain.
Notice that the include path in CreateProcess(...) is fine, so it doesn't look to be a GNU make problem, however the command line that chc08 complains about now has the " before the -I.
I cleaned up my Path environment so I wasn't pulling in utilities from other chains and made sure sh.exe was no longer available to GNU make. That fixed the problem.
Thanks CompilerGuru.
Regards,
vegie_stu