>>>>> "Tom" == Tom Tromey <[EMAIL PROTECTED]> writes:
Tom> gcc3 very nearly does exactly what automake wants in terms of
Tom> dependency tracking.
Tom> I think that ideally automake should recognize this and avoid
Tom> using depcomp when it discovers that the user is using gcc3. In
Tom> this situation instead of invoking depcomp we would just invoke
Tom> gcc like depcomp does (with a small change):
Tom> gcc <args> <dependency args> && mv "$tmpdepfile" "$depfile"
Tom> I don't think we need the explicit `rm $tmpdepfile' because the
Tom> whole problem is that gcc deletes it on failure.
Tom> Akim, any comments on the best approach to implementing this?
Tom> One problem I see is that detecting gcc3 in a
Tom> language-independent way is not going to be easy, at least not
Tom> without autoconf assistance.
Well, at first sight we might be doing good with the current scheme.
I might very well be underestimating some issues, but let me just
imagine :)
Say for .o:
?GENERIC?.%EXT%.o:
?!GENERIC?%OBJ%: %SOURCE%
if %AMDEP%
source='%SOURCE%' object='%OBJ%' libtool=no @AMDEPBACKSLASH@
depfile='$(DEPDIR)/%BASE%.Po' tmpdepfile='$(DEPDIR)/%BASE%.TPo'
@AMDEPBACKSLASH@
$(%FPFX%DEPMODE) $(depcomp) @AMDEPBACKSLASH@
endif %AMDEP%
?-o? %COMPILE% %-c% %-o% %OBJ% `test -f %SOURCE% || echo '$(srcdir)/'`%SOURCE%
?!-o? %COMPILE% %-c% `test -f %SOURCE% || echo '$(srcdir)/'`%SOURCE%
we can map %AMDEP% to something else than FALSE or AMDEP, but, say,
CCAMDEP, and let the
if CCAMDEP
endif CCAMDEP
magic happen. And conditioning the mv should be quite easy too.
Am I missing something?