file dependency generator?

Eugene Tsyrklevich eugenet at mailcity.com
Fri Apr 28 13:11:38 CDT 2000


~sdpm~
http://cscope.sourceforge.net/ might be of interest to you


--

On Thu, 27 Apr 2000 18:45:00   Todd Rockhold wrote:
>~sdpm~
>Indirect (not Perl code) but perhaps potentially helpful:
>
>http://www.cs.uni-sb.de/RW/users/sander/html/gsvcg1.html
>
>http://data.mpi-sb.mpg.de/internet/news.nsf/Spotlight/19990308
>
>http://www.cs.brown.edu/people/rt/papers/ordal96/ordal96.html
>
>A simple "graph untangling" Java applet is an example in the Java JDK from
>Sun.
>LEDA (C++) has graph drawing algorithms.  I think LEDA is bundled with the
>SuSE Linux distro.
>
>> -----Original Message-----
>> From:	John R. Comeau [SMTP:comeaujr at sd.conexant.com]
>> Sent:	Thursday, April 27, 2000 5:53 PM
>> To:	san-diego-pm-list at happyfunball.pm.org
>> Subject:	file dependency generator?
>> 
>> ~sdpm~
>> I have a large C project I work ON.  We have around 100 .c files.  At
>> one time I attempted to write a Perl program that would graph the
>> dependencies between these files.  What I mean by a 'dependency' is
>> that the C functions in one file call the C functions in another.  I
>> was attempting to graph this relationship in pTk using shapes
>> containing the names of the .c files connected by arrows pointing from
>> a "calling" file to a "called" file.
>> 
>> The graphing in pTk wasn't much of a problem, but trying to figure out
>> how to arrange this many files was a problem.  These file nodes with
>> their connecting arrows ended up looking like a horrible mess, and
>> didn't shed much light on the relationship between the files.  I
>> played around with various algorithms (all invented by myself), but I
>> couldn't come up with anything to sort them out in a clear fashion.
>> Perhaps this means that the project is disorganized and poorly
>> modularized, but I tend to think the problem was more with my
>> algorithm for arranging them in two dimensions.
>> 
>> I was thinking that it would be a lot simpler to just create a
>> text-based structure something like this:
>> 
>> file_A
>>   file_B
>>     file_C
>>     file_D
>>   file_E
>> file_F
>>   file_G
>>   file_B
>>   file_H
>>     file_I
>> 
>> This is sort of like the directory structures you see in file_ browser
>> GUIs or generated by the Unix 'tree' command.  The problem with this
>> is that, like file_B in the example above, the tree is not a regular
>> tree.  Sometimes the branches rejoin themselves.
>> 
>> A similar is solved by the Data::Dumper by referring back to a data
>> structure it has already printed without printing it again.  I could
>> just take that approach and not repeat the tree when it's already been
>> printed.  If I took that approach, I could write a program really
>> quickly with Data::Dumper by just creating a data structure analogous
>> to the file dependency structure and then Data::Dump'ing it.
>> 
>> But does anyone have any ideas for graphing a full tree that shows all
>> the reconnected branches?  I.e. that would show the structure like it
>> really is - like a Hillbilly family tree?  I'd think that other
>> programmers have faced this problem before.
>> 
>> -John
>> ~sdpm~
>> 
>> The posting address is: san-diego-pm-list at hfb.pm.org
>> 
>> List requests should be sent to: majordomo at hfb.pm.org
>> 
>> If you ever want to remove yourself from this mailing list,
>> you can send mail to <majordomo at happyfunball.pm.org> with the following
>> command in the body of your email message:
>> 
>>     unsubscribe san-diego-pm-list
>> 
>> If you ever need to get in contact with the owner of the list,
>> (if you have trouble unsubscribing, or have questions about the
>> list itself) send email to <owner-san-diego-pm-list at happyfunball.pm.org> .
>> This is the general rule for most mailing lists when you need
>> to contact a human.
>~sdpm~
>
>The posting address is: san-diego-pm-list at hfb.pm.org
>
>List requests should be sent to: majordomo at hfb.pm.org
>
>If you ever want to remove yourself from this mailing list,
>you can send mail to <majordomo at happyfunball.pm.org> with the following
>command in the body of your email message:
>
>    unsubscribe san-diego-pm-list
>
>If you ever need to get in contact with the owner of the list,
>(if you have trouble unsubscribing, or have questions about the
>list itself) send email to <owner-san-diego-pm-list at happyfunball.pm.org> .
>This is the general rule for most mailing lists when you need
>to contact a human.
>
>


Get your FREE Email at http://mailcity.lycos.com
Get your PERSONALIZED START PAGE at http://my.lycos.com
~sdpm~

The posting address is: san-diego-pm-list at hfb.pm.org

List requests should be sent to: majordomo at hfb.pm.org

If you ever want to remove yourself from this mailing list,
you can send mail to <majordomo at happyfunball.pm.org> with the following
command in the body of your email message:

    unsubscribe san-diego-pm-list

If you ever need to get in contact with the owner of the list,
(if you have trouble unsubscribing, or have questions about the
list itself) send email to <owner-san-diego-pm-list at happyfunball.pm.org> .
This is the general rule for most mailing lists when you need
to contact a human.




More information about the San-Diego-pm mailing list