diff options
author | Karl Hegbloom <hegbloom@pdx.edu> | 2005-06-19 03:50:47 -0400 |
---|---|---|
committer | Sam Ravnborg <sam@mars.(none)> | 2005-07-13 17:45:57 -0400 |
commit | acbef459a663a8349ceb46b5a11ede50fa7909c7 (patch) | |
tree | 793c0d842fc8bafb180c298042e3227e30375ccd /Makefile | |
parent | d2cb1a95c5fa4d1691c90a4f530955b4ea3cfa24 (diff) |
[PATCH] kbuild: make 'cscope -q' play well with cscope.el
I tried the Linux Makefile 'make cscope' target, and found that the
generated database is not compatible with 'cscope.el' under XEmacs.
The thing is that 'cscope.el' does not allow setting the command line
options to the 'cscope' commands it runs, and it errors with a message
about the options not matching the ones used to generate the index.
It turns out the cscope designers already thought of this. The
options can be written into the "cscope.files". The included patch
moves the "-q" and "-k" options from the 'cmd_cscope' to the
'cmd_cscope-file', echoing them into the top of the files listing.
Now the index is generated with the "-q" option, and when 'cscope.el'
performs it's search, it uses that argument as well. Lookups are fast
and everyone is happy.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1177,10 +1177,10 @@ define all-sources | |||
1177 | endef | 1177 | endef |
1178 | 1178 | ||
1179 | quiet_cmd_cscope-file = FILELST cscope.files | 1179 | quiet_cmd_cscope-file = FILELST cscope.files |
1180 | cmd_cscope-file = $(all-sources) > cscope.files | 1180 | cmd_cscope-file = (echo \-k; echo \-q; $(all-sources)) > cscope.files |
1181 | 1181 | ||
1182 | quiet_cmd_cscope = MAKE cscope.out | 1182 | quiet_cmd_cscope = MAKE cscope.out |
1183 | cmd_cscope = cscope -k -b -q | 1183 | cmd_cscope = cscope -b |
1184 | 1184 | ||
1185 | cscope: FORCE | 1185 | cscope: FORCE |
1186 | $(call cmd,cscope-file) | 1186 | $(call cmd,cscope-file) |