On Fri, Jan 29, 2010 at 11:39 PM, <[email protected]> wrote:
> * Steffen Dettmer wrote on Fri, Jan 29, 2010 at 02:10:16PM CET:
> > here we use doxygen to comment functions in the .h files.
> > When using "make tags", tags for the definitons but not for
> > the declarations are generated. In case of "own functions"
> > this is great (you jump to the implemenations when analysing
> > code) but in other cases it is not and someone may want to
> > see the documentation.
> >
> > What best practices exist here?
>
> You can install Exuberant Ctags and let it tag declarations for
> you, too (use the --<LANG>-kinds= option).

ohh indeed, `make ctags' generates tags_c that also contains refs
to the .h files by default!

> I think cscope can parse declarations as well; git Automake
> provides a 'make cscope' rule.

stef...@raven:/tmp/steffen_exp/new-autotools/systest_exp # make cscope
make: *** No rule to make target `cscope'.  Stop.
stef...@raven:/tmp/steffen_exp/new-autotools/systest_exp # grep -i scope Mak*
stef...@raven:/tmp/steffen_exp/new-autotools/systest_exp # head -1 Makefile
# Makefile.in generated by automake 1.11.1 from Makefile.am.
stef...@raven:/tmp/steffen_exp/new-autotools/systest_exp #

What do I wrong?
(personally I don't know cscope, but a team mate is using it)

> I don't think either of those distinguish between functions
> that you also define and those that you don't define, but why
> should you declare functions from third parties?

Typically, when the headers do not compile, clash, use wrong
types, are missing `const' qualifiers or generate warnings (if
files should not be changed, and only one or very very few
declarations of it are needed).

But back to `make tags', how it is intended to be used, should
users have something like `export ETAGS_ARGS=--declarations' in
their ~/.profile? But this does not work (does not influence
$(ETAGS_ARGS)).

Is there something like `./configure ETAGS_ARGS=--declarations'
(which unfortunately does not work with autoconf-2.65)?

Using `make ETAGS_ARGS=--declarations' works but is inconvenient.
How to set it best?

oki,

Steffen


Reply via email to