[PATCH] sim: generate build dependencies on the fly

Tom Tromey tromey@redhat.com
Tue Jul 12 19:49:00 GMT 2011


>>>>> "Mike" == Mike Frysinger <vapier@gentoo.org> writes:

Mike> Lift the code that GDB is using to generate dependencies on the
Mike> fly and port it over to the sim.  Now people shouldn't have to
Mike> manually maintain these in their Makefile's (for the most part).

Thanks.  I think it is a good idea.

Mike> Generated header files still need to be manually tracked.

Why is that?

Mike> -VPATH = @srcdir@
Mike> +VPATH = @srcdir@:$(srccom)

The Autoconf manual lists various problems with VPATH.

You can't use variable references in VPATH.

Also VPATH won't work properly with built sources.  I'm not sure if your
patch relies on that or not.

Finally I thought there was some problem with multiple entries in VPATH,
but I cannot find that in the docs.  Perhaps it is one of those ancient
incorrect memories.  It would bear testing with a non-GNU make.

Mike> +depcomp = $(SHELL) $(srcdir)/../depcomp

This seems like the wrong directory to me.
I would have expected $(srcdir)/../../depcomp.

Tom



More information about the Gdb-patches mailing list