On Sun, Mar 16, 2008 at 10:14 AM, Oren Ben-Kiki via RT
<bug-Makefile-GraphViz@rt.cpan.org> wrote:
Show quoted text>
> My makefile is generated incrementally from some other files so dependencies
> are written one at a time.
> Graphing this:
>
> all: foo
> all: bar
>
> Shows 'all' depending only on 'bar', not on 'foo'.
Thanks for reporting this. I've fixed it in Makefile::GraphViz 0.17
(as well as its dependency, Makefile::Parser 0.210) and they are
already on CPAN now. Also, I've added support for double colon rules
as a bonus ;) You can try gvmake again to see if it works ;)
Because the Makefile::Parser engine used by the gvmake script is
rather limited in functionalities, it's recommended to call the
makesimple script (provided by Makefile::Parser) to convert your
makefiles to the simplest form __before__ feeding it directly to
gvmake. Here's the commands that *I* normally use myself:
$ makesimple -f input.mk > simplest.mk
$ gvmake -a -f simplest.mk
It's worth mentioning that the makesimple script requires the "make"
program in PATH to be at least GNU make 3.81 (which can be downloaded
from ftp://ftp.gnu.org/pub/gnu/make/ . And it's also compiled well on
Win32 with the Visual C/C++ compiler BTW.
Show quoted text>
> I have tried to look in the code - it "smells" like somewhere the dependency
> list is overwritten instead of appended to - but I got lost in a maze of
> twisty little modules, all different :-)
>
Heh, sorry about the twisty code...it also took me a while to make a patch :P
Thanks!
-agentzh