pr@fctunl.rccn.pt (Paulo Rosado) (06/07/90)
I was given this medium-size system with about 15 *.c modules and respective
*.h ones, to extend. The program was developed in an incremental not nicely
way so _every_ c module includes _every_ h file. I want to rearrange this and
define exactly what is defined/used by whom, at least, in order to get a
better profit from the make utility.
Ok, what'd like to know if there is some kind of lint utility who could output
a list of types, vars, macros and functions used but not defined in a module.
Also, if anyone knows where I can find a lex/yacc C grammar that would be
nice. That way I could build my own utility with less effort.
Of course if everyone has some different approachs to achieve the main
objective I'll be glad to hear them.
I apologize if this not the right group to post this kind request but it
sounded suitable.
Thanks in advance.
------------
paulo rosado _ Centro de Inteligencia Artificial Uninova
email: pr@fctunl.rccn.pt -- pr@unl.uucp
snail: Fac. de Ciencias e Tecnologia-UNL, 2825 Monte de Caparica, PORTUGAL
[A reasonable request. For functions, cross-referencing the object files is
a simple way to find out who defines and uses what; it is quite easy to build
a crossreferencer with nm, sort, and awk. Beyond that, there's cscope, a
funky but very useful crossreference utility that comes with System V.3.2, but
I haven't seen anything to mark preprocessor definitions and uses by module.
-John]
--
Send compilers articles to compilers@esegue.segue.boston.ma.us
{spdcc | ima | lotus}!esegue. Meta-mail to compilers-request@esegue.
Please send responses to the author of the message, not the poster.pardo@cs.washington.edu (David Keppel) (06/08/90)
pr@fctunl.rccn.pt (Paulo Rosado) writes: >[15 .c modules, 15 .h modules. How do I figure out relationships?] There was a project at UC Berkeley 4 years ago called `CIA' for "C Inforemation Abstractor". It was being done under prof. C. V. Ramamorthy. Perhaps somebody there knows or could inquire as to what ever heppened to it? ;-D oN ( FBI: Fortran Bestower of Information ) Pardo -- pardo@cs.washington.edu {rutgers,cornell,ucsd,ubc-cs,tektronix}!uw-beaver!june!pardo -- Send compilers articles to compilers@esegue.segue.boston.ma.us {spdcc | ima | lotus}!esegue. Meta-mail to compilers-request@esegue. Please send responses to the author of the message, not the poster.