Message-Id: <201403212143.s2LLhWbi002081@delorie.com> Date: Fri, 21 Mar 2014 22:45:15 +0100 From: Juan Manuel Guerrero To: djgpp-announce AT delorie DOT com Subject: ANNOUNCE: DJGPP port of GNU grep 2.18 uploaded. Content-Type: text/plain; charset=ISO-8859-15; format=flowed Reply-To: djgpp AT delorie DOT com This is a port of GNU grep 2.18 to MSDOS/DJGPP. This is GNU grep, the "fastest grep in the west". GNU grep is based on a fast lazy-state deterministic matcher (about twice as fast as stock Unix egrep) hybridized with a Boyer-Moore-Gosper search for a fixed string that eliminates impossible text from being considered by the full regexp matcher without necessarily having to look at every character. The result is typically many times faster than Unix grep or egrep. (Regular expressions containing backreferencing will run more slowly, however.) DJGPP specific changes. ======================= DJGPP specific changes are those required to implement colorization support for this port. If grep is called with the command line option --color and the output is directed to the screen then the default colors will be used to mark matches, file names and line numbers. If the output does not go to the screen then colorization is automatically suppressed. Read the docs to learn how to control the color using the environment variable GREP_COLORS. As usual all changes are documented in the diffs file that is stored in the /djgpp directory. Please note that to run the test suite produced with autoconf 2.64 and later you must install mktmp17br2 or later. Because the test suite also tries to test multibyte patterns but multibyte strings are not fully supported by DJGPP some tests will be skipped or fail. The yesno test is known to fail, so please do not report it. Before starting the test suite, please make sure to unset the GREP_OPTIONS in djgpp.env or the test suite may not work as expected. The grep program uses a new method called fts to traverse a file tree. This code is very posix centric, especially it uses gnulib functions like openat, openat-proc and fdopendir that try to access directories using file descriptors with open(). This is only supported by djdev204 but not by djdev203. This means that if grep is compiled using djdev203, the program will no longer be able neither to recurse directories nor will be able to follow symlinks. This is because djdev203 only produces symlinks for programs. In both cases grep will always terminated with ENOSYS. grep211 was probably the last DJGPP port of grep compiled with djdev203. Please also note that there is a function name clash between gnulib's and grep's gettext wrapper and djgpp's old BORLAND compatibility gettext function declared in conio.h. This issue has been solved in djdev204. To solve the problem for djdev203, I provide the patch /djgpp/conio.patch that will change djdev203's conio.h accordingly to djdev204 conio.h. After this change the name clash will be solved in the same way as it has been solved for djdev204. The patch only concerns this name clash. This port has been configured with perl-regexp (pcre) support enabled. This means that you will have to install pcre libray available as: ftp://ftp.delorie.com/pub/djgpp/current/v2tk/pcre834b.zip or ftp://ftp.delorie.com/pub/djgpp/beta/v2tk/pcre834b.zip if you decide to compile the the preconfigured sources. If you prefer to disable the pcre support you will have to reconfigure and recompile the suorces again, but this time passing the "no-pcre" command line option to config.bat. The grep218b.zip file contains only the one build with perl-regexp support enabled. This port has no wide character/multi byte support at all. To build this port and run the test suite you will need LFN support. The source package is configured to be build in the "_build.204" directory. The port has been configured and compiled with NLS support enabled using the latest ports of libiconv, libunistring and gettext. ftp://ftp.delorie.com/pub/djgpp/beta/v2gnu/licv114b.zip ftp://ftp.delorie.com/pub/djgpp/beta/v2gnu/luns093b.zip ftp://ftp.delorie.com/pub/djgpp/beta/v2gnu/gtx1832b.zip For further information about GNU grep please read the info docs and NEWS file. This is an verbatim extract of the NEWS file: ------------------------------------------------------------------------------- * Noteworthy changes in release 2.18 (2014-02-20) [stable] ** Bug fixes grep no longer mishandles patterns like [^^-~] in unibyte locales. [bug introduced in grep-2.8] grep -i in a multibyte, non-UTF8 locale could be up to 200 times slower than in 2.16. [bug introduced in grep-2.17] * Noteworthy changes in release 2.17 (2014-02-17) [stable] ** Improvements grep -i in a multibyte locale is now typically 10 times faster for patterns that do not contain \ or [. grep (without -i) in a multibyte locale is now up to 7 times faster when processing many matched lines. ** Maintenance grep's --mmap option was disabled in March of 2010, and began to elicit a warning in January of 2012. Now it is completely gone. * Noteworthy changes in release 2.16 (2014-01-01) [stable] ** Bug fixes Fix gnulib-provided maint.mk so that the release procedure described in README-release actually does what we want. Before that fix, that procedure resulted in a grep-2.15 tarball that would lead to a grep binary whose --version-reported version number was 2.14.51... The fix to make \s and \S work with multi-byte white space broke the use of each shortcut whenever followed by a repetition operator. For example, \s*, \s+, \s? and \s{3} would all malfunction in a multi-byte locale. [bug introduced in grep-2.15] The fix to make grep -P work better with UTF-8 made it possible for grep to evoke a larger set of PCRE errors, some of which could trigger an abort. E.g., this would abort: printf '\x82'|LC_ALL=en_US.UTF-8 grep -P y Now grep handles arbitrary PCRE errors. [bug introduced in grep-2.15] Handle very long lines (2GiB and longer) on systems with a deficient read system call. ------------------------------------------------------------------------------- The port has been compiled using stock djdev204 from the /beta directory and consists of three packages that can be downloaded from ftp.delorie.com and mirrors as (timestamp 2014-03-20): grep 2.18 binaries, info and man format documentation: ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/grep218b.zip grep 2.18 dvi, html, pdf and ps format documentation: ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/grep218d.zip grep 2.18 source: ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/grep218s.zip Send grep specific bug reports to . Send suggestions and bug reports concerning the DJGPP port to comp.os.msdos.djgpp or . If you are not sure if the failure is really a grep failure or a djgpp specific failure, report it here and *not* to . Enjoy. Guerrero, Juan Manuel