From: Richard G Riley <rileyrgdev@googlemail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Emacs + cscope (xcscope.el)
Date: Fri, 12 Oct 2007 19:41:46 +0200 [thread overview]
Message-ID: <5n9purFgtvkpU1@mid.uni-berlin.de> (raw)
In-Reply-To: 87przlz8zs.fsf@post.rwth-aachen.de
Thorsten Bonow <thorsten.bonow@post.rwth-aachen.de> writes:
>>>>>> "Iakie" == Iakie <accelas@gmail.com> writes:
>
> Hi,
>
> Iakie> I edited my .emacs like this: Code:
>
> Iakie> (load-file "/usr/share/emacs/site-lisp/xcscope.el") (require
> Iakie> 'xcscope)
>
> you should take a look at the installation instructions at the beginning of the
> file. In your case, since you put "xcscope.el" in "/usr/share/emacs/site-lisp/",
> the
>
> (require 'xcscope)
>
> should be enough. The directory should be in your `load-path', where emacs looks
> for lisp files (you can check with "C-h v load-path")
>
> You missed the part where you should install the indexer-script. I would do this
> and try everything from within emacs---it is supposed to work.
>
> Iakie> Then, I untar-ed linux kernel in my home folder, under which I ran
> Iakie> cscope to generate search database. And I tried to edit some files
>
> Iakie> Code:
>
> Iakie> me@box:~/linux-source-2.6.22$ cscope -R -q -b
> Iakie> me@box:~/linux-source-2.6.22$ emacs kernel/time.c
>
> You must specify the initial directory in the cscope menu, but even then this
> will fail...
>
> Iakie> When I tried to find symbol definition using C-c s d, it returns no
> Iakie> matched result
>
> ... yup, same here. Works if you let xcscope create the index. Again, you must
> install the cscope-indexer script *first*.
>
> Iakie> Can someone tell me what I did wrong?
I use two scripts to use tags and cscope in conjunction with the oft
overlooked fact that the linux makefiles include makefiles with tags and
cscope targets : i just run "tags" .....
1) ~/bin/tags
,----
| #!/bin/bash
| cd ~/programming
| echo Calculating tags in ~/programming ...
| ctags-exuberant -e --language-force=auto --recurse=yes --links=yes ~/programming
|
| cd /usr/src/linux
| echo Calculating tags in /usr/src
| make TAGS
|
| ~/bin/makecs
| # echo Done!
`----
2) ~/bin/makecs
,----
| #!/bin/bash
|
| SRC=/usr/src/linux
|
| cd $SRC
| echo "CScoping Linux sources ....."
| make cscope
|
| SRC=/home/rgr/programming
|
| cd $SRC
| echo "CScoping ~/programming/c....."
| # find -L $SRC -name "*.[chxsS]" -o -iname \*.php -print > cscope.files
| find -L $SRC -name "*.[chxsS]" -print > cscope.files
| cscope -b -q -u
`----
prev parent reply other threads:[~2007-10-12 17:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-11 17:52 Emacs + cscope (xcscope.el) Iakie
2007-10-11 20:33 ` Thorsten Bonow
2007-10-12 17:41 ` Richard G Riley [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5n9purFgtvkpU1@mid.uni-berlin.de \
--to=rileyrgdev@googlemail.com \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).