rpms/cscope/devel cscope-15.6-findassign.patch, NONE, 1.1 cscope-15.6-ocs.patch, NONE, 1.1 cscope-15.6-sigwinch-linemode.patch, NONE, 1.1 cscope-15.6-xcscope-man.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 cscope.spec, 1.34, 1.35 sources, 1.4, 1.5 cscope-15.5-findassign.patch, 1.1, NONE cscope-15.5-fscanf-overflows.patch, 1.2, NONE cscope-15.5-inv-overflow.patch, 1.1, NONE cscope-15.5-inverted.patch, 1.2, NONE cscope-15.5-ocs-dash_s_fix.patch, 1.2, NONE cscope-15.5-ocs-sysdir.patch, 1.1, NONE cscope-15.5-ocs.patch, 1.1, NONE cscope-15.5-putstring-overflow.patch, 1.1, NONE cscope-15.5-resize.patch, 1.5, NONE cscope-15.5-samelist.patch, 1.1, NONE cscope-15.5-tempsec.patch, 1.2, NONE cscope-15.5-xcscope-man.patch, 1.1, NONE

Neil Horman (nhorman) fedora-extras-commits at redhat.com
Fri Mar 14 13:07:20 UTC 2008


Author: nhorman

Update of /cvs/extras/rpms/cscope/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv25018

Modified Files:
	.cvsignore cscope.spec sources 
Added Files:
	cscope-15.6-findassign.patch cscope-15.6-ocs.patch 
	cscope-15.6-sigwinch-linemode.patch 
	cscope-15.6-xcscope-man.patch 
Removed Files:
	cscope-15.5-findassign.patch 
	cscope-15.5-fscanf-overflows.patch 
	cscope-15.5-inv-overflow.patch cscope-15.5-inverted.patch 
	cscope-15.5-ocs-dash_s_fix.patch cscope-15.5-ocs-sysdir.patch 
	cscope-15.5-ocs.patch cscope-15.5-putstring-overflow.patch 
	cscope-15.5-resize.patch cscope-15.5-samelist.patch 
	cscope-15.5-tempsec.patch cscope-15.5-xcscope-man.patch 
Log Message:
Resolves: bz 343671

cscope-15.6-findassign.patch:

--- NEW FILE cscope-15.6-findassign.patch ---
--- cscope-15.6/src/display.c.orig	2006-09-30 04:13:00.000000000 -0400
+++ cscope-15.6/src/display.c	2007-05-25 10:15:14.000000000 -0400
@@ -113,6 +113,7 @@
 	{"Find this", "file",				findfile},
 	{"Find", "files #including this file",		findinclude},
 	{"Find all", "function definitions",		findallfcns},	/* samuel only */
+	{"Find all", "symbol assignments",		findassign},
 };
 
 /* Internal prototypes: */
--- cscope-15.6/src/global.h.orig	2006-09-30 04:13:00.000000000 -0400
+++ cscope-15.6/src/global.h	2007-05-25 10:15:14.000000000 -0400
@@ -327,6 +327,7 @@
 char	*findfile(char *dummy);
 char	*findinclude(char *pattern);
 char	*findsymbol(char *pattern);
+char	*findassign(char *pattern);
 char	*findregexp(char *egreppat);
 char	*findstring(char *pattern);
 char	*inviewpath(char *file);
--- cscope-15.6/src/find.c.orig	2006-09-30 04:13:00.000000000 -0400
+++ cscope-15.6/src/find.c	2007-05-25 10:15:27.000000000 -0400
@@ -79,6 +79,8 @@
 static	void	findcalledbysub(char *file, BOOL macro);
 static	void	findterm(char *pattern);
 static	void	putline(FILE *output);
+static  char    *find_symbol_or_assignment(char *pattern, BOOL assign_flag);
+static  BOOL    check_for_assignment(void);
 static	void	putpostingref(POSTING *p, char *pat);
 static	void	putref(int seemore, char *file, char *func);
 static	void	putsource(int seemore, FILE *output);
@@ -88,6 +90,77 @@
 char *
 findsymbol(char *pattern)
 {
+	return find_symbol_or_assignment(pattern, NO);
+}
+
+/* find the symbol in the cross-reference, and look for assignments */
+char *
+findassign(char *pattern)
+{
+	return find_symbol_or_assignment(pattern, YES);
+}
+
+/* Test reference whether it's an assignment to the symbol found at
+ * (global variable) 'blockp' */
+static BOOL
+check_for_assignment(void) 
+{
+	/* Do the extra work here to determine if this is an
+	* assignment or not Do this by examining the next character
+	* or two in blockp */
+	char *asgn_char = blockp;
+	int i = 1; /*skip any leading \n*/
+
+	while(1) {
+		if (asgn_char[i] == blockmark) {
+			/* get the next block when we reach the end of
+			* the current block */
+			asgn_char = read_block();
+			i=0;
+		}
+		while (isspace((unsigned char) asgn_char[i])) {
+			/* skip any whitespace or \n */
+			i++;
+		}
+		/* this next character better be one of the assignment
+		* characters, ie: =, +=, -=, *=, %=, /=, &=, |=, ^=,
+		* ~= if not, then its a notmatched case */
+		if ((asgn_char[i] != '=') &&
+		   (asgn_char[i] != '+') && 
+		   (asgn_char[i] != '-') && 
+		   (asgn_char[i] != '*') && 
+		   (asgn_char[i] != '/') && 
+		   (asgn_char[i] != '%') && 
+		   (asgn_char[i] != '&') && 
+		   (asgn_char[i] != '|') && 
+		   (asgn_char[i] != '^') && 
+		   (asgn_char[i] != '~')) {
+			return NO;
+		} else {
+			/* if the first found character is = and the
+			* next found character is also =, then this
+			* is not an assignment.  likewise if the
+			* first character is not = (i.e. one of the
+			* +,-,*,etc. chars and the next character is
+			* not =, then this is not an assignment */
+			if ((((asgn_char[i] == '=')
+			     && (asgn_char[i+1] == '='))) 
+			   || ((asgn_char[i] != '=')
+				&& (asgn_char[i+1] != '='))) {
+				return NO;
+			}
+			/* if we pass all these filters then this is
+			* an assignment */
+			return YES;
+		} /* else(operator char?) */
+	} /* while(endless) */
+}
+
+/* The actual routine that does the work for findsymbol() and
+* findassign() */
+static char *
+find_symbol_or_assignment(char *pattern, BOOL assign_flag)
+{
 	char	file[PATHLEN + 1];	/* source file name */
 	char	function[PATLEN + 1];	/* function name */
 	char	macro[PATLEN + 1];	/* macro name */
@@ -249,6 +322,14 @@
 			if (matchrest()) {
 				s = NULL;
 		matched:
+				/* if the assignment flag is set then
+				 * we are looking for assignments and
+				 * some extra filtering is needed */
+				if(assign_flag == YES
+				  && ! check_for_assignment())
+				       goto notmatched;
+
+
 				/* output the file, function or macro, and source line */
 				if (strcmp(macro, global) && s != macro) {
 					putref(0, file, macro);
--- cscope-15.6/src/constants.h.orig	2006-09-30 04:13:00.000000000 -0400
+++ cscope-15.6/src/constants.h	2007-05-25 10:15:14.000000000 -0400
@@ -101,7 +101,7 @@
 #define	REGEXP		6
 #define FILENAME	7
 #define INCLUDES	8
-#define	FIELDS		9
+#define	FIELDS		11
 
 #if (BSD || V9) && !__NetBSD__ && !__FreeBSD__
 # define TERMINFO	0	/* no terminfo curses */

cscope-15.6-ocs.patch:

--- NEW FILE cscope-15.6-ocs.patch ---
--- cscope-15.6/contrib/ocs.orig1	2006-09-30 04:12:58.000000000 -0400
+++ cscope-15.6/contrib/ocs	2007-05-25 10:04:01.000000000 -0400
@@ -75,7 +75,7 @@
 
 #set the default value for SYSDIR 
 if [ -z "${SYSDIR}" ]; then
-   SYSDIR=/usr/local/lib/cs
+   SYSDIR=/var/run/cs
    echo setting default sysdir
 fi
 

cscope-15.6-sigwinch-linemode.patch:

--- NEW FILE cscope-15.6-sigwinch-linemode.patch ---
--- cscope-15.6/src/main.c.orig	2007-05-25 10:11:02.000000000 -0400
+++ cscope-15.6/src/main.c	2007-05-25 10:12:43.000000000 -0400
@@ -153,12 +153,7 @@
     yyout = stdout;
     /* save the command name for messages */
     argv0 = argv[0];
-#if defined(KEY_RESIZE) && !defined(__DJGPP__)
-    winch_action.sa_sigaction = sigwinch_handler;
-    sigemptyset(&winch_action.sa_mask);
-    winch_action.sa_flags = SA_SIGINFO;
-    sigaction(SIGWINCH,&winch_action,NULL);
-#endif
+
     /* set the options */
     while (--argc > 0 && (*++argv)[0] == '-') {
 	/* HBB 20030814: add GNU-style --help and --version options */
@@ -400,6 +395,13 @@
     }
 
     if (linemode == NO) {
+	
+#if defined(KEY_RESIZE) && !defined(__DJGPP__)
+	winch_action.sa_sigaction = sigwinch_handler;
+	sigemptyset(&winch_action.sa_mask);
+	winch_action.sa_flags = SA_SIGINFO;
+	sigaction(SIGWINCH,&winch_action,NULL);
+#endif
 	signal(SIGINT, SIG_IGN);	/* ignore interrupts */
 	signal(SIGPIPE, SIG_IGN);/* | command can cause pipe signal */
 

cscope-15.6-xcscope-man.patch:

--- NEW FILE cscope-15.6-xcscope-man.patch ---
--- /dev/null	2007-05-12 17:40:21.471089444 -0400
+++ cscope-15.6/doc/xcscope.1	2007-05-25 09:45:31.000000000 -0400
@@ -0,0 +1,577 @@
+'\" t
+.\" The xcscope.el man page
+.\" Origionally written by Darryl Okahata, Apr 2000
+.\" 
+.\" Converted to a man page July 20, 2004 by Neil Horman <nhorman at redhat.com>
+.\"
+
+.PU
+.TH XCSCOPE.EL "1" "April 2000" "Darryl Okahata"
+.SH NAME
+xcscope.el - xemacs cscope lisp support package
+.SH DESCRIPTION
+xcscope is a lisp package for use in integrating cscope 
+functionality into xemacs
+.SH INSTALLATION
+.P
+ Installation steps:
+
+.P
+ 0. (It is, of course, assumed that cscope is already properly
+    installed on the current system.)
+.P
+ 1. Ensure that the location of cscope-indexer is located in your path
+
+.P
+ 2. Ensure that the location of xcscope.el is in the xemacs module load path
+
+.P
+ 3. Edit your ~/.emacs file to add the line:
+.P
+.BI      (require 'xcscope)
+
+.P
+5. If you intend to use xcscope.el often you can optionally edit your
+~/.emacs file to add keybindings that reduce the number of keystrokes
+required.  For example, the following will add "C-f#" keybindings,
+which are easier to type than the usual "C-c s" prefixed keybindings.
+Note that specifying "global-map" instead of "cscope:map" makes the
+keybindings available in all buffers:
+.nf
+	(define-key global-map [(ctrl f3)]  'cscope-set-initial-directory)
+	(define-key global-map [(ctrl f4)]  'cscope-unset-initial-directory)
+	(define-key global-map [(ctrl f5)]  'cscope-find-this-symbol)
+	(define-key global-map [(ctrl f6)]  'cscope-find-global-definition)
+	(define-key global-map [(ctrl f7)]
+		cscope-find-global-definition-no-prompting)
+	(define-key global-map [(ctrl f8)]  'cscope-pop-mark)
+	(define-key global-map [(ctrl f9)]  'cscope-next-symbol)
+	(define-key global-map [(ctrl f10)] 'cscope-next-file)
+	(define-key global-map [(ctrl f11)] 'cscope-prev-symbol)
+	(define-key global-map [(ctrl f12)] 'cscope-prev-file)
+	(define-key global-map [(meta f9)]  'cscope-display-buffer)
+	(define-key global-map [(meta f10)] 'cscope-display-buffer-toggle)
+.fi
+
+.P
+ 6. Restart (X)Emacs.  That's it.
+
+
+.SH USING THIS MODULE
+
+.SS * Basic usage:
+
+.P
+ If all of your C/C++/lex/yacc source files are in the same
+ directory, you can just start using this module.  If your files are
+ spread out over multiple directories, see "Advanced usage", below.
+
+.P
+ Just edit a source file, and use the pull-down or pop-up (button 3)
+ menus to select one of:
+
+.nf
+	Find symbol
+	Find global definition
+	Find called functions
+	Find functions calling a function
+	Find text string
+	Find egrep pattern
+	Find a file
+	Find files #including a file
+.fi
+
+.P
+The cscope database will be automatically created in the same directory 
+as the source files (assuming that you've never used cscope before), and
+a buffer will pop-up displaying the results.  You can then use button 2
+(the middle button) on the mouse to edit the selected file, or you can
+move the text cursor over a selection and press [Enter].
+
+.P
+Hopefully, the interface should be fairly intuitive.
+
+.SS * Locating the cscope databases:
+
+.P
+This module will first use the variable, `cscope-database-regexps',
+to search for a suitable database directory.  If a database location
+cannot be found using this variable then a search is begun at the
+variable, `cscope-initial-directory', if set, or the current
+directory otherwise.  If the directory is not a cscope database
+directory then the directory's parent, parent's parent, etc. is
+searched until a cscope database directory is found, or the root
+directory is reached.  If the root directory is reached, the current
+directory will be used.
+
+.P
+A cscope database directory is one in which EITHER a cscope database
+file (e.g., "cscope.out") OR a cscope file list (e.g.,
+"cscope.files") exists.  If only "cscope.files" exists, the
+corresponding "cscope.out" will be automatically created by cscope
+when a search is done.  By default, the cscope database file is called
+"cscope.out", but this can be changed (on a global basis) via the
+variable, `cscope-database-file'.  There is limited support for cscope
+databases that are named differently than that given by
+`cscope-database-file', using the variable, `cscope-database-regexps'.
+
+.P
+Note that the variable, `cscope-database-regexps', is generally not
+needed, as the normal hierarchical database search is sufficient
+for placing and/or locating the cscope databases.  However, there
+may be cases where it makes sense to place the cscope databases
+away from where the source files are kept; in this case, this
+variable is used to determine the mapping.  One use for this
+variable is when you want to share the database file with other
+users; in this case, the database may be located in a directory
+separate from the source files.  
+
+.P
+Setting the variable, `cscope-initial-directory', is useful when a
+search is to be expanded by specifying a cscope database directory
+that is a parent of the directory that this module would otherwise
+use.  For example, consider a project that contains the following
+cscope database directories:
+
+.nf
+	/users/jdoe/sources
+	/users/jdoe/sources/proj1
+	/users/jdoe/sources/proj2
+.fi
+
+.P
+If a search is initiated from a .c file in /users/jdoe/sources/proj1
+then (assuming the variable, `cscope-database-regexps', is not set)
+/users/jdoe/sources/proj1 will be used as the cscope data base directory.
+Only matches in files in /users/jdoe/sources/proj1 will be found.  This
+can be remedied by typing "C-c s a" and then "M-del" to remove single
+path element in order to use a cscope database directory of
+/users/jdoe/sources.  Normal searching can be restored by typing "C-c s A".
+
+
+
+.SS * Keybindings:
+
+.P
+All keybindings use the "C-c s" prefix, but are usable only while
+editing a source file, or in the cscope results buffer:
+
+.BI     "C-c s s         Find symbol."
+.TP
+.BI     "C-c s d         Find global definition."
+.TP
+.BI     "C-c s g         Find global definition (alternate binding)."
+.TP
+.BI     "C-c s G         Find global definition without prompting."
+.TP
+.BI     "C-c s c         Find functions calling a function."
+.TP
+.BI     "C-c s C         Find called functions (list functions called"
+.BI     "                from a function)."
+.TP
+.BI     "C-c s t         Find text string."
+.TP
+.BI     "C-c s e         Find egrep pattern."
+.TP
+.BI     "C-c s f         Find a file."
+.TP
+.BI     "C-c s i         Find files #including a file."
+
+.P
+These pertain to navigation through the search results:
+
+.P
+.BI     "C-c s b         Display *cscope* buffer."
+.TP
+.BI     "C-c s B         Auto display *cscope* buffer toggle."
+.TP
+.BI     "C-c s n         Next symbol."
+.TP
+.BI     "C-c s N         Next file."
+.TP
+.BI     "C-c s p         Previous symbol."
+.TP
+.BI     "C-c s P         Previous file."
+.TP
+.BI     "C-c s u         Pop mark."
+
+.P
+These pertain to setting and unsetting the variable,
+`cscope-initial-directory', (location searched for the cscope database
+directory):
+
+.P
+.BI     "C-c s a         Set initial directory."
+.TP
+.BI     "C-c s A         Unset initial directory."
+
+.P
+These pertain to cscope database maintenance:
+.P
+.BI     "C-c s L         Create list of files to index."
+.TP
+.BI     "C-c s I         Create list and index."
+.TP
+.BI     "C-c s E         Edit list of files to index."
+.TP
+.BI     "C-c s W          Locate this buffer's cscope directory"
+.BI     "                 ("
+"W" --> "where"
+.BI ")."
+.TP
+.BI     "C-c s S         Locate this buffer's cscope directory."
+.BI     "                 (alternate binding: "
+"S" --> "show"
+.BI ")."
+.TP
+.BI     "C-c s T         Locate this buffer's cscope directory."
+.BI     "                 (alternate binding: "
+"T" --> "tell"
+.BI ")."
+.TP
+.BI     "C-c s D         Dired this buffer's directory."
+
+.P
+.SS * Advanced usage:
+
+.P
+If the source files are spread out over multiple directories,
+you've got a few choices:
+
+.P
+[ NOTE: you will need to have the script, "cscope-indexer",
+properly installed in order for the following to work.  ]
+
+.P
+1. If all of the directories exist below a common directory
+(without any extraneous, unrelated subdirectories), you can tell
+this module to place the cscope database into the top-level,
+common directory.  This assumes that you do not have any cscope
+databases in any of the subdirectories.  If you do, you should
+delete them; otherwise, they will take precedence over the
+top-level database.
+
+.P
+If you do have cscope databases in any subdirectory, the
+following instructions may not work right.
+
+.P
+It's pretty easy to tell this module to use a top-level, common
+directory:
+
+.HP
+a. Make sure that the menu pick, "Cscope/Index recursively", is
+checked (the default value).
+
+.HP
+b. Select the menu pick, "Cscope/Create list and index", and
+specify the top-level directory.  This will run the script,
+"cscope-indexer", in the background, so you can do other
+things if indexing takes a long time.  A list of files to
+index will be created in "cscope.files", and the cscope
+database will be created in "cscope.out".
+
+.HP
+Once this has been done, you can then use the menu picks
+(described in "Basic usage", above) to search for symbols.
+
+.HP
+Note, however, that, if you add or delete source files, you'll
+have to either rebuild the database using the above procedure,
+or edit the file, "cscope.files" to add/delete the names of the
+source files.  To edit this file, you can use the menu pick,
+"Cscope/Edit list of files to index".
+
+.P
+2. If most of the files exist below a common directory, but a few
+are outside, you can use the menu pick, "Cscope/Create list of
+files to index", and specify the top-level directory.  Make sure
+that "Cscope/Index recursively", is checked before you do so,
+though.  You can then edit the list of files to index using the
+menu pick, "Cscope/Edit list of files to index".  Just edit the
+list to include any additional source files not already listed.
+
+.P
+Once you've created, edited, and saved the list, you can then
+use the menu picks described under "Basic usage", above, to
+search for symbols.  The first time you search, you will have to
+wait a while for cscope to fully index the source files, though.
+If you have a lot of source files, you may want to manually run
+cscope to build the database:
+
+.nf
+	cd top-level-directory    # or wherever
+	rm -f cscope.out          # not always necessary
+	cscope -b
+.fi
+
+.P
+ 3. If the source files are scattered in many different, unrelated
+    places, you'll have to manually create cscope.files and put a
+    list of all pathnames into it.  Then build the database using:
+
+.nf
+	cd some-directory         # wherever cscope.files exists
+	rm -f cscope.out          # not always necessary
+	cscope -b
+.fi
+
+.P
+Next, read the documentation for the variable,
+"cscope-database-regexps", and set it appropriately, such that
+the above-created cscope database will be referenced when you
+edit a related source file.
+
+.P
+Once this has been done, you can then use the menu picks
+described under "Basic usage", above, to search for symbols.
+
+.SS * Interesting configuration variables:
+
+.P
+.B "cscope-truncate-lines"
+.P
+This is the value of `truncate-lines' to use in cscope
+buffers; the default is the current setting of
+`truncate-lines'.  This variable exists because it can be
+easier to read cscope buffers with truncated lines, while
+other buffers do not have truncated lines.
+
+.P
+.B "cscope-use-relative-paths"
+.P
+If non-nil, use relative paths when creating the list of files
+to index.  The path is relative to the directory in which the
+cscope database will be created.  If nil, absolute paths will
+be used.  Absolute paths are good if you plan on moving the
+database to some other directory (if you do so, you'll
+probably also have to modify `cscope-database-regexps').
+Absolute paths may also be good if you share the database file
+with other users (you'll probably want to specify some
+automounted network path for this).
+
+.P
+.B "cscope-index-recursively"
+.P
+If non-nil, index files in the current directory and all
+subdirectories.  If nil, only files in the current directory
+are indexed.  This variable is only used when creating the
+list of files to index, or when creating the list of files and
+the corresponding cscope database.
+
+.P
+.B "cscope-name-line-width"
+.P
+The width of the combined "function name:line number" field in
+the cscope results buffer.  If negative, the field is
+left-justified.
+
+.P
+.B "cscope-do-not-update-database"
+.P
+If non-nil, never check and/or update the cscope database when
+searching.  Beware of setting this to non-nil, as this will
+disable automatic database creation, updating, and
+maintenance.
+
+.P
+.B "cscope-display-cscope-buffer" 
+.P
+If non-nil, display the *cscope* buffer after each search
+(default).  This variable can be set in order to reduce the
+number of keystrokes required to navigate through the matches.
+
+.P
+.B "cscope-database-regexps"
+.P
+List to force directory-to-cscope-database mappings.
+This is a list of `(REGEXP DBLIST [ DBLIST ... ])', where:
+
+.P
+.B "REGEXP" 
+is a regular expression matched against the current buffer's
+current directory.  The current buffer is typically some source file,
+and you're probably searching for some symbol in or related to this
+file.  Basically, this regexp is used to relate the current directory
+to a cscope database.  You need to start REGEXP with "^" if you want
+to match from the beginning of the current directory.
+
+.P
+.B "DBLIST" 
+is a list that contains one or more of:
+
+.nf
+	( DBDIR )
+	( DBDIR ( OPTIONS ) )
+	( t )
+	t
+.fi
+
+.P
+Here, 
+.B DBDIR 
+is a directory (or a file) that contains a cscope
+database.  If DBDIR is a directory, then it is expected that the
+cscope database, if present, has the filename given by the variable,
+`cscope-database-file'; if DBDIR is a file, then DBDIR is the path
+name to a cscope database file (which does not have to be the same as
+that given by `cscope-database-file').  If only DBDIR is specified,
+then that cscope database will be searched without any additional
+cscope command-line options.  If OPTIONS is given, then OPTIONS is a
+list of strings, where each string is a separate cscope command-line
+option.
+
+.P
+ In the case of "( t )", this specifies that the search is to use the
+ normal hierarchical database search.  This option is used to
+ explicitly search using the hierarchical database search either before
+ or after other cscope database directories.
+
+.P
+ If "t" is specified (not inside a list), this tells the searching
+ mechanism to stop searching if a match has been found (at the point
+ where "t" is encountered).  This is useful for those projects that
+ consist of many subprojects.  You can specify the most-used
+ subprojects first, followed by a "t", and then followed by a master
+ cscope database directory that covers all subprojects.  This will
+ cause the most-used subprojects to be searched first (hopefully
+ quickly), and the search will then stop if a match was found.  If not,
+ the search will continue using the master cscope database directory.
+
+.P
+ Here, `cscope-database-regexps' is generally not used, as the normal
+ hierarchical database search is sufficient for placing and/or locating
+ the cscope databases.  However, there may be cases where it makes
+ sense to place the cscope databases away from where the source files
+ are kept; in this case, this variable is used to determine the
+ mapping.
+
+.P
+ This module searches for the cscope databases by first using this
+ variable; if a database location cannot be found using this variable,
+ then the current directory is searched, then the parent, then the
+ parent's parent, until a cscope database directory is found, or the
+ root directory is reached.  If the root directory is reached, the
+ current directory will be used.
+
+.P
+A cscope database directory is one in which EITHER a cscope database
+file (e.g., "cscope.out") OR a cscope file list (e.g.,
+"cscope.files") exists.  If only "cscope.files" exists, the
+corresponding "cscope.out" will be automatically created by cscope
+when a search is done.  By default, the cscope database file is called
+"cscope.out", but this can be changed (on a global basis) via the
+variable, `cscope-database-file'.  There is limited support for cscope
+databases that are named differently than that given by
+`cscope-database-file', using the variable, `cscope-database-regexps'.
+
+.P
+Here is an example of `cscope-database-regexps':
+
+.nf
+	(setq cscope-database-regexps
+	      '(
+		( "^/users/jdoe/sources/proj1"
+		  ( t )
+		  ( "/users/jdoe/sources/proj2")
+		  ( "/users/jdoe/sources/proj3/mycscope.out")
+		  ( "/users/jdoe/sources/proj4")
+		  t
+		  ( "/some/master/directory" ("-d" "-I/usr/local/include") )
+		  )
+		( "^/users/jdoe/sources/gnome/"
+		  ( "/master/gnome/database" ("-d") )
+		  )
+		))
+.fi
+
+.P
+If the current buffer's directory matches the regexp,
+"^/users/jdoe/sources/proj1", then the following search will be
+done:
+
+.TP
+1. First, the normal hierarchical database search will be used to
+locate a cscope database.
+
+.TP
+2. Next, searches will be done using the cscope database
+directories, "/users/jdoe/sources/proj2",
+"/users/jdoe/sources/proj3/mycscope.out", and
+"/users/jdoe/sources/proj4".  Note that, instead of the file,
+"cscope.out", the file, "mycscope.out", will be used in the
+directory "/users/jdoe/sources/proj3".
+
+.TP
+3. If a match was found, searching will stop.
+
+.TP
+4. If a match was not found, searching will be done using
+"/some/master/directory", and the command-line options "-d"
+and "-I/usr/local/include" will be passed to cscope.
+
+.TP
+If the current buffer's directory matches the regexp,
+"^/users/jdoe/sources/gnome", then the following search will be
+done:
+
+.TP
+The search will be done only using the directory,
+"/master/gnome/database".  The "-d" option will be passed to
+cscope.
+
+.TP
+If the current buffer's directory does not match any of the above
+regexps, then only the normal hierarchical database search will be
+done.
+
+.P
+.SS * Other notes:
+
+.P
+1. The script, "cscope-indexer", uses a sed command to determine
+what is and is not a C/C++/lex/yacc source file.  It's idea of a
+source file may not correspond to yours.
+
+.P
+2. This module is called, "xcscope", because someone else has
+already written a "cscope.el" (although it's quite old).
+
+.SH KNOWN BUGS:
+
+.P
+1. Cannot handle whitespace in directory or file names.
+
+.P
+2. By default, colored faces are used to display results.  If you happen
+to use a black background, part of the results may be invisible
+(because the foreground color may be black, too).  There are at least
+two solutions for this:
+
+.TP
+.BI    "2a. Turn off colored faces, by setting `cscope-use-face' to `nil', eg:"
+.TP
+.BI            "(setq cscope-use-face nil)"
+
+.TP
+.BI   " 2b. Explicitly set colors for the faces used by cscope.  The faces are"
+
+.nf
+	cscope-file-face
+	cscope-function-face
+	cscope-line-number-face
+	cscope-line-face
+	cscope-mouse-face
+.fi
+
+.TP
+The face most likely to cause problems (e.g., black-on-black
+color) is `cscope-line-face'.
+
+.P
+3. The support for cscope databases different from that specified by
+`cscope-database-file' is quirky.  If the file does not exist, it
+will not be auto-created (unlike files names by
+`cscope-database-file').  You can manually force the file to be
+created by using touch(1) to create a zero-length file; the
+database will be created the next time a search is done.
--- cscope-15.6/doc/Makefile.in.orig	2006-09-30 11:14:57.000000000 -0400
+++ cscope-15.6/doc/Makefile.in	2007-05-25 09:46:04.000000000 -0400
@@ -148,7 +148,7 @@
 sharedstatedir = @sharedstatedir@
 sysconfdir = @sysconfdir@
 target_alias = @target_alias@
-man_MANS = cscope.1
+man_MANS = cscope.1 xcscope.1
 EXTRA_DIST = $(man_MANS)
 all: all-am
 


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/cscope/devel/.cvsignore,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- .cvsignore	28 Sep 2004 19:46:27 -0000	1.3
+++ .cvsignore	14 Mar 2008 13:06:42 -0000	1.4
@@ -1,2 +1,3 @@
 cscope-15.5.tar.gz
 cscope-15.5-inverted.patch
+cscope-15.6.tar.gz


Index: cscope.spec
===================================================================
RCS file: /cvs/extras/rpms/cscope/devel/cscope.spec,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- cscope.spec	10 Mar 2008 18:36:31 -0000	1.34
+++ cscope.spec	14 Mar 2008 13:06:42 -0000	1.35
@@ -1,8 +1,8 @@
 Summary: C source code tree search and browse tool 
 Name: cscope
-Version: 15.5
-Release: 18%{?dist}
-Source0: http://unc.dl.sourceforge.net/sourceforge/cscope/cscope-15.5.tar.gz 
+Version: 15.6
+Release: 1%{?dist}
+Source0: http://unc.dl.sourceforge.net/sourceforge/cscope/cscope-15.6.tar.gz 
 URL: http://cscope.sourceforge.net
 License: BSD 
 Group: Development/Tools 
@@ -13,18 +13,10 @@
 %define xemacs_lisp_path %{_datadir}/xemacs/site-packages/lisp
 %define emacs_lisp_path %{_datadir}/emacs/site-lisp
 
-Patch0:cscope-15.5-ocs.patch
-Patch1:cscope-15.5-findassign.patch
-Patch2:cscope-15.5-ocs-dash_s_fix.patch
-Patch3:cscope-15.5-xcscope-man.patch
-Patch4:cscope-15.5-inverted.patch
-Patch5:cscope-15.5-resize.patch
-Patch6:cscope-15.5-tempsec.patch
-Patch7:cscope-15.5-inv-overflow.patch
-Patch8:cscope-15.5-ocs-sysdir.patch
-Patch9:cscope-15.5-putstring-overflow.patch
-Patch10: cscope-15.5-fscanf-overflows.patch
-Patch11: cscope-15.5-samelist.patch
+Patch0:cscope-15.6-findassign.patch
+Patch1:cscope-15.6-ocs.patch
+Patch2:cscope-15.6-xcscope-man.patch
+Patch3:cscope-15.6-sigwinch-linemode.patch
 
 %description
 cscope is a mature, ncurses based, C source code tree browsing tool.  It 
@@ -39,14 +31,6 @@
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
-%patch4 -p1
-%patch5 -p1
-%patch6 -p1
-%patch7 -p1
-%patch8 -p1
-%patch9 -p1 
-%patch10 -p1
-%patch11 -p1
 
 %build
 %configure
@@ -95,14 +79,8 @@
 rm -f %{emacs_lisp_path}/xcscope.el
 
 %changelog
-* Mon Mar 10 2008 Neil Horman <nhorman at redhat.com> -15.5-18
-- Fix samelist to properly absorb newlines (bz 436648)
-
-* Tue Feb 19 2008 Fedora Release Engineering <rel-eng at fedoraproject.org> - 15.5-17
-- Autorebuild for GCC 4.3
-
-* Fri Jan 18 2008 Neil Horman <nhorman at redhat.com> -15.5-16.dist
-- Fix revision sillyness & bump rev for rebuild
+* Fri Mar 25 2007 Neil Horman <nhorman at redhat.com> -15.6-1.dist
+- Rebase to version 15.6
 
 * Mon Mar 05 2007 Neil Horman <nhorman at redhat.com> -15.5-15.4.dist
 - Make sigwinch handler only register for curses mode (bz 230862)


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/cscope/devel/sources,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- sources	28 Sep 2004 19:50:21 -0000	1.4
+++ sources	14 Mar 2008 13:06:42 -0000	1.5
@@ -1 +1 @@
-beb6032a301bb11524aec74bfb5e4840  cscope-15.5.tar.gz
+db87833f90d8267b1fc0c419cfc4d219  cscope-15.6.tar.gz


--- cscope-15.5-findassign.patch DELETED ---


--- cscope-15.5-fscanf-overflows.patch DELETED ---


--- cscope-15.5-inv-overflow.patch DELETED ---


--- cscope-15.5-inverted.patch DELETED ---


--- cscope-15.5-ocs-dash_s_fix.patch DELETED ---


--- cscope-15.5-ocs-sysdir.patch DELETED ---


--- cscope-15.5-ocs.patch DELETED ---


--- cscope-15.5-putstring-overflow.patch DELETED ---


--- cscope-15.5-resize.patch DELETED ---


--- cscope-15.5-samelist.patch DELETED ---


--- cscope-15.5-tempsec.patch DELETED ---


--- cscope-15.5-xcscope-man.patch DELETED ---




More information about the fedora-extras-commits mailing list