Linux内核源码的ctags,cscope应用及增强补丁

我用的是3.1的内核,把内核源码解压到/usr/src/linux目录下

cd /usr/src

patch linux/scripts/tags.sh tags.sh.patch

cd linux

make tags

make cscope

vim ~/.vimrc,加入

set tags+=/usr/src/linux/tags

set nocsverb

cs add /usr/src/linux/cscope.out

tag.sh.patch补丁在3.1上测试过,其它内核版本没测试

该补丁内容

1,把tags,cscope.out中的相对路径改为绝对路径使得可以在任何目录中浏览内核源码,而不是一定要在内核源码目录中

2,增强了代码补全预览的信息,如行号,语言,符号类型用全称,函数原型显示等

截图



 补丁在下面下载

猜你喜欢

转载自haohetao.iteye.com/blog/1279590