6/30/2004:
	Changed License to Lucent Public License.  Bumped version to 8.15.
6/24/2004:
	Fixed a memory usage bug that was causing core dumps when
	many patterns are being checked.  Bumped version to 8.14.
7/01/2003:
	Converted to use autconf.  No functional changes.
7/18/2002:
	Released open source.  No other changes made
5/24/2002:
	ported 8.13 to new types darwin, zlinux and cygwin
4/6/2000
       cgrep in exptools has been upgraded to version 8.13.

       The information below for versions 8.05 and 8.00 describe the
       changes (other than bug fixes).  All changes in other versions
       were bug fixes only.

       06/02/98: cgrep Version 8.05
       Viewpathing is now supported.  See the manual page for details.

       12/30/96: cgrep Version 8.00
       Improvements to cgrep have been made.  See the new
       manual page for details.  

       The improvements and changes include the following:

         1.  Unlike the previous version, Version 8.00 works well
             under MS-DOS and will (hopefully) be supported for
             MS-DOS.

         2.  Major performance improvements have been made in some
             specific cases where the previous version of cgrep was
             not optimal.  For example, cgrep is now faster than
             grep even when the pattern matches nearly every line
             of the file.

         3.  Multiline matching (a match that spans more than one
             line of input text) is now permitted everywhere,
             including in delimiters (used with +-w) and trail
             patterns (used with -t, +t, or -T).

         4.  The buffer size option (-B bufsize) is now used only
             if cgrep is reading from a pipe or a special device
             file.  The option is otherwise ignored.  There is no
             longer any maximum value for bufsize.  The buffer size
             is specified in units of kilobytes, rather than
             depending on the BUFSIZ #define.

         5.  The -t and +t options are no longer distinct.  They
             have been collapsed into a single option.  Matches are
             non-recursive (as was the case for +t), but the size
             of the following window is determined as was the case
             for -t.  This also affects the -T option, which uses
             +t.  Also, for -t, +t, and -T, the 32 latest fixed
             strings are saved, rather than 16.

         6.  The -X and +X options have been replaced by the
             equivalent -I2 and +I2 options, respectively.  This
             was done for naming consistency of options.  The -X
             and +X options will still be supported for backward
             compatibility, but MAY be removed in a future release.

       OLD NEWS:

       8/17/92: cgrep Version 7.00 Improvements to cgrep have been
       made.  See the new manual page for details.  The
       improvements and changes include the following:

         1.  A new algorithm is used to match patterns consisting
             of two to 32 fixed strings, which results in a typical
             speedup over Version 6.00 ranging from a factor of 3
             for two strings to a factor of 1.8 for 32 strings.
             The new algorithm can match two strings almost as fast
             as a single string.  cgrep is now typically 15 times
             faster than egrep and 25 times faster than fgrep in
             matching two fixed strings.

         2.  The matching of multiple regular expressions has been
             speeded up in many cases, by as much as a factor of
             six in some cases.

         3.  The implementation of the -T option (5ESS ROP event
             trace) has been speeded up by a factor of four, as
             have the -t and +t options.

         4.  The new -A option allows for approximate matching of
             fixed strings or regular expressions, with the number
             of errors allowed specified on the command line.  This
             is very useful for finding misspelled words and other
             applications where exact matching is not desirable.  A
             portion of the string or expression can optionally be
             forced to match exactly.

         5.  The new -C, +C, and -+C options, when used with -A
             (above), allow for independent treatment of deletion,
             insertion, and substitution errors.

         6.  The new -l2 option outputs the file names of those
             files that do NOT have a match.

         7.  The new -h1 option forces the file name to be printed
             on each line of output even if only one file is
             specified.

         8.  The new -x1 option allows matches to be made to
             complete words or phrases in fixed strings or regular
             expressions.

         9.  The new -c1 option is equivalent to -c (count option),
             but suppresses the printout for files with no matches.

        10.  The 5ESS ROP feature for selecting specific SMs has
             been cleaned up to produce less output that is not
             related to the selected SMs.

       4/05/91: cgrep Version 6.00 Improvements to cgrep have been
       made.  See the new manual page for details.  The
       improvements and changes include the following:

         1.  The new -H and -H1 options highlight matched lines
             within context windows.

         2.  Matches can now be made to complete words or phrases
             using \< and \> in regular expressions in grep mode.

         3.  The -S option flag has been replaced by the the -h
             option flag for compatibility with versions of grep,
             egrep, and fgrep that support -h.

         4.  The new -l1 option suppresses output.

         5.  The -l option can now be used legally when reading
             from standard input.

         6.  The new -b1 option outputs the byte offset of matched
             lines.

         7.  The new -s1 option prevents missing or inaccessible
             files from affecting the exit status of cgrep.

         8.  The new -I1 and +I1 options allow more flexible
             specification of context windows.

         9.  The -T options will now follow ROP trail patterns in
             Spanish as well as English.

       1/27/90: cgrep Version 5.00 Improvements to cgrep have been
       made.  See the new manual page for details.  The
       improvements include the following:

         1.  Performance has been improved.  Cgrep 5.0 is much
             faster than grep, egrep, and fgrep in almost all
             situations.  You can use cgrep in place of grep,
             egrep, and fgrep by using the following exported Korn
             shell aliases:

                     alias -x grep="~exptools/bin/cgrep -G"
                     alias -x egrep="~exptools/bin/cgrep -E"
                     alias -x fgrep="~exptools/bin/cgrep -F"

             Typically, on a MAXI, cgrep 5.0 is around ten times as
             fast as grep for matching a fixed strings and up to
             thirty times as fast for some regular expressions.

         2.  Cgrep 5.0 can match patterns that span multiple lines.
             Matched patterns need no longer be confined to a
             single line.

         3.  Cgrep 5.0 has full egrep compatibility.  Parentheses
             for grouping are now recognized.

         4.  The new -a (ASCII) option of cgrep 5.0 makes it more
             convenient to match non-printing or special ASCII
             characters.

         5.  The new -B (buffer size) option allows the user to
             specify a smaller than standard input buffer size,
             which is useful when running with concurrently
             generated input, such as:

             tail -f file | cgrep -B 1 pattern

         6.  The -R option (5ESS ROP) has been changed slightly to
             take into account that ^Y is the first character of a
             5ESS domestic ROP record, not the last.

         7.  The version of cgrep 5.0 installed on the 5ESS PSS
             machines is "viewpathed" so it can be used in place of
             grep inside all 5ESS tools.

       2/27/89: cgrep Version 4.00 Many improvements to cgrep have
       been made.  See the new manual page for details.  The
       improvements include the following:

         1.  PERFORMANCE:  Cgrep 4.0 matches a single fixed string
             or regular expression much faster than grep.
             Typically, cgrep is around eight times as fast as grep
             for matching a fixed strings and up to twenty times as
             fast for some regular expressions.

         2.  A context window need not terminate at the nearest
             delimiter.  If a delimiter and a matching line count
             are both used (e.g. "cgrep -3 -w delimiter pattern
             file" or "cgrep +3 +w delimiter pattern file") the
             window will be delimited by the Nth occurrence of the
             delimiter. (3rd in the example).  This can also be
             used with the ROP options -R or -T, which imply
             delimiters.  For example, "cgrep -R -31 +11 pattern
             file" will print the preceding 30 and the following 10
             ROP reports as well as the matching report.  WARNING:
             THIS IS DIFFERENT THAN THE PREVIOUS INTERPRETATION OF
             A LINE COUNT AND A DELIMITER USED TOGETHER.

         3.  New special ROP expressions allow simple printing of
             SM associated ROP reports by SM number.
         4.  The -i option (ignore upper/lower case distinction)
             can now be used independently for delimiters and trail
             patterns, as well as for matching patterns.

         5.  The -x option (match entire line) no longer forces the
             expression to be treated as a fixed string as in
             fgrep, but is now usable in grep and egrep modes as
             well.  The -x option now is turned off by +x, rather
             than by a mode option, such as -E, -F, or -G.

         6.  Windows are no longer limited to 512 lines preceding
             the matched line.

         7.  Lines are no longer limited to BUFSIZ characters.

         8.  A file containing patterns (-f patterns_file) is no
             longer limited to BUFSIZ characters.

         9.  Cgrep now properly handles text lines with embedded
             nulls.

        10.  The -o (overlap) option will work correctly and
             consistently for more than two overlapping windows and
             for all degrees of overlap.

        11.  The -m option is no longer necessary, as subsequent
             matches within a window are now never ignored.  The
             subsequent match generates a new window, which is
             either cleanly merged with the previous window
             (without -o option) or cleanly printed separately in
             its entirety (with -o option).  The -m option will
             still be accepted for backward compatibility but will
             have no effect.  The -m option will be removed from
             the next release.

        12.  The -M option will consistently treats multiple files
             as a single concatenated file in all respects, rather
             than just in some respects.

        13.  Unless the -o (overlap) option is specified,
             overlapping or contiguous windows will be merged.
             Thus, the output delimiter, if present, will be
             printed between two output lines if and only if they
             are nonadjacent in the input.

        14.  The -c and -C options, which in fact were redundant,
             have been merged into -c without loss of
             functionality.  For backward compatibility, -C will be
             accepted as identical to -c, but will be removed from
             the next release.

        15.  Most options that do not take arguments, such as
             -bcilnosvxDMSV, will now be able to be overridden by a
             subsequent corresponding +bcilnosvxDMSV option.  This
             will allow users to use any of these options as the
             default in a script or in a Korn shell command alias
             and still be able to override it.  For example, the
             user could define "cgrep -n" as an alias for cgrep if
             he/she usually wishes to print line numbers, and type
             "cgrep +n" in those instances when line numbers are
             not wanted.  Note that the mode options -EFG are
             overridden by any other mode option, just as in the
             previous release.

        16.  The -v option did not work properly if more than one
             pattern was specified.  This bug has been fixed.

       06/07/88: cgrep Version 3.00 New options (-N, +N) have been
       added to cgrep to allow matching only selected instances of
       an expression, for example, the first N occurrences of an
       expression.  See the manual page for details.

       12/20/87: cgrep Version 2.00 A completely new release of
       cgrep (context grep) has been written based on grep, whereas
       the previous release was based on fgrep.  The new cgrep is
       upward compatible with the previous release, with a few
       minor exceptions stated below.  The new cgrep is
       considerably faster than the previous release, and provides
       all of the functionality of the previous release, plus many
       new features.  New features include the following:

         1.  Upward compatibility with grep, egrep, or fgrep
             (selectable).

         2.  Matching can be done on any number of full or limited
             regular expressions or fixed strings.

         3.  Window frame delimiters need not match entire line,
             and any number of full or limited regular expressions
             or fixed strings may be used.

         4.  Window frame delimiters may be used together with
             window line counts.

         5.  Optionally, windows may span input file boundaries.

         6.  Optionally, only lines outside the windows will be
             printed.

         7.  By default, overlapping windows do not cause lines to
             be printed more than once.

         8.  Lines containing window frame delimiters may either be
             included in or excluded from windows.

         9.  Optionally on output, file names and/or the output
             delimiter may be suppressed.

        10.  Matching can be done on fixed strings selected
             dynamically from the input files.

        11.  For convenience, 5ESS(Tm) (International or Domestic)
             ROP report delimiters and event trails are recognized
             by specifying a single option flag.

       Usage of the new release of cgrep is upward compatible with
       the old release with the following exceptions (See manual
       page for more details):

         1.  If any of the strings to be matched contain special
             characters, the new -F option must be used to specify
             fixed strings instead of regular expressions.

         2.  If the window frame delimiter must match the entire
             line, the -x option must be used before the delimiter
             to indicate this, and that the delimiter is to be
             interpreted as a fixed string.

         3.  The superfluous -u option (show usage) has been
             removed.  To show usage, merely type cgrep without
             arguments or options.

       When no new features are used, output from the new release
       of cgrep should be identical with that of the old cgrep with
       the following exceptions (See manual page for more details):

         1.  Overlapping windows do not cause multiple printing of
             lines, unless the -o option is used.

         2.  By default, if window frame delimiters (-w or +w
             options) are used, the lines containing the delimiters
             are considered as part of the windows.  Also, the
             entire matching line is itself also searched for the
             frame delimiters.  This behavior can be overridden by
             the -X and +X options.

         3.  A bug in the -c (count) option, which the old cgrep
             inherited from fgrep, has been eliminated.  Multiple
             matches in the same line will only be counted once, as
             they should be.

         4.  The error messages are completely different, having
             been derived from those of grep.

         5.  Considerably less processor time will have been
             expended.

