Mail Archives: djgpp/2002/02/10/10:26:09
Eli Zaretskii wrote:
> If you indeed run "gcc -MM" (without any other switches), GCC should
> have complained about <tmp.h> not found anywhere in the include path.
> So something is missing in your description.
But tmp.h is in the system header directory, c:\djgpp\include\ , isn't
gcc supposed to find it there? (tmp.c is in current directory, say
c:\sven\ ) I double-checked, and "gcc -MM tmp.c" does produce that
result.
Btw, I tested a bit more, putting more #include directives with quotes
in tmp.h, and changing the order of them. The general rule seems to be:
gcc -MM always ignores the first quoted include file but it never
ignores later ones.
> FWIW, GCC 2.95.3 correctly reports the dependencies: if I use -I. -MM
> and <tmp.h>, it doesn't mention any headers except djgpp.ver, and if I
> use -MM alone and change tmp.c to include "tmp.h", it reports all of
> tmp.h, tmp2.h, and tmp3.h. I don't have GCC 3.0.3 installed where I
> type this to test that version.
I don't have an earlier version here so I can't test, but I think this
used to work with 2.95.*, i.e., it didn't produce dependencies to qouted
include files.
Oh, and when I'm at it, what is this djgpp.ver thing anyway? It's not
very good to have it in dependency files which you distribute, so I
usually sed it out. Is there any preferred way to get rid of it?
--
Sven Sandberg svsa1977 AT student DOT uu DOT se home.student.uu.se/svsa1977
- Raw text -