|Looking for tool to generate C/C++ crossrefs email@example.com (Andrew Berg) (1998-10-04)|
|Re: Looking for tool to generate C/C++ crossrefs firstname.lastname@example.org (Dr Richard A. O'Keefe) (1998-10-06)|
|Re: Looking for tool to generate C/C++ crossrefs email@example.com (Wolfgang Keil) (1998-10-07)|
|Re: Looking for tool to generate C/C++ crossrefs firstname.lastname@example.org (1998-10-10)|
|Re: Looking for tool to generate C/C++ crossrefs email@example.com (Greg Jaxon) (1998-10-13)|
|From:||Andrew Berg <firstname.lastname@example.org>|
|Date:||4 Oct 1998 01:15:00 -0400|
|Keywords:||C, C++, tools, question, comment|
I am looking for a tool to generate cross references for a collection
of C/C++ source and header files. Basically all I want is for each
symbol to know the line it is defined on and the lines it is
referenced on. Ideally this would include preprocessor macros.
I have considered so far:
Writing my own. This looks like a lot of work even if I start with
existing C/C++ grammars and just add the 100 lines or so to keep track
of the symbols, because I still have to write my own preprocessor to
resolve macros. Does anybody know how to avoid doing that?
Building a custom gcc. Making a gcc just dump out the stuff I need
may or may not be so hard, I have not looked, but it is my
understanding that I will not have any information about the macros.
Can anybody confirm or deny this?
Is there any other options that I just don't see?
[There are various ways to fake it, e.g., compile to assembler or
object and extract the symbols from there, but doing a good
crossreference is a challenge, particularly if you want to do
something reasonable with symbols mentioned in macros and the like.
Return to the
Search the comp.compilers archives again.