Patch: automatic dependencies for gcc
Ralf Wildenhues
Ralf.Wildenhues@gmx.de
Sun Mar 9 16:36:00 GMT 2008
* Tom Tromey wrote on Sun, Mar 09, 2008 at 04:09:53PM CET:
> >>>>> "Ralf" == Ralf Wildenhues <Ralf.Wildenhues@gmx.de> writes:
>
> Ralf> The reason I see against my proposal that IMVHO carries real weight
> Ralf> would be if you were to require up to date deps files. I would not know
> Ralf> how to easily reformulate
> Ralf> %.o $(DEPDIR)/%.d: %.c
> Ralf> rules into the subdir/$(DEPDIR) scheme. Why aren't you using this BTW?
> Ralf> It would already be a bit safer than what you currently have, even if
> Ralf> you don't go all the way and make $(DEPFILES) a prerequisite of 'all'.
>
> It seems to me that this will cause us to run these rules at -include
> time. -include will not error if the file does not exist, but if the
> file can be remade, make will try to do that.
I don't think make will ignore prerequisites of the .c files when
considering remaking include files. If it did, I'd consider that
a bug. Or does gcc/Makefile.in not have full dependency information?
> I think include time is too early to build the .d files.
Sure. But I think make would just remake them after redoing whatever
else it needs to redo. But maybe I have also misunderstood you.
Cheers,
Ralf
More information about the Gcc-patches
mailing list