The -MT option really does use precisely the specified string as the target. It would be better if spaces (and other funny characters) were escaped (using backslash) in the output. Note: for my purposes it would be enough to follow the proposal in bug #15185 that there be an option to force the full path name in the target. EXAMPLE: compare the outputs of the following two calls to gcc $ touch my\ prog.c $ gcc -MM my\ prog.c my\ prog.o: my\ prog.c $ gcc -MM my\ prog.c -MT my\ prog.o my prog.o: my\ prog.c I am inclined to say that the second output is wrong.
-- Summary: -MT option does not escape funny characters Product: gcc Version: 3.4.3 Status: UNCONFIRMED Severity: enhancement Priority: P2 Component: preprocessor AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: abbott at dima dot unige dot it CC: gcc-bugs at gcc dot gnu dot org GCC build triplet: i486-slackware-linux GCC host triplet: i486-slackware-linux GCC target triplet: i486-slackware-linux http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19361