Imported Upstream version 2.19 upstream upstream/2.19
authorJean-Benoit MARTIN <jean-benoit.martin@open.eurogiciel.org>
Fri, 7 Nov 2014 13:46:23 +0000 (14:46 +0100)
committerNicolas Zingilé <nicolas.zingile@open.eurogiciel.org>
Thu, 15 Jan 2015 09:41:19 +0000 (10:41 +0100)
188 files changed:
.tarball-version
ChangeLog
Makefile.am
Makefile.in
NEWS
aclocal.m4
build-aux/compile
build-aux/config.guess
build-aux/config.sub
build-aux/gendocs.sh
build-aux/install-sh
build-aux/missing
build-aux/test-driver
build-aux/texinfo.tex
cfg.mk
configure
configure.ac
doc/Makefile.in
doc/grep.in.1
doc/grep.info
doc/grep.texi
doc/stamp-vti
doc/version.texi
gnulib-tests/Makefile.in
gnulib-tests/gnulib.mk
gnulib-tests/init.sh
gnulib-tests/test-fdopen.c
gnulib-tests/test-memchr2.c [new file with mode: 0644]
lib/Makefile.in
lib/exclude.c
lib/exclude.h
lib/fts.c
lib/gnulib.mk
lib/memchr2.c [new file with mode: 0644]
lib/memchr2.h [new file with mode: 0644]
lib/memchr2.valgrind [new file with mode: 0644]
lib/obstack.c
lib/obstack.h
lib/regcomp.c
lib/regex_internal.c
lib/regex_internal.h
lib/regexec.c
lib/stdint.in.h
lib/strtoimax.c
lib/sys_types.in.h
lib/time.in.h
lib/unistd.in.h
lib/xalloc.h
m4/00gnulib.m4
m4/gnulib-common.m4
m4/gnulib-comp.m4
m4/manywarnings.m4
maint.mk
po/POTFILES.in
po/af.gmo
po/af.po
po/be.gmo
po/be.po
po/bg.gmo
po/bg.po
po/ca.gmo
po/ca.po
po/cs.gmo
po/cs.po
po/da.gmo
po/da.po
po/de.gmo
po/de.po
po/el.gmo
po/el.po
po/eo.gmo
po/eo.po
po/es.gmo
po/es.po
po/et.gmo
po/et.po
po/eu.gmo
po/eu.po
po/fi.gmo
po/fi.po
po/fr.gmo
po/fr.po
po/ga.gmo
po/ga.po
po/gl.gmo
po/gl.po
po/grep.pot
po/he.gmo
po/he.po
po/hr.gmo
po/hr.po
po/hu.gmo
po/hu.po
po/id.gmo
po/id.po
po/it.gmo
po/it.po
po/ja.gmo
po/ja.po
po/ko.gmo
po/ko.po
po/ky.gmo
po/ky.po
po/lt.gmo
po/lt.po
po/nb.gmo
po/nb.po
po/nl.gmo
po/nl.po
po/pa.gmo
po/pa.po
po/pl.gmo
po/pl.po
po/pt.gmo
po/pt.po
po/pt_BR.gmo
po/pt_BR.po
po/ro.gmo
po/ro.po
po/ru.gmo
po/ru.po
po/sk.gmo
po/sk.po
po/sl.gmo
po/sl.po
po/sr.gmo
po/sr.po
po/sv.gmo
po/sv.po
po/th.gmo
po/th.po
po/tr.gmo
po/tr.po
po/uk.gmo
po/uk.po
po/vi.gmo
po/vi.po
po/zh_CN.gmo
po/zh_CN.po
po/zh_TW.gmo
po/zh_TW.po
src/Makefile.am
src/Makefile.in
src/dfa.c
src/dfa.h
src/dfasearch.c
src/dosbuf.c
src/egrep.c [deleted file]
src/egrep.sh [new file with mode: 0644]
src/fgrep.c [deleted file]
src/grep.c
src/grep.h
src/kwsearch.c
src/kwset.c
src/kwset.h
src/main.c [deleted file]
src/mbsupport.h [deleted file]
src/pcresearch.c
src/search.h
src/searchutils.c
src/system.h
tests/Makefile.am
tests/Makefile.in
tests/bre
tests/case-fold-titlecase [new file with mode: 0755]
tests/context-0 [new file with mode: 0755]
tests/count-newline [new file with mode: 0755]
tests/empty-line [new file with mode: 0755]
tests/ere
tests/euc-mb
tests/fgrep-infloop
tests/ignore-mmap [deleted file]
tests/init.cfg
tests/init.sh
tests/invalid-multibyte-infloop
tests/mb-non-UTF8-performance [new file with mode: 0755]
tests/null-byte [new file with mode: 0755]
tests/pcre
tests/pcre-infloop [new file with mode: 0755]
tests/pcre-invalid-utf8-input
tests/pcre-w [new file with mode: 0755]
tests/pcre-wx-backref [new file with mode: 0755]
tests/posix-bracket [new file with mode: 0755]
tests/prefix-of-multibyte
tests/spencer1-locale
tests/turkish-eyes [new file with mode: 0755]
tests/unibyte-negated-circumflex [new file with mode: 0755]
tests/word-delim-multibyte

index 6d28a11..15a3e92 100644 (file)
@@ -1 +1 @@
-2.16
+2.19
index b035ddc..961b48e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
+2014-05-22  Jim Meyering  <meyering@fb.com>
+
+       version 2.19
+       * NEWS: Record release date.
+
+2014-05-21  Jim Meyering  <meyering@fb.com>
+
+       maint: avoid new false-positive syntax-check failure
+       * cfg.mk (exclude_file_name_regexp--sc_prohibit_doubled_word):
+       Exempt new test file that contains legitimate use of "in in".
+
+2014-05-17  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       tests: add test case for newline-count fix
+       * tests/count-newline: New test.
+       * tests/Makefile.am (TESTS): Add it.
+
+2014-05-16  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: do not count newline before the start of buffer
+       * src/dfa.c (build_state): When checking whether the previous
+       character was a newline, do not count any newline before the
+       start of the buffer.
+
+2014-05-15  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: port mb_next_wc to RHEL 6.5 x86-64
+       * src/searchutils.c (mb_next_wc): Work around glibc bug 16950; see:
+       https://sourceware.org/bugzilla/show_bug.cgi?id=16950
+       This bug was masked in the other GNU/Linux tests I made.  It was
+       exposed on RHEL 6.5 x86-64, where the compiler (GCC Red Hat 4.4.7-4)
+       happened to use temporaries in a different way.
+       Also see recent changes to the Gnulib documentation in this area:
+       http://lists.gnu.org/archive/html/bug-gnulib/2014-05/msg00013.html
+
+       tests: port mb-non-UTF8-performance to RHEL 6.5
+       * tests/mb-non-UTF8-performance (timeout): Use an integer,
+       as 'timeout 1.234' doesn't work in EUC locales.
+
+2014-05-12  Paul Eggert  <eggert@cs.ucla.edu>
+
+       egrep, fgrep: port to Solaris 10 /bin/sh
+       This old shell doesn't grok ${0%/*}; see: http://bugs.gnu.org/17471
+       * src/Makefile.am (egrep fgrep): Don't assume the shell does substrings.
+       * src/egrep.sh (dir): New var, so that the substring calculation is
+       done only once (which is a small win even with newer shells),
+       and so that the calculation is easier to edit on older shells.
+
+2014-05-10  Jim Meyering  <meyering@fb.com>
+
+       maint: NEWS: adjust wording to reflect move
+       * NEWS (Improvements): Correct direction-relative wording,
+       now that the referent is below, not above.
+
+       maint: NEWS: move "Improvements" to the top
+       * NEWS: Move the small "Improvements" section to precede
+       the longer "Bug fixes" one.
+
+       gnulib: update submodule to latest, and bootstrap
+       * gnulib: Update submodule.
+       * bootstrap: Update from gnulib.
+
+2014-05-10  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: omit double includes
+       * src/dfa.c: Don't include stddef.h or stdbool.h, as dfa.h includes
+       them already, and it's the same module as we are.
+       Suggested by Aharon Robbins in: http://bugs.gnu.org/17458
+
+       dfa: fix bug with \< etc in multibyte locales
+       Problem reported by Stephane Chazelas in: http://bugs.gnu.org/16867
+       * NEWS: Document the fix.
+       * src/dfa.c (dfaoptimize): Remove any superset if changing from
+       UTF-8 to unibyte, and if the pattern has no backreferences.
+       (dfassbuild): In multibyte locales, treat \< \> \b \B as
+       backreferences in the DFA, since the DFA relies on unibyte
+       tests to check them.
+       (dfacomp): Optimize after building the superset, so that
+       dfassbuild can depend on d->multibyte.  A downside is that
+       dfaoptimize must remove supersets that are likely slower than the
+       DFA after optimization, but that's been done in the
+       above-described change.
+       * tests/Makefile.am (XFAIL_TESTS): Remove word-delim-multibyte,
+       since the test works now.
+
+       tests: add test case for -C 0 change
+       * tests/context-0: New test.
+       * tests/Makefile.am (TESTS): Add it.
+
+       grep: -A 0, -B 0, -C 0 now output a separator
+       Problem reported by Dan Jacobson in: http://bugs.gnu.org/17380
+       * NEWS:
+       * doc/grep.texi (Context Line Control): Document this.
+       * src/grep.c (prtext): Output a separator even if context is zero.
+       (main): Default context is now -1, not 0.
+
+2014-05-09  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: minor improvements to retry-DFA-superset patch
+       * src/dfasearch.c (EGexecute): Avoid unnecessary test in a context
+       where memrchr cannot return a null pointer.
+
+2014-05-09  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: retry DFA superset after matching multiple lines
+       * src/dfasearch.c (EGexecute): Without this patch, the code reverts
+       to KWset when the DFA superset matches multiple lines.
+       However, if the DFA superset matches multiple lines, it most likely
+       also matches a single line, and reverting to KWset means dfafast
+       won't work effectively.  Change the code so that it retries the DFA
+       superset immediately after it matches multipline lines.  On my platform
+       this improves the performance of "LC_ALL=C grep '\(ab\)cd\1d' k" from
+       3.48 to 2.14 seconds realtime, where k contains the output of
+       "yes abcdabc | head -50000000".
+
+       dfa: fix inconsistency in multibyte locales
+       * src/dfa.c (dfaexec): Use the same exit condition in multibyte
+       locales as in unibyte.
+
+2014-05-08  Jim Meyering  <meyering@fb.com>
+
+       maint: mark some breakless cases with /* fallthrough */ comment
+       * src/dfa.c (addtok_mb, dfaanalyze): Add comment so that it is
+       clear that the "break" statement is deliberately omitted.
+
+2014-05-08  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: assume C89 for CHAR_BIT
+       * src/dfa.c (CHARBITS): Remove.  All uses replaced by CHAR_BIT.
+       (NOTCHAR): Now an enum, since it need not be a macro.
+
+       dfa: don't assume unsigned int is exactly 32 bits wide
+       Sun C 5.12 (sparc) warns of the potential unportability.
+       * src/dfa.c (charclass_word): New type, for clarity.
+       All relevant uses of 'unsigned' changed.
+       (CHARCLASS_WORD_BITS): Rename from INTBITS.  All uses changed.
+       Now an enum, since it needn't be a macro.
+       (CHARCLASS_WORD_MASK): New macro.
+       (CHARCLASS_WORDS): Rename from CHARCLASS_INTS.  All uses changed.
+       (setbit, clrbit): Cast 1 to charclass_word, for clarity.
+       (notset, add_utf8_anychar, dfastats):
+       Don't assume unsigned int is exactly 32 bits wide.
+       (dfastate): Don't rely on implementation-defined conversion of
+       greater-than-INT_MAX unsigned to int.  Change bit test to resemble
+       tstbit more.
+
+       maint: fix indenting to pacify 'prohibit_tab_based_indentation'
+       * src/dfa.c: Use spaces and not tabs to indent some lines.
+
+       grep: simplify and clarify invert-related code
+       * src/grep.c (out_invert, prtext): Use bool for booleans.
+       (prline): Remove unnecessary '!!' on a value that is always 0 or 1.
+       (prtext): Remove last arg NLINESP; use !out_invert instead.  All uses
+       changed.  Move decls to nearer uses, since we can assume C99 here.
+       Update 'outleft' and 'after_last_match' here; it's simpler.
+       (grepbuf): Compute return value by subtracting new from old 'outleft',
+       rather than by keeping a separate running total.  Avoid code duplication
+       by arranging for prtext to be called from one place, not three.
+
+2014-05-08  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: improve performance of -v when combined with -L, -l or -q
+       Problem reported by Jörn Hees in: http://bugs.gnu.org/17427
+       * src/grep.c (grepbuf, grep): When -v is combined with -L, -l, or -q,
+       don't read data unnecessarily after a non-match is found.
+
+2014-05-06  Paul Eggert  <eggert@cs.ucla.edu>
+
+       doc: mention performance changes
+       * NEWS: Discuss recent performance improvements and downgrades.
+
+       dfa: clarify use of "if"
+       The phrase "Y is true if X" is logically equivalent to "X implies Y",
+       but often "X if and only if Y" was intended.
+       * src/dfa.c, src/dfa.h: Reword to avoid the incorrect use of "if".
+
+       dfa: minor performance improvement for previous change
+       * src/dfa.c (struct dfa): New member 'fast'.  Remove 'has_backref'.
+       All uses changed.
+
+2014-05-06  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       dfa: speed up 'dfaisfast'
+       * src/dfa.c (struct dfa): New member 'has_backref'.
+       (addtok_mb): Set it.
+       (dfaisfast): Use it.
+
+2014-05-05  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: fix -w match next to a multibyte letter
+       * NEWS: Document this.
+       * src/dfasearch.c, src/kwsearch.c (WCHAR): Remove.
+       (wordchar): New static function.
+       * src/dfasearch.c (EGexecute):
+       * src/kwsearch.c (Fexecute): Use the new functions, so that the
+       code works correctly if a multibyte character adjacent to the
+       match has two or more bytes.
+       * src/search.h, src/searchutils.c (mb_prev_wc, mb_next_wc):
+       New functions.
+       * tests/word-delim-multibyte: Add a test for grep -w (which now
+       passes), and a test for \> (which still fails).  The \< test also
+       still fails.
+
+       grep: improve internal API for multibyte boundary
+       * src/search.h, src/searchutils.c (mb_goback): Rename from
+       is_mb_middle.  Omit last arg.  Return number of bytes to go back,
+       not just a boolean.  All uses changed.
+       * src/dfasearch.c (EGexecute):
+       * src/kwsearch.c (Fexecute): Adjust to API change.
+       * src/kwsearch.c (Fexecute): Eliminate common subexpression.
+
+       grep: fix encoding-error incompatibilities among regex, DFA, KWset
+       This follows up to http://bugs.gnu.org/17376 and fixes a different
+       set of incompatibilities, namely between the regex matcher and the
+       other matchers, when the pattern contains encoding errors.
+       The GNU regex matcher is not consistent in this area: sometimes
+       an encoding error matches only itself, and sometimes it
+       matches part of a multibyte character.  There is no documentation
+       for grep's behavior in this area and users don't seem to care,
+       and it's simpler to defer to the regex matcher for problematic
+       cases like these.
+       * NEWS: Document this.
+       * src/dfa.c (ctok): Remove.  All uses removed.
+       (parse_bracket_exp, atom): Use BACKREF if a pattern contains
+       an encoding error, so that the matcher will revert to regex.
+       * src/dfasearch.c, src/grep.c, src/pcresearch.c, src/searchutils.c:
+       Don't include dfa.h, since search.h now does that for us.
+       * src/dfasearch.c (EGexecute):
+       * src/kwsearch.c (Fexecute): In a UTF-8 locale, there's no need to
+       worry about matching part of a multibyte character.
+       * src/grep.c (contains_encoding_error): New static function.
+       (main): Use it, so that grep -F is consistent with plain fgrep
+       when the pattern contains an encoding error.
+       * src/search.h: Include dfa.h, so that kwsearch.c can call using_utf8.
+       * src/searchutils.c (is_mb_middle): Remove UTF-8-specific code.
+       Callers now ensure that we are in a non-UTF-8 locale.
+       The code was clearly wrong, anyway.
+       * tests/fgrep-infloop, tests/invalid-multibyte-infloop:
+       * tests/prefix-of-multibyte:
+       Do not require that grep have a particular behavor for this test.
+       It's OK to match (exit status 0), not match (exit status 1), or
+       report an error (exit status 2), since the pattern contains an
+       encoding error and grep's behavior is not specified for such
+       patterns.  Test only that KWset, DFA, and regex agree.
+       * tests/prefix-of-multibyte: Add tests for ABCABC and __..._ABCABC___.
+
+2014-05-04  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: minor simplification
+       * src/dfa.c (parse_bracket_exp): Use enum, not macro, and move var
+       to just the scope it's needed.
+
+       grep: simplify and fix problems with KWset-DFA agreement patch
+       * src/dfa.c (dfambcache, parse_bracket_exp): Simplify.
+       (mbs_to_wchar, wctok, FETCH_WC, match_anychar, match_mb_charset)
+       (check_matching_with_multibyte_ops, transit_state_consume_1char)
+       (transit_state, dfaexec): Use wint_t, not wchar_t, so that
+       WEOF is treated correctly on platforms where WEOF is not a valid
+       wchar_t value.
+       (ctok, lex): Use int, not unsigned int, for characters,
+       so that EOF is treated more naturally.
+       (parse_bracket_exp): Use NOTCHAR to mark uninitialized char, since
+       FETCH_WC can now set the char to EOF.
+       (lex): Remove unnecessary test for EOF.
+       (parse_bracket_exp, atom): Swap then and else parts, to put
+       the small one first; this is more readable here.
+       * src/searchutils.c (is_mb_middle): Simplify.
+
+       tests: improve coverage for prefix-of-multibyte
+       * tests/prefix-of-multibyte: Also test the regex version.
+
+2014-05-04  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: make KWset and DFA agree about invalid sequences in patterns
+       See: http://bugs.gnu.org/17376
+       * src/dfa.c (dfambcache): Don't cache invalid sequences, because they can't be
+       represented by wide characters.
+       (dfambcache, mbs_to_wchar): Return WEOF for invalid sequences.
+       (ctok): New global variable.
+       (parse_bracket_exp, atom, match_anychar, match_mb_charset): Don't allow WEOF.
+       (lex): Set 'ctok'.
+       * src/kwsearch.c (Fexecute):
+       * src/searchutils.c (is_mb_middle): Don't check here.
+       * tests/invalid-multibyte-infloop: Adjust to fixed behavior.
+       * tests/prefix-of-multibyte: Add test cases for this bug.
+
+2014-05-03  Jim Meyering  <meyering@fb.com>
+
+       maint: make ChangeLog generation more robust
+       * Makefile.am (gen-ChangeLog): Sync changes from GNU coreutils,
+       to ensure exit status is propagated, and to support an optional
+       git-log-fix file.
+
+2014-05-03  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: clarify EGexecute slightly
+       * src/dfasearch.c (EGexecute): Change if-then-else to !if-else-then.
+
+2014-05-03  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: fix the bug in previous patch.
+       * src/dfasearch.c (EGexecute): Do it.
+
+2014-04-30  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: simplify EGexecute further
+       * src/dfa.c, src/dfa.h (dfasuperset): Arg is now const pointer.
+       Now pure.
+       * src/dfasearch.c (EGexecute): Coalesce some duplicate code.
+       Don't worry about memrchr returning NULL when that's impossible.
+
+2014-04-30  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: adjust timing back to kwset when dfaisfast is true
+       * src/dfasearch.c (EGexecute): If DFA fails after kwset succeeds,
+       the code doesn't return to kwset until it reaches the end of the buffer
+       or finds a match.  Because of this, although some cases speed up,
+       others slow down.
+
+       Adjust the heuristic for switching to the DFA, so that it
+       is more likely to switch at the right times.
+
+2014-04-30  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: simplify superset
+       * src/dfa.h (dfahint): Remove decl.
+       (dfasuperset): New decl.
+       * src/dfa.c (dfahint): Remove.
+       (dfassbuild): Rename from dfasuperset.
+       (dfasuperset): New function.  It returns the superset of D.
+       * src/dfasearch.c: Use dfasuperset instead of dfahint, and simplify.
+
+       dfa: optimize memory allocation
+       * src/dfa.c (epsclosure): get the value of 'visited' from the argument.
+       (dfaanalyze): Define and allocate variable 'visited'.
+       (dfastate): Use not 'insert' but 'merge' to insert positions for
+       state 0 of DFA.
+
+2014-04-29  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       kwset: improve performance by inlining tr
+       Without this change, older versions of GCC won't inline 'tr', and this
+       can hurt performance significantly.  See: http://bugs.gnu.org/17229#64
+       * src/kwset.c (tr): Make it inline.
+
+2014-04-27  Jim Meyering  <meyering@fb.com>
+
+       gnulib: update to latest
+       * gnulib: This fixes a bug whereby running bootstrap
+       would remove our build-aux/git-log-fix file.
+
+2014-04-27  Paul Eggert  <eggert@cs.ucla.edu>
+
+       kwset: improve performance by inlining more
+       Problem reported by Norihiro Tanaka in <http://bugs.gnu.org/17229#55>.
+       * src/kwset.c (bmexec_trans): Rename from bmexec, and make it inline.
+       (bmexec): New implementation, which calls bmexec_trans.  This helps
+       GCC inline more aggressively with the default optimization, and
+       improves performance 25% with the reported benchmark on my host.
+
+2014-04-26  Paul Eggert  <eggert@cs.ucla.edu>
+
+       kwset: speed up by using memchr2
+       Idea suggested by Eric Blake in: http://bugs.gnu.org/17229#43
+       * bootstrap.conf (gnulib_modules): Add memchr2.
+       * src/kwset.c: Include stdint.h, for uintptr_t.  Include memchr2.h.
+       (struct kwset): New members gc1, gc2, gc1help.
+       (tr): Move earlier, so it can be used earlier.
+       (kwsprep): Initialize struct kwset's new members.
+       (memchr_kwset): Rename from memchr_trans.  Combine C and TRANS args into
+       new arg KWSET.  All uses changed.  Use memchr2 when appropriate.
+       (bmexec): Use new members instead of recomputing their values.
+       Increase advance_heuristic; it's just a guess, but memchr2 probably
+       makes it reasonable to increase it.
+
+       kwset: improve performance when large Boyer-Moore key doesn't match
+       * src/kwset.c (bmexec): As a heuristic, prefer memchr to seeking
+       by delta1 only when the latter doesn't advance much.
+
+       dfa: fix index bug in previous patch, and simplify
+       * src/dfa.c, src/dfa.h (dfaisfast): Arg is const pointer.
+       * src/dfa.c (dfaisfast): Simplify, since supersets never contain BACKREF.
+       * src/dfa.h (dfaisfast): Declare to be pure.
+       * src/dfasearch.c (EGexecute): Fix typo that could cause buffer
+       read overrun when !dfafast.  Hoist duplicate computation out
+       of an if's then and else parts.
+
+2014-04-26  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: speed up for a case to repeat failure in DFA after success in kwset
+       A DFA is typically much faster if it is unibyte and does not set BACKREF.
+       Skip kwset if the DFA is fast.  For example:
+
+           yes abcdabc | head -50000000 >k
+           env LC_ALL=C time -p src/grep -i 'abcd.bd' k
+
+       This improved real-time from 4.86 to 1.34 s.
+
+       * src/dfa.c, src/dfa.h (dfaisfast): New function.
+       * src/dfasearch.c (EGexecute): Use it.
+
+2014-04-24  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: fix recently-introduced memory leak
+       Problem reported by Aharon Robbins in: http://bugs.gnu.org/17341
+       * src/dfa.c (dfasuperset): free after dfafree.
+
+       misc: fix doc and test bugs re grep -z
+       Problem reported by Stephane Chazelas in: http://bugs.gnu.org/16871
+       * doc/grep.texi (Usage): Remove incorrect example with -P.
+       * tests/pcre: Improve test so that it actually tests whether \s
+       matches a newline.
+
+       dfa: minor simplification of dfaexec
+       * src/dfa.c (dfaexec): Streamline updating of returned values.
+       Don't bother to check d->multibyte before updating mbp.
+       Avoid duplicate p > end test.
+
+2014-04-24  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: simplify and be more consistent about MB_CUR_MAX
+       * src/dfa.c (struct dfa): New member 'multibyte',
+       replacing 'mb_cur_max'.  All uses changed.  Use this new member
+       consistently, instead of sometimes referring to MB_CUR_MAX directly.
+
+       dfa: fix comment
+       * src/dfa.c (maybe_realloc): Fix comment to match behavior better.
+
+2014-04-24  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: skip checking of multibyte character boundary, reaching at eolbyte
+       * src/dfa.c (dfaexec): Skip checking of multibyte character boundary,
+       reaching at eolbyte.
+
+2014-04-24  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: fix incorrect comment that led to heap overrun
+       * dfa.c (maybe_realloc): Fix comment to match behavior.
+
+       dfa: minor tuneup of dfamust memory savings patch
+       * src/dfa.c (allocmust): Use xmalloc, not xzalloc.
+       Initialize the must completely, so that the caller need not
+       invoke resetmust.  All callers changed.
+       (dfamust): Omit asserts that aren't needed on typical machines
+       where dereferencing NULL dumps core.  Don't leak memory if the
+       pattern contains a NUL byte.
+
+2014-04-24  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: avoid wasting memory for large patterns in dfamust
+       * src/dfa.c (struct must): New member 'prev'.  It points to the
+       previous must.
+       (allocmust): New function.
+       (freemust): New function.
+       (dfamust): Use it.
+
+2014-04-24  Jim Meyering  <meyering@fb.com>
+
+       grep: fix new heap write buffer overrun
+       * src/dfa.c (parse_bracket_exp): Fix off-by-one allocation error.
+       Exposed by running the tests with an ASAN-enabled binary (i.e.,
+       created using gcc's -fsanitize=address option).  Introduced by
+       commit v2.18-70-gd3d9612, "dfa: simplify range char allocation".
+
+2014-04-24  Paul Eggert  <eggert@cs.ucla.edu>
+
+       build: suppress unsafe-loop-optimizations warnings
+       I ran into one of these while trying out GCC 4.9.0's new
+       -fsanitize=undefined option.  The warning told me that GCC didn't
+       do an unsafe optimization, but in 'grep' this is not typically a
+       symptom of a programming error.
+       * configure.ac (WERROR_CFLAGS): Suppress -Wunsafe-loop-optimizations.
+
+2014-04-23  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: fix memory leak reintroduced by previous patch
+       Reported by Norihiro Tanaka in <http://bugs.gnu.org/17328#16>.
+       * src/dfa.c (dfaexec): Allocate mb_match_lens and mb_follows only
+       if not already allocated.
+       (free_mbdata): Null out mb_match_lens to mark it as being freed.
+
+2014-04-23  Jim Meyering  <meyering@fb.com>
+
+       tests: use consistent spelling for locale name, en_US.UTF-8
+       * tests/pcre-infloop: Spell locale name, en_US.UTF-8, consistently,
+       converting this one use from "en_US.utf8", which would provoke a
+       test failure on OS/X.
+
+2014-04-23  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: omit static variables that limited dfaexec to one struct dfa
+       Problem reported by Aharon Robbins in: http://bugs.gnu.org/17328
+       * src/dfa.c (struct dfa): New member mbs.
+       mb_follows is now a position_set, not a pointer to one;
+       this simplifies memory allocation.  All uses changed.
+       (mbs_to_wchar): Put DFA arg at the end, in place of the mbstate_t *arg,
+       since the DFA now contains an mbstate_t.  All uses changed.
+       (mbs): Remove static variable.
+       (dfaexec): Remove static bool that attempted to optimize memory
+       allocation, as this wasn't correct for Gawk.  Perhaps we can think
+       of a better way to optimize memory.
+
+2014-04-22  Paul Eggert  <eggert@cs.ucla.edu>
+
+       kwset: simplify and speed up Boyer-Moore unibyte -i in some cases
+       This improves the performance of, for example,
+       yes jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj | head -10000000 | grep -i jk
+       in a unibyte locale.
+       * src/kwset.c (memchr_trans): New function.
+       (bmexec): Use it.  Simplify the code and remove some of the
+       confusing gotos and breaks and labels.  Do not treat glibc memchr
+       as a special case; if non-glibc memchr is slow, that is lower
+       priority and I suppose we can try to work around the problem in
+       gnulib.
+
+2014-04-22  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: speed-up by using memchr() in Boyer-Moore searching
+       memchr() of glibc is faster than seeking by delta1 on some platforms.
+       When there is no chance to match for a while, use it on them.
+       * src/kwset.c (bmexec): Use memchr() in Boyer-Moore searching.
+
+2014-04-22  Paul Eggert  <eggert@cs.ucla.edu>
+
+       kwset: simplify Boyer-Moore with unibyte -i
+       This change doesn't significantly affect performance on my platform,
+       and should make the code easier to maintain.
+       * src/kwset.c (BM_DELTA2_SEARCH, LAST_SHIFT, TRANS):
+       Remove these macros, in favor of ...
+       (tr, bm_delta2_search): New functions.  All uses changed.
+       The latter function is inline because this improves code size and
+       runtime CPU slightly on x86-64 with gcc -O2 (GCC 4.9.0).
+       (bmexec): Prefer tr when that's simpler.
+
+2014-04-22  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: may also use Boyer-Moore algorithm for case-insensitive matching
+       * src/kwset.c (BM_DELTA2_SEARCH, LAST_SHIFT, TRANS): New macro.
+       (bmexec): Use character translation table.
+       (kwsexec): Call bmexec for case-insensitive matching.
+       (kwsprep): Change the `if' condition.
+
+2014-04-21  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: -P now rejects invalid input sequences in UTF-8 locales
+       See <http://bugs.gnu.org/17245> and <http://bugs.exim.org/1468>.
+       * NEWS: Document this.
+       * src/pcresearch.c (Pexecute): Do not use PCRE_NO_UTF8_CHECK,
+       as this leads to undefined behavior when the input is not UTF-8.
+       * tests/pcre-infloop, tests/pcre-invalid-utf8-input:
+       Exit status is now 2, not 1, when grep -P is given invalid UTF-8
+       data in a UTF-8 locale.
+
+       dfa: minor improvements to previous patch
+       * src/dfa.c (dfamust): Use &=, not if-then.
+       * src/dfa.h (struct dfamust):
+       * src/dfasearch.c (begline, hwsmusts): Use bool for boolean.
+       * src/dfasearch.c (kwsmusts):
+       * src/kwsearch.c (Fcompile): Prefer decls after statements.
+       * src/dfasearch.c (kwsmusts): Avoid conditional branch.
+       * src/kwsearch.c (Fcompile): Unify the two calls to kwsincr.
+
+2014-04-21  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: speed-up for exact matching with begline and endline constraints.
+       dfamust turns on the flag when a state exactly matches the proposed one.
+       However, when the state has begline and/or endline constraints, turns
+       off it.
+
+       This patch enables to match a state exactly, even if the state has
+       begline and/or endline constraints.  If a exact string has one of their
+       constrations, the string adding eolbyte to a head and/or foot is pushed
+       to kwsincr().  In addition, if it has begline constration, start
+       searching from just before the position of the text.
+
+       * src/dfa.c (variable must): New members `begline' and `endline'.
+       (dfamust): Consideration of begline and endline constrations.
+       * src/dfa.h (struct dfamust): New members `begline' and `endline'.
+       * src/dfasearch.c (kwsmusts): If a exact string has begline constration,
+       start searching from just before the position of the text.
+       (EGexecute): Same as above.
+       * src/kwsearch.c (Fexecute): Same as above.
+
+2014-04-20  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: fix bug that caused NUL to be mishandled in patterns
+       This bug was introduced in the early-2012 patches that fixed some
+       context-handling bugs.  Bisecting found commit
+       d8951d3f4e1bbd564809aa8e713d8333bda2f802 (2012-02-05 18:00:43 +0100),
+       but it apears the underlying problem was introduced in commit
+       8b47c4cf6556933f59226c234b0fe984f6c77dc7 (2012-01-03 11:22:09 +0100).
+       * NEWS: Mention bug fix.
+       * src/dfa.c (char_context): Consider NUL to be a newline only if -z.
+       * tests/Makefile.am (TESTS): Add null-byte.
+       * tests/null-byte: New file.
+
+2014-04-19  Jim Meyering  <meyering@fb.com>
+
+       build: reenable some compiler warning options
+
+2014-04-18  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: fix pointer type conversion bug
+       The code converted between size_t * and ptrdiff_t *, which wasn't
+       diagnosed by modern x86-64 GCC but isn't portable.  Problem
+       reported by Norihiro Tanaka in <http://bugs.gnu.org/17136#31>.
+       * configure.ac (WERROR_CFLAGS): Don't add -Wno-pointer-sign.
+       We want GCC to diagnose pointer signedness problems, as they
+       violate the C standard and other compilers no doubt complain too.
+       * src/dfa.c (struct dfa): Change type of salloc to size_t.
+       (realloc_trans_if_necessary): Convert signed value to size_t before
+       passing its address to x2nrealloc.  Changing the type of tralloc
+       to size_t might have led to problems elsewhere.
+
+2014-04-18  Jim Meyering  <meyering@fb.com>
+
+       maint: Revert "dfa: avoid new NULL dereference"
+       This reverts commit 5190041fe515743ef4545abf287d243bc025c701.
+       It was only a bug if one neglected to update to the latest gnulib.
+       With the newer xn2realloc, there is no problem.
+
+       dfa: avoid new NULL dereference
+       * src/dfa.c (dfa_charclass_index): Restore a "+ 1" mistakenly omitted
+       during recent improvements.  Introduced in v2.18-66-g6a60fd5.
+
+2014-04-17  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: minor cleanup
+       * src/dfa.c (MAX): Remove; no longer used.
+
+2014-04-17  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       dfa: speed up by checking multibyte characters on demand
+       If dfaexec() runs in non-UTF8 locales, length and wide character
+       representation are checked for all characters of a line in a input
+       string.  However, if matched early in the line, results for remaining
+       characters are wasted.
+
+       This patch checks multibyte characters on demand.  It should work
+       faster for early matches, and reduces memory requirements.
+
+       * src/dfa.c (struct dfa): Remove members mblen_buf, nmblen_buf,
+       inputwcs, ninputwcs.  All uses removed.
+       (buf_begin, buf_end, prepare_wc_buf): Remove.  All uses removed.
+       (SKIP_REMAINS_MB_IF_INITIAL_STATE): Remove.  This is now expanded
+       when used.
+       (match_anychar, match_mb_charset, check_matching_with_multibyte_ops):
+       New arg wc, mbclen.  Remove arg idx.  All uses changed.
+       (transit_state_consume_1char): New arg wc.  All uses changed.
+       (transit_state): New arg 'end'.  All uses changed.
+
+2014-04-17  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: trans reallocation microoptimization
+       * src/dfa.c (realloc_trans_if_necessary):
+       Help the compiler avoid unnecessary reloads.
+
+       dfa: simplify dfmust initialization
+       * src/dfa.c (dfamust): Don't initialize musts twice.
+       Use zcalloc, not xmalloc followed by zeroing.
+       Make result a const pointer.
+
+       dfa: simplify freelist
+       * src/dfa.c (freelist): Don't null out array while freeing its
+       pointers; the caller can do that if needed.
+       (resetmust): Null out zeroth entry of array.
+
+       dfa: avoid duplicate strlen when allocating memory
+       * src/dfa.c (dfamust): Use xstrdup, not strlen (twice) + xmemdup.
+
+       dfa: simplify memory allocation
+       * src/dfa.c (icatalloc, freelist, enlist, comsubs, addlists, inboth)
+       (dfamust): Don't worry about null arguments or results,
+       as memory allocators no longer can return null pointers.
+       (dfamust): Invoke malloc just once when building a concatenated string.
+
+       dfa: simplify position set and element count allocation
+       * src/dfa.c (dfaanalyze): Allocation position set info all at one go,
+       and similarly for element count info.
+
+       dfa: simplify multibyte_prop allocation
+       * src/dfa.c (struct dfa): Simplify by removing nmultibyte_prop;
+       it should always be the same as talloc.  All uses changed.
+
+       dfa: simplify range char allocation
+       * src/dfa.c (struct dfa): Simplify by allocating one array of ranges
+       rather than one for range starts and another for range ends.
+       All uses changed.
+
+       dfa: simplify transition table allocation
+       * src/dfa.c (struct dfa): Remove member 'realtrans', as it can
+       be computed from 'trans'.  All uses changed.
+       (realloc_trans_if_necessary): Move earlier, to avoid a forward decl.
+       Use x2nrealloc to compute new size, rather than doing it by hand,
+       which omits a check for unlikely overflow.
+       (realloc_trans_if_necessary, dfafree): Adjust to the fact that
+       d->trans now might be either NULL, or 1 + the pointer to free.
+       (build_state, build_state_zero): Use realloc_trans_if_necessary
+       instead of duplicating its code.
+
+       dfa: better size-overflow check
+       * src/dfa.c (dfasuperset): Let xnmalloc do the multiplication,
+       to check for size arithmetic overflow better.
+
+       dfa: avoid unnecessary work and other initialization
+       * src/dfa.c (dfaanalyze, dfainit):
+       Don't bother allocating when x2nrealloc will do it for us.
+       (dfastate): Allocate grps and labels on the stack, as their
+       size is known at compile time.
+       (build_state): Use xmalloc, not xnmalloc, since the multiplication
+       can be done at compile-time.
+
+       dfa: clarify memory allocation and port to IRIX
+       This change was prompted by a porting problem:
+       IRIX defines its own MALLOC macro, which clashes with ours.
+       More generally, the MALLOC etc. macros are confusing, as they
+       look like functions but do not have C-function semantics.
+       A functional style makes the code easier to read, and though
+       it lengthens the code a bit here it'll make other
+       simplifications easier.
+       * src/dfa.c (XNMALLOC, XCALLOC, CALLOC, MALLOC, REALLOC): Remove.
+       All uses replaced by xnmalloc etc.
+       (REALLOC_IF_NECESSARY): Remove; all uses replaced by ....
+       (maybe_realloc): New function.
+       (copy, merge): Free and allocate rather than realloc, as we
+       needn't save the contents.
+
+2014-04-14  Jim Meyering  <meyering@fb.com>
+
+       tests: detect an infloop-inducing bug in grep -P (pcre-8.35)
+       * tests/pcre-infloop: New test.
+       * tests/Makefile.am (TESTS): Add it.
+
+2014-04-12  Paul Eggert  <eggert@cs.ucla.edu>
+
+       build: update gnulib submodule to latest
+
+2014-04-11  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: improvements for the open-CSET patch
+       * src/dfa.c (dfamust): Simplify by removing some duplicate code.
+       Optimize patterns like [aaa] even when not case-folding.
+       Avoid an unnecessary copy of the charclass.
+
+2014-04-11  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: open CSET and transform into uppercase when MB_CUR_MAX == 1
+       In unibyte locales with -i, kwset matching isn't helpful, because
+       dfamust doesn't extract the CSET entries.  Fix dmamust so that it
+       does that, and makes it possible to take out a longer fixed string
+       from tokens.
+       * src/dfa.c (dfamust): open CSET and transform into uppercase
+       when MB_CUR_MAX == 1.
+
+2014-04-11  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: cleanup for HAS_DOS_FILE_CONTENTS issue
+       While cleaning up the empty-string fix, I noticed that one part of
+       the code worried about CRLF in pattern files whereas another part
+       did not.  Fix this by using the same approach in both places,
+       and make the CRLF code more modular in the process.
+       * src/dosbuf.c (dos_binary, dos_unix_byte_offsets): New functions.
+       (undossify_input, dossified_pos): Do nothing if ! O_BINARY.
+       * src/grep.c: Always include dosbuf.c so that the code is
+       checked statically even on non-DOS hosts.
+       (dos_binary, dos_unix_byte_offsets): New decls.
+       (undossify_input): Declare unconditionally.
+       * src/grep.c (fillbuf, print_line_head, main):
+       * src/kwsearch.c (Fcompile):
+       Simplify by not worrying about HAVE_DOS_FILE_CONTENTS.
+       * src/grep.c (main): fopen with "rt" if O_TEXT; this is simpler
+       than worrying about HAVE_DOS_FILE_CONTENTS elsewhere.
+       * src/system.h (HAVE_DOS_FILE_CONTENTS): Remove.
+
+       grep: cleanup for empty-string fix
+       * NEWS: Document it.
+       * src/dfasearch.c (GEAcompile):
+       * src/kwsearch.c (Fcompile):
+       Use C99-style decls to simplify.  Avoid duplicate code.
+       * tests/empty-line: Add some more tests like this.
+
+2014-04-11  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: no match for the empty string included in multiple patterns
+       * src/dfasearch.c (EGAcompile): Fix it.
+       * src/kwsearch.c (Fcompile): Fix it.
+
+2014-04-08  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: remove bool_bf
+       The extra complexity of this microoptimization wasn't ever much help,
+       and currently it generated bigger code with gcc -O2 (x86-64).
+       * src/dfa.c (bool_bf): Remove.  All uses replaced by plain 'bool',
+       without a bitfield.
+
+2014-04-08  Jim Meyering  <meyering@fb.com>
+
+       maint: avoid sc_po_check syntax-check failure (kwset.c)
+       * po/POTFILES.in: Remove kwset.c from this list, since it
+       no longer contains a translatable diagnostic.
+
+2014-04-08  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: port better to hosts with nonstandard nl_langinfo
+       On some hosts, nl_langinfo returns strings other than "UTF-8" when
+       UTF-8 is used, and (worse) return "UTF-8" even if the encoding is
+       single-byte.  Work around these problems by trying a sample
+       character instead.
+       * src/dfa.c, src/pcresearch.c, src/searchutils.c:
+       Don't include <langinfo.h>.
+       * src/dfa.c (using_utf8): Test for UTF-8 by trying a character
+       rather than by invoking nl_langinfo (CODESET); this is more
+       portable in practice, and removes a dependency on
+       HAVE_LANGINFO_CODESET.
+       * src/pcresearch.c: Include dfa.h, for using_utf8.
+       (Pcompile): Use using_utf8 rather than nl_langinfo.
+
+2014-04-07  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: prefer bool in DFA internals
+       * src/dfa.c (bool_bf): New type.
+       (dfa_state): Use it, as this seems to generate slightly better
+       code with GCC.
+       (struct mb_char_classes, struct dfa, equal, case_fold, dfasyntax)
+       (laststart, parse_bracket_exp, lex, dfaparse, dfaanalyze, dfastate)
+       (match_mb_charset, dfamust):
+       Use bool for boolean.
+       (using_utf8) [!HAVE_LANGINFO_CODESET]: Tune.
+       (dfaanalyze): Prefer & to && and | to || on booleans; it's simpler here.
+       (dfastate): Simplify charclass nonzero testing.  Redo has_mbcset
+       test so that the compiler's more likely to optimize it.
+
+2014-04-07  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: prefer regex to DFA for ANYCHAR in multibyte locales
+       * src/dfa.c (dfa_state): New member has_mbcset.
+       Rename backref to has_backref, and make it of type bool too.
+       All uses changed.
+       (state_index, dfastate): Initialize new member.
+       (dfaexec): Prefer regex to DFA for ANYCHAR in multibyte locales.
+
+2014-04-07  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: remove trival_case_ignore
+       This optimization is no longer needed, given the other
+       optimizations recently installed.  Derived from a patch by
+       Norihiro Tanaka; see <http://bugs.gnu.org/17019>.
+       * bootstrap.conf (gnulib_modules): Remove assert-h.
+       * src/dfa.c (CASE_FOLDED_BUFSIZE): Move here from dfa.h.
+       Remove now-unnecessary static assert.
+       (case_folded_counterparts): Now static.
+       * src/dfa.h (CASE_FOLDED_BUFSIZE, case_folded_counterparts):
+       Remove decls; no longer public.
+       * src/dfasearch.c (kwsmusts): Use kwset even if fill MB_CUR_MAX > 1
+       and case-insensitive.
+       * src/grep.c (MBRTOWC, WCRTOMB): Remove.
+       (fgrep_to_grep_pattern): Use mbrtowc, not MBRTOWC.
+       (trivial_case_ignore): Remove; this optimization is no longer needed.
+       All uses removed.
+
+       grep: simplify memory allocation in kwset
+       * src/kwset.c: Include kwset.h first, to check its prereqs.
+       Include xalloc.h, for xmalloc.
+       (kwsalloc): Use xmalloc, not malloc, so that the caller need not
+       worry about memory allocation failure.
+       (kwsalloc, kwsincr, kwsprep): Do not worry about obstack_alloc
+       returning NULL, as that's not possible.
+       (kwsalloc, kwsincr, kwsprep, bmexec, cwexec, kwsexec, kwsfree):
+       Omit unnecessary conversion between struct kwset * and kwset_t.
+       (kwsincr, kwsprep): Return void since memory-allocation failure is
+       not possible now.  All uses changed.
+       * src/kwset.h: Include <stddef.h>, for size_t, so that this
+       include file doesn't require other files to be included first.
+
+       grep: minor cleanups for Galil speedups
+       * src/kwset.c: Update citations.
+       Include stdbool.h.
+       (kwsincr, kwsprep): Clarify by using C99 decls after statements.
+       (kwsprep): Clarify by using MIN.  Avoid a couple of buffer copies
+       when !TRANS.
+       (bmexec): Use bool for boolean.  Prefer "continue;" to ";".
+
+2014-04-07  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: use the Galil rule for Boyer-Moore algorithm in KWSet
+       The Boyer-Moore algorithm is O(m*n), which means it may be much
+       slower than the DFA.  Its Galil rule variant is O(n) and increases
+       efficiency in the typical case; it skips sections that are known
+       to match and does not compare more than once for a position in the text.
+       To use the Galil rule, look for the delta2 shift at each position
+       from the trie instead of the 'mind2' value.
+       * src/kwset.c (struct kwset): Replace member 'mind2' with 'shift'.
+       (kwsprep): Look for the delta2 shift.
+       (bmexec): Use it.
+
+2014-04-06  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: cleanup DFA superset optimization
+       * src/dfa.c (dfa_charclass_index): New function, with body of
+       old dfa_charclass but with an extra parameter D.
+       (charclass_index): Reimplement in terms of dfa_charclass_index.
+       (dfahint): Clarify.
+       (dfasuperset): Do not assign to 'dfa' static variable.  Instead,
+       use a local, and use the new dfa_charclass_index function.  This
+       doesn't fix any bugs, but it's clearer.  Initialize a few more
+       members, to simplify dfafree.  Copy the charclasses with
+       just one memcpy call.  Don't assign nonnull to D->superset until
+       it's known to be valid; that's simpler.
+       (dfafree, dfaalloc): Simplify based on dfasuperset initializations.
+       * src/dfa.h (dfahint): Add comment.
+       * src/dfasearch.c (EGexecute): Simplify use of memchr.
+       Simplify by using memrchr.  Fix typo that could cause a buffer
+       read overrun.
+
+2014-04-06  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: optimization with the superset of DFA
+       The superset of a DFA is like the DFA, except that for speed
+       ANYCHAR, MBCSET and BACKREF are replaced by (CSET full bits) STAR,
+       and mb_cur_max is 1.  For example, for 'a\(b\)c\1':
+         original: a b CAT c CAT BACKREF CAT
+         superset: a b CAT c CAT CSET STAR CAT  (The CSET has all bits set.)
+       If a string matches a DFA, it matches the DFA's superset.
+       Using the superset to filter can dramatically improve performance,
+       over 200x in some cases.  See <http://bugs.gnu.org/16966>.
+       * src/dfa.c (struct dfa): New member 'superset'.
+       (dfahint, dfasuperset): New functions.
+       (dfacomp): Create and analyze the superset.
+       (dfafree): Free only non-NULL items.
+       (dfaalloc): Initialize superset member.
+       (dfaoptimize): If succeed in optimization for UTF-8 locale, don't use
+       the superset.
+       * src/dfa.h (dfahint): New decl.
+       * src/dfasearch.c (EGexecute): Use dfahint.
+
+2014-04-06  Jim Meyering  <meyering@fb.com>
+
+       build: avoid OS X 10.8.5 build failure due to lack of static_assert
+       * bootstrap.conf (gnulib_modules): Add assert-h, to accommodate the
+       new use of static_assert on systems lacking support for that construct.
+       Without this change, compilation of dfa.c failed on OS X 10.8.5 with
+       gcc-4.9.0 20140324.  We should be using gnulib's assert-h module,
+       regardless, for its nominal improved portability, since grep includes
+       assert.h and uses assert.
+
+2014-04-05  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: fix performance bug with regex in line-by-line mode
+       * src/dfasearch.c (EGexecute): Match line-by-line with regex.
+
+2014-04-05  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: minor improvements to previous patch
+       * src/dfa.c (MAX): New macro.
+       (match_anychar, match_mb_charset, transit_state_consume_1char):
+       Use it to simplify assignments.
+       (SKIP_REMAINS_MB_IF_INITIAL_STATE): Prefer != 0 for unsigned.
+       (free_mbdata): Omit an unnecessary 'free'.
+
+2014-04-05  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: reuse multibyte DFA buffers in non-UTF8 locales
+       * src/dfa.c (struct dfa): New members 'mblen_buf', 'nmblen_buf',
+       'inputwcs', 'ninputwcs', 'mb_follows' and 'mb_match_lens'.
+       (mblen_buf, inputwcs): Remove static vars.
+       (SKIP_REMAINS_MB_IF_INITIAL_STATE, match_anychar, match_mb_charset)
+       (transit_state_consume_1char, transit_state, prepare_wc_buf):
+       Use new members instead of global variables.
+       (check_matching_with_multibyte_ops): Use new members
+       instead of new allocation.
+       (dfaexec): Initialize new members.
+       (free_mbdata): Free new members.
+
+2014-04-05  Paul Eggert  <eggert@penguin.cs.ucla.edu>
+
+       grep: simplify dfa.c by having it not include mbsupport.h directly
+       * src/mbsupport.h: Remove.
+       * src/Makefile.am (noinst_HEADERS): Remove mbsupport.h.
+       * src/dfa.c, src/grep.c, src/search.h: Don't include mbsupport.h.
+       * src/dfa.c: Include wchar.h and wctype.h unconditionally, as
+       this simplifies the use of dfa.c in grep, and it does no harm
+       in gawk.
+       (setlocale, static_assert): Remove gawk-specific hacks, as
+       gawk now does these itself.
+       (struct dfa, dfambcache, mbs_to_wchar)
+       (is_valid_unibyte_character, setbit_wc, using_utf8, FETCH_WC)
+       (addtok_wc, add_utf8_anychar, atom, state_index, epsclosure)
+       (dfaanalyze, dfastate, prepare_wc_buf, dfaoptimize, dfafree, dfamust):
+       * src/dfasearch.c (EGexecute):
+       * src/grep.c (main):
+       * src/searchutils.c (mbtoupper):
+       Assume MBS_SUPPORT.
+
+2014-04-01  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       dfa: avoid re-building a state built previously
+       * src/dfa.c (dfaexec): Avoid to re-build a state built previously.
+
+2014-03-28  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: improve port to freestanding DJGPP
+       Suggested by Aharon Robbins (Bug#17056).
+       * src/dfa.c (setlocale) [!LC_ALL]: Return NULL, not "C",
+       reverting part of a recent change.
+       (using_simple_locale): Return true if setlocale returns null.
+
+2014-03-28  Jim Meyering  <meyering@fb.com>
+
+       tests: placate "make syntax-check" re compare arg ordering
+       * tests/euc-mb: Reverse order of arguments to compare.
+       Be consistent in ordering compare arguments: expected followed
+       by actual.
+
+2014-03-28  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: avoid an indirection and port wint_t usage
+       * src/dfa.c (struct dfa): Put mbrtowc_cache directly into struct dfa
+       rather than having a pointer; this saves a malloc and an indirection.
+       All uses changed.
+       (dfambcache): Port to hosts where wint_t * can't be cast to wchar_t *.
+
+2014-03-28  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: take mbrtowc_cache into new member of struct dfa
+       When struct dfa more than one are used at the same time, mbrtowc cache
+       may be conflict.  So, take mbrtowc_cache into new member of struct dfa,
+       and define each mbrtowc cache for them.
+
+       * src/dfa.c (struct dfa): New member `mbrtowc_cache'.
+       (dfambcache): Rename from build_mbrtowc_cache.  Add dependency on struct dfa.
+       (mbs_to_wchar): Add dependency on struct dfa.
+       (FETCH_WC): Use it.
+       (prepare_wc_buf): Use it.  Add dependency on struct dfa.
+       (dfacomp): Call it.
+       (dfafree): Release it.
+
+2014-03-28  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: cache results of mbrtowc for speed
+       Idea suggested by Norihiro Tanaka in Bug#16842.
+       * src/dfa.c (mbrtowc_cache): New static var.
+       (build_mbrtowc_cache, mbs_to_wchar): New functions.
+       (FETCH_WC) [MBS_SUPPORT]: Speed up by using mbs_to_wchar
+       instead of mbrtowc and wctob.
+       (FETCH_WC) [!MBS_SUPPORT]: Rewrite in terms of old FETCH macro.
+       (FETCH): Remove; no longer used.
+       (lex): Simplify by avoiding the need for FETCH.
+       (prepare_wc_buf) [MBS_SUPPORT]: Speed up by using mbs_to_wchar.
+       Simplify the loop.
+       (dfacomp): Initialize the cache.
+
+2014-03-27  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: perform the kwset-helping DFA match in narrower range
+       When kwsexec gives us the offset of a potential match, we compute
+       line begin/end and then run the DFA matcher to see if there really
+       is a match on that line.  When the beginning of the line, BEG, is
+       not on a multibyte character boundary, advance BEG until it on such
+       a boundary, before running the DFA search.
+       * src/dfasearch.c (EGexecute): As above.  Add a comment.
+       * tests/euc-mb: Add a test case that exercises this code.
+       This addresses http://debbugs.gnu.org/17095.
+
+2014-03-26  Jim Meyering  <meyering@fb.com>
+
+       maint: fix "make dist"
+       * src/Makefile.am (egrep fgrep): Specify egrep.sh via
+       $(srcdir)/egrep.sh, so non-srcdir builds work once again.
+
+2014-03-26  Paul Eggert  <eggert@penguin.cs.ucla.edu>
+
+       dfa: improve port to freestanding DJGPP
+       * src/dfa.c (setlocale) [!LC_ALL]: Return "C", not NULL (Bug#17056).
+       (using_simple_locale): Store setlocale result in a ptr-to-const.
+
+       egrep, fgrep: improve diagnostics from shell scripts
+       This should fix Bug#17098.
+       * src/Makefile.am (EXTRA_DIST): Add egrep.sh.
+       (egrep fgrep): Depend on egrep.sh and Makefile.
+       Build from new file egrep.sh, as this makes the build process
+       easier to follow.  Arrange for $0 to look nicer in subgrep.
+       * src/egrep.sh: New file.
+
+2014-03-23  Paul Eggert  <eggert@cs.ucla.edu>
+
+       dfa: avoid undefined behavior
+       * src/dfa.c (FETCH_WC, addtok_wc): Don't rely on undefined behavior
+       when converting an out-of-range value to 'int'.
+       (FETCH_WC, prepare_wc_buf): Don't rely on conversion state after
+       mbrtowc returns a special value, as it's undefined for (size_t) -1.
+       (prepare_wc_buf): Simplify test for valid character.
+
+       grep: fix and simplify grep -iF optimization
+       * src/grep.c (check_any_alphabets): Remove.
+       (fgrep_to_grep_pattern): Fix problems when mbrtowc returns -1 or -2.
+       Simplify a bit.
+       (main): Don't bother optimizing 'grep -iF PAT' when PAT contains no
+       alphabetics; it's so rare it's not worth the complexity.
+
+2014-03-23  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: optimization for fgrep with changing the macher to grep macher.
+       fgrep macher is only use kwset engine.  However, it's very slow for
+       case-insensitive matching in multibyte locales.
+
+       And so, if the matcher is fgrep and case-insensitive and keys including
+       any alphabets, change it into grep matcher by escape of keys.  OTOH, if
+       keys include no alphabet, turn match_icase flag off.
+
+       I prepare following string to measure the performance.
+
+           yes $(printf '%078dm' 0)| head -1000000 | tr 0 a > in
+           A=`printf '\xef\xbc\xa1'`   # FULLWIDTH LATIN CAPITAL LETTER A
+
+       I run three tests with this patch (best-of-5 trials):
+
+           env LC_ALL=en_US.UTF-8 time -p src/fgrep -i "$A" in
+               real 8.54       user 7.13       sys 1.16
+
+       Back out that commit (temporarily), recompile, and rerun the experiment:
+
+           env LC_ALL=en_US.UTF-8 time -p src/fgrep -i "$A" in
+               real 0.07       user 0.02       sys 0.05
+
+       * src/fgrep.c (Gcompile) New function.
+       * src/main.c (check_any_alphabets) New function.
+       (fgrep_to_grep_pattern) New function.
+       (main) Use them.
+
+2014-03-23  Paul Eggert  <eggert@cs.ucla.edu>
+
+       egrep, fgrep: go back to shell scripts
+       Although egrep's and fgrep's switch from shell scripts to
+       executables may have made sense in 2005, it complicated
+       maintenance and recently has caused subtle performance bugs.
+       Go back to the old way of doing things, as it's simpler and more
+       easily separated from the mainstream implementation.  This should
+       be good enough nowadays, as POSIX has withdrawn egrep/fgrep and
+       portable applications should be using -E/-F anyway.
+       * po/POTFILES.in: Remove src/egrep.c, src/fgrep.c, src/main.c.
+       * src/Makefile.am (bin_PROGRAMS): Remove egrep, fgrep.
+       (bin_SCRIPTS): New macro.
+       (grep_SOURCES): Move searchutils.c, dfa.c, dfasearch.c, kwset.c,
+       kwsearch.c, pcresearch.c here from libgrep_a_SOURCES.
+       (egrep_SOURCES, fgrep_SOURCES, noinst_LIBRARIES, libgrep_a_SOURCES):
+       Remove.
+       (LDADD): Remove libgrep.a.
+       (egrep, fgrep): New rules.
+       (CLEANFILES): New macro.
+       * src/grep.c: Rename from src/main.c.
+       (usage, setmatcher, main):
+       Simplify, since there's now just one executable.
+       (Gcompile, Ecompile, Acompile, GAcompile, PAcompile, matchers):
+       Move here from the (removed) src/grep.c.
+       (compile_fp_t, execute_fp_t, struct matcher, matchers):
+       Move here from src/grep.h, as they no longer need to be public.
+       (struct matcher.name): Avoid one level of indirection/relocation.
+       (do_execute, main): Fix a performance bug when it was compiled
+       as 'fgrep', due to confusion about which matcher was which.
+       (main): Fix a performance bug with -P, likewise.
+       * src/grep.h (before_options, after_options): Remove.
+       * src/egrep.c, src/fgrep.c, src/grep.c: Remove.
+
+       dfa: port to freestanding DJGPP (Bug#17056)
+       * src/dfa.c (setlocale) [!LC_ALL]: Define a dummy.
+
+2014-03-16  Jim Meyering  <meyering@fb.com>
+
+       tests: avoid false-positive failure on some AMD CPUs
+       * tests/mb-non-UTF8-performance: Avoid false-positive failure
+       when run on certain AMD processors.
+
+2014-03-10  Jim Meyering  <meyering@fb.com>
+
+       tests: make a performance-measuring test less system-sensitive
+       Andreas Schwab reported in http://debbugs.gnu.org/16941
+       that this test would timeout and fail on m68k-suse-linux.
+       Rather than testing absolute duration with a limit tuned
+       to today's hardware, compare performance of grep with LC_ALL=C
+       against that same command using LC_ALL=ja_JP.eucJP.
+       * tests/init.cfg (require_hi_res_time_): New function.
+       * tests/mb-non-UTF8-performance: Rewrite to use it:
+       record absolute duration D of the first (normally much faster)
+       command, and set a timeout of 8*D for the command running in
+       an affected locale.
+
+2014-03-09  Paul Eggert  <eggert@cs.ucla.edu>
+
+       maint: pacify 'make dist'
+       * src/dfa.c (parse_bracket_exp): Reindent with spaces.
+       * src/dfa.h (case_folded_counterparts): Prefix decl with 'extern'.
+       * src/main.c: Don't include assert.h.
+
+2014-03-07  Paul Eggert  <eggert@cs.ucla.edu>
+
+       fgrep: fix case-fold incompatibility with plain 'grep'
+       fgrep converted to lowercase, whereas the regex code converted
+       to uppercase.  The resulting behaviors don't agree in offbeat
+       cases like Greek sigmas and Turkish Is.  Fix this by changing
+       fgrep to agree with the regex code.
+       * src/kwsearch.c (Fcompile, Fexecute):
+       * src/searchutils.c (kwsinit, mbtoupper):
+       Convert to uppercase, not to lowercase, for compatibility with
+       plain 'grep'.
+       * src/search.h, src/searchutils.c (mbtoupper):
+       Rename from mbtolower, since it now converts to uppercase.
+       All uses changed.
+       * tests/case-fold-titlecase: Add tests for this.
+
+       grep: fix case-fold mismatches between DFA and regex
+       The DFA code and the regex code didn't use the same semantics for
+       case-folding.  The regex code says that the data char d matches
+       the pattern char p if uc (d) == uc (p).  POSIX is unclear in this
+       area; the simplest fix for now is to change the DFA code to agree
+       with the regex code.  See <http://bugs.gnu.org/16919>.
+       * src/dfa.c (static_assert): New macro, if not already defined.
+       (setbit_case_fold_c): Assume MB_CUR_MAX is 1 and that case_fold
+       is nonzero; all callers changed.
+       (setbit_case_fold_c, parse_bracket_exp, lex, atom):
+       Case-fold like the regex code does.
+       (lonesome_lower): New constant.
+       (case_folded_counterparts): New function.
+       (parse_bracket_exp): Prefer plain setbit when case-folding is
+       not needed.
+       * src/dfa.h (CASE_FOLDED_BUFSIZE): New constant.
+       (case_folded_counterparts): New function decl.
+       * src/main.c (trivial_case_ignore): Case-fold like the regex code does.
+       (main): Try to improve comment re trivial_case_ignore.
+       * tests/case-fold-titlecase: Add lots more test cases.
+
+2014-03-06  Paul Eggert  <eggert@cs.ucla.edu>
+
+       build: update gnulib submodule to latest
+
+       doc: do not overpromise --ignore-case's behavior
+       * NEWS: Omit vague statement about titlecase that could be
+       misinterpreted, and is more trouble than it's worth.
+       * doc/grep.texi: Add @documentencoding.  Fix copyright range to
+       use endash not hyphen.
+       (Matching Control): Do not overpromise what --ignore-case will do.
+       Give examples of corner cases where the documentation does not
+       specify behavior.
+
+2014-03-05  Paul Eggert  <eggert@cs.ucla.edu>
+
+       maint: remove differences from gnulib regex code
+       These don't seem to be needed with GCC 4.8.2, and are making
+       maintenance harder.  If we need to disable warnings with older
+       compilers, we can add pragmas to the gnulib versions.  See
+       <http://bugs.gnu.org/16911#24>.
+       * gl/lib/regcomp.c.diff, gl/lib/regex_internal.c.diff:
+       * gl/lib/regex_internal.h.diff, gl/lib/regexec.c.diff:
+       Remove.
+       * cfg.mk (exclude_file_name_regexp--sc_prohibit_tab_based_indentation):
+       Don't mention gl/* files.
+
+2014-03-03  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: fix comment
+       * src/main.c (trivial_case_ignore): Fix comment typo.
+
+2014-03-03  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: avoid to add same character to a bracket expression
+       * src/main.c (trivial_ignore_case): Only when uppercase and/or
+       lowercase is different from original character, add it to new pattern.
+
+2014-03-02  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: fix some unlikely bugs in trivial_case_ignore
+       * src/main.c (MBRTOWC, WCRTOMB): Reformat as per usual GNU style.
+       (trivial_case_ignore): Don't overrun buffer in the unusual case
+       when a character has both lowercase and uppercase counterparts.
+       Don't rely on undefined behavior when assigning out-of-range value
+       to an 'int'.  Simplify by avoiding unnecessary buffer copies.
+       Work even with shift encodings, by using mbsinit to
+       disable the optimization if we are not in the initial state
+       when we replace B by [BCD].
+
+2014-03-02  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: revert removal of trivial_case_ignore
+       Revive trivial_case_ignore function in order to be able to use kwset.
+
+       * src/main.c (MBRTOWC, WCRTOMB): New macros.
+       (trivial_case_ignore): New function.
+       (main): Use it.
+
+2014-03-02  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: optimization of bracket expression for non-UTF8 locales
+       * src/dfa.c (addtok): Replace an MBCSET with a CSET even in
+       non-UTF8 locales, and even when it has individual characters.
+
+2014-03-01  Paul Eggert  <eggert@cs.ucla.edu>
+
+       doc: describe titlecase fix better
+       * NEWS: Document behavior on lowercase text too.
+       Suggested by Eric Blake in <http://bugs.gnu.org/16911#10>.
+       * doc/grep.texi (Matching Control): Specify behavior of -i
+       more precisely.
+
+2014-02-28  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: minor tuning for mb_case_map_apply
+       * src/kwsearch.c (mb_case_map_apply): Avoid unnecessary widening of
+       size_t to intmax_t.  Avoid unnecessary reinitialization of k.
+
+       grep: avoid 'inline' when it doesn't matter
+       These days, compilers generally do just fine without advice from
+       users about 'inline', and there's little need for 'static inline',
+       just as there's little need for 'register'.
+       * src/dfa.c (to_uchar):
+       * src/dosbuf.c (guess_type, undossify_input, dossified_pos):
+       * src/main.c (undossify_input):
+       No longer inline.
+       * src/search.h (mb_case_map_apply): Move from here ...
+       * src/kwsearch.c (mb_case_map_apply): ... to here, and
+       make it no longer 'inline'.
+
+       grep: fix bugs with -i and titlecase
+       * NEWS: Document this.
+       * src/dfa.c (setbit_wc): Simplify.
+       (setbit_c): Remove; no longer used.
+       (setbit_case_fold_c, parse_bracket_exp, atom):
+       Don't mishandle titlecase.  For 'atom', this removes the need for
+       the refactoring of Bug#16729.
+       (lex): Use the slower approach only for letters that have a
+       differing case.
+       * tests/case-fold-titlecase: New file.
+       * tests/Makefile.am (TESTS): Add it.
+
+       grep: remove lint
+       * src/main.c (MBRTOWC, WCRTOMB): Remove no-longer-used macros.
+
+2014-02-28  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       grep: remove trivial_case_ignore
+       * src/main.c (trivial_case_ignore): Remove.
+       (main): Remove its use; this optimization is no longer needed.
+
+       grep: don't match line-by-line for case-insensitive with grep and awk
+       * src/main.c (matcher): Move decl up.
+       (do_execute): With the grep or awk matchers,
+       no need to match line by line.
+
+2014-02-27  Jim Meyering  <meyering@fb.com>
+
+       maint: dfa: pass NULL, not 0, as 2nd arg to setlocale
+       * src/dfa.c (using_simple_locale): Use NULL, not 0.
+
+2014-02-27  Paul Eggert  <eggert@cs.ucla.edu>
+
+       * src/dfa.c (prednames): POSIX allows [[:xdigit:]] to match multibyte chars.
+
+       * src/dfa.c (parse_bracket_exp): Parenthesize.
+
+       grep: fix multiple bugs with bracket expressions
+       * NEWS: Document this.
+       * src/dfa.c (using_simple_locale): New function.
+       (parse_bracket_exp): Handle bracket expressions like [a-[.z.]]
+       correctly.  Don't assume that dfaexec handles expressions like
+       [^a-z] correctly, as they can match multiple characters in some
+       locales.
+       * tests/posix-bracket: New file.
+       * tests/Makefile.am (TESTS): Add it.
+
+2014-02-25  Stephane Chazelas  <stephane.chazelas@gmail.com>
+
+       align grep -Pw with grep -w
+       For the -w option, with -P, we used to look for the pattern surrounded by
+       word boundaries. That's different from what grep -w does and what the
+       documentation describes. Now align with grep -w and the documentation by
+       using PCRE look-behind and look-ahead operators to match the pattern if
+       it is not surrounded by word constituents.
+       * src/pcresearch.c (Pcompile): Use (?<!\w)(?:...)(?!\w) rather than
+       \b(?:...)\b.
+       * NEWS (Bug fixes): Mention it.
+       * tests/pcre-w: New file.
+       * tests/Makefile.am (TESTS): Add it.
+       This complements the fix for http://debbugs.gnu.org/16865
+
+2014-02-24  Stephane Chazelas  <stephane.chazelas@gmail.com>
+
+       grep -P: fix it so backreferences now work with -w and -x
+       To implement -w and -x, we bracket the search term with parentheses.
+       However, that set of parentheses had the default semantics of
+       "capturing", i.e., creating a backreferenceable matched quantity.
+       Instead, use (?:...), to create a non-capturing group.
+       * src/pcresearch.c (Pcompile): Use (?:...) rather than (...).
+       * NEWS (Bug fixes): Mention it.
+       * tests/pcre-wx-backref: New file.
+       * tests/Makefile.am (TESTS): Add it.
+       This addresses http://debbugs.gnu.org/16865
+
+2014-02-20  Jim Meyering  <meyering@fb.com>
+
+       maint: post-release administrivia
+       * NEWS: Add header line for next release.
+       * .prev-version: Record previous version.
+       * cfg.mk (old_NEWS_hash): Auto-update.
+
+       version 2.18
+       * NEWS: Record release date.
+
+       tests: test for the non-UTF8 multi-byte performance regression
+       Test for the just-fixed performance regression.
+       With a 100-200x differential, it is reasonable to expect that
+       a very slow system will be able to complete the designated
+       task in a few seconds, while with the bug, even a very fast
+       system would exceed the timeout.
+       * tests/mb-non-UTF8-performance: New file.
+       * tests/Makefile.am (TESTS): Add it.
+       * tests/init.cfg (require_JP_EUC_locale_): New function.
+
+       grep -i: avoid a performance regression in multibyte non-UTF8 locales
+       * src/main.c: Include dfa.h.
+       (trivial_case_ignore): Perform this optimization only for UTF8 locales.
+       This rectifies a 100-200x performance regression in non-UTF8 multi-byte
+       locales like ja_JP.eucJP.  The regression was introduced by the 10x
+       UTF8/grep-i speedup, commit v2.16-4-g97318f5.
+       * NEWS (Bug fixes): Mention it.
+       Reported by Norihiro Tanaka in http://debbugs.gnu.org/16232#50
+
+       maint: give dfa.c's using_utf8 function external scope
+       * src/dfa.c (using_utf8): Remove "static inline".
+       * src/dfa.h (using_utf8): Declare it.
+       * src/searchutils.c (is_mb_middle): Use using_utf8 rather than
+       rolling our own.
+
+2014-02-20  Paul Eggert  <eggert@cs.ucla.edu>
+
+       tests: test [^^-^] in unibyte locales
+       This is a bug in the current dfa.c, which was reintroduced by the
+       recent reversion from RRI.
+       * tests/unibyte-negated-circumflex: New file.
+       * tests/Makefile.am (TESTS): Add it.
+       * tests/init.cfg (require_unibyte_locale): New function.
+
+       grep: fix bug with patterns like [^^-~] in unibyte locales
+       * NEWS: Document this.
+       * src/dfa.c (parse_bracket_exp): Escape patterns like [^^-~], or
+       Awk patterns like [\^-\]], so that they are not misinterpreted by
+       the system regex library.  Check for system regex failure due to
+       memory exhaustion.
+
+2014-02-17  Jim Meyering  <meyering@fb.com>
+
+       maint: post-release administrivia
+       * NEWS: Add header line for next release.
+       * .prev-version: Record previous version.
+       * cfg.mk (old_NEWS_hash): Auto-update.
+
+       version 2.17
+       * NEWS: Record release date.
+
+2014-02-17  Paolo Bonzini  <bonzini@gnu.org>
+
+       revert "grep: DFA now uses rational ranges in unibyte locales"
+       The correct course of action for grep is to defer range interpretation
+       to regex, because otherwise you can get mismatches between regexes with
+       backreferences and those without.
+
+       For example, [A-Z]. will use RRI but ([A-Z])\1 won't, with the confusing
+       result that the first regex won't match a superset of the language
+       described by the second regex.
+
+       The source of the confusion is that, even though grep's dfa.c was changed
+       to use range checking instead of strcoll, that code is only invoked if
+       dfaexec is called with backref = NULL, and that never happens for grep!
+
+       In the end, all that's needed for RRI is compiling --with-included-regex,
+       and in that case the patch is almost a no-op.  Almost, because there
+       are corner cases that aren't handled correctly (e.g. [a-[.e.]], or
+       regular expressions that include a NUL character), but this can be
+       handled separately.
+
+       * NEWS: Revert paragraph introduced by commit v2.16-7-g1078b64.
+       * src/dfa.c (parse_bracket_exp): Revert back to regcomp/regexec.
+
+2014-02-16  Mike Frysinger  <vapier@gentoo.org>
+
+       maint: ignore configure.lineno
+       * .gitignore: Add configure.lineno.
+
+2014-02-11  Benno Schulenberg  <bensberg@justemail.net>
+
+       help: remove surplus newline
+       * src/main.c (usage): Remove inconsistent \n introduced by previous
+       patch.
+
+2014-02-10  Benno Schulenberg  <bensberg@justemail.net>
+
+       help: fix a line ending, and use the same word for similar things
+       * src/main.c (usage): Change a stray 'n' to a newline, and use
+       the word "display" for showing version info as for help text.
+
+2014-02-09  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       speed up mb-boundary-detection after each preliminary match
+       After each kwsexec or dfaexec match, we must determine whether
+       the tentative match falls in the middle of a multi-byte character.
+       That is what our is_mb_middle function does, but it was expensive,
+       even when most input consisted of single-byte characters.  The main
+       cost was for each call to mbrlen.  This change constructs and uses
+       a cache of the lengths returned by mbrlen for unibyte values.
+       The largest speed-up (3x to 7x, CPU-dependent) is when most
+       lines contain a match, yet few are printed, e.g., when using
+       grep -v common-pattern ... to filter out all but a few lines.
+
+       * src/search.h (build_mbclen_cache): Declare it.
+       * src/main.c: Include "search.h".
+       [MBS_SUPPORT] (main): Call build_mbclen_cache in a multibyte locale.
+       * src/searchutils.c [HAVE_LANGINFO_CODESET]: Include <langinfo.h>.
+       (mbclen_cache): New global.
+       (build_mbclen_cache): New function.
+       (is_mb_middle) [HAVE_LANGINFO_CODESET]: Use it.
+       * NEWS (Improvements): Mention it.
+
+2014-02-01  Jim Meyering  <meyering@fb.com>
+
+       maint: use to_uchar function rather than explicit casts
+       * src/system.h (to_uchar): Define function.
+       * src/kwsearch.c (Fexecute): Use to_uchar twice in place of casts.
+       * src/dfasearch.c (EGexecute): Likewise.
+       * src/main.c (prepend_args): Likewise.
+       * src/kwset.c (U): Define in terms of to_uchar.
+       * src/dfa.c (match_mb_charset): Use to_uchar, not an explicit cast.
+
+2014-01-27  Jim Meyering  <meyering@fb.com>
+
+       maint: remove vestiges of support for long-disabled --mmap option
+       This option was disabled in March of 2010, and began to elicit a
+       warning in January of 2012.  Its time has come.
+       * doc/grep.in.1: Remove mention.
+       * doc/grep.texi: Likewise.
+       * src/main.c (GROUP_SEPARATOR_OPTION, usage, MMAP_OPTION)
+       (long_options, main): Remove all traces.
+       * tests/Makefile.am (check_PROGRAMS): Remove mention of ignore-mmap.
+       * tests/ignore-mmap: Remove file.
+       * NEWS (Maintenance): Mention it.
+
+2014-01-26  Jim Meyering  <meyering@fb.com>
+
+       maint: move two local variable declarations
+       * src/dfasearch.c (kwsmusts): Move one declaration down to the point
+       of definition.  Move another into the sole scope where it is used.
+
+2014-01-26  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       dfasearch: skip kwset optimization when multi-byte+case-insensitive
+       Now that DFA searching works with multi-byte locales, the only remaining
+       reason to case-convert the searched input is the kwset optimization.
+       But multi-byte case-conversion is so expensive that it's not
+       worthwhile even to attempt that optimization.
+
+       * src/dfasearch.c (kwsmusts): Skip this function in ignore-case mode
+       when the locale is multi-byte.
+       (EGexecute): Now that this code need not handle multi-byte case-ignoring
+       matches, remove the expensive copy/case-conversion code.
+       With no case-converted buffer, there is no longer any need to call
+       mb_case_map_apply, so remove it and associated code.
+       (kwsincr_case): Remove function.  Now, every use of this function
+       is equivalent to a use of kwsincr.  Replace all uses.
+       * tests/turkish-eyes: Test all of -E, -F and -G.
+
+2014-01-25  Norihiro Tanaka  <noritnk@kcn.ne.jp>
+
+       dfa: remove GREP-ifdef'd code in favor of code used by gawk
+       For many years, gawk and grep have used different #ifdef'd bits of
+       code relating to how the DFA matcher matches multibyte characters.
+       Remove the GREP-specific code in favor of the code gawk uses.  This
+       permits us to avoid still more cases in which grep must resort to
+       the expensive process of copying/case-converting each input line
+       before matching against a case-converted regexp.
+       * src/dfa.c (parse_bracket_exp, atom): As above.
+
+2014-01-25  Jim Meyering  <meyering@fb.com>
+
+       gnulib: update to latest
+
+2014-01-17  Paul Eggert  <eggert@cs.ucla.edu>
+
+       grep: DFA now uses rational ranges in unibyte locales
+       Problem reported by Aharon Robbins in <http://bugs.gnu.org/16481>.
+       * NEWS:
+       * doc/grep.texi (Environment Variables)
+       (Character Classes and Bracket Expressions):
+       Document this.
+       * src/dfa.c (parse_bracket_exp): Treat unibyte locales like multibyte.
+
+2014-01-17  Aharon Robbins  <arnold@skeeve.com>
+
+       grep: add undocumented '-X gawk' and '-X posixawk' options
+       See <http://bugs.gnu.org/16481>.
+       * src/grep.c (GAcompile, PAcompile): New functions.
+       (const): Use them.
+
+2014-01-10  Pádraig Brady  <P@draigBrady.com>
+
+       tests: remove superfluous uses of printf
+       * tests/turkish-eyes: Remove unnecessary uses of printf.
+
+2014-01-09  Jim Meyering  <meyering@fb.com>
+
+       grep: make --ignore-case (-i) faster (sometimes 10x) in multibyte locales
+       These days, nearly everyone uses a multibyte locale, and grep is often
+       used with the --ignore-case (-i) option, but that option imposes a very
+       high cost in order to handle some unusual cases in just a few multibyte
+       locales.  This change gets most of the performance of using LC_ALL=C
+       without eliminating the ability to search for multibyte strings.
+
+       With the following example, I see an 11x speed-up with a 2.3GHz i7:
+       Generate a 10M-line file, with each line consisting of 40 'j's:
+
+           yes jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj | head -10000000 > k
+
+       Time searching it for the simple/noexistent string "foobar",
+       first with this patch (best-of-5 trials):
+
+           LC_ALL=en_US.UTF-8 env time src/grep -i foobar k
+               1.10 real         1.03 user         0.07 sys
+
+       Back out that commit (temporarily), recompile, and rerun the experiment:
+
+           git log -1 -p|patch -R -p1; make
+           LC_ALL=en_US.UTF-8 env time src/grep -i foobar k
+               12.50 real        12.41 user         0.08 sys
+
+       The trick is to realize that for some search strings, it is easy
+       to convert to an equivalent one that is handled much more efficiently.
+       E.g., convert this command:
+
+         grep -i foobar k
+
+       to this:
+
+         grep '[fF][oO][oO][bB][aA][rR]' k
+
+       That allows the matcher to search in buffer mode, rather than having to
+       extract/case-convert/search each line separately.  Currently, we perform
+       this conversion only when search strings contain neither '\' nor '['.
+       See the comments for more detail.
+
+       * src/main.c (trivial_case_ignore): New function.
+       (main): When possible, transform the regexp so we can drop the -i.
+       * tests/turkish-eyes: New file.
+       * tests/Makefile.am (TESTS): Use it.
+       * NEWS (Improvements): Mention it.
+
+2014-01-07  Paul Eggert  <eggert@cs.ucla.edu>
+
+       tests: port Solaris 10 /bin/sh patch back to GNU/Linux
+       Problem reported by Jim Meyering.
+       * tests/bre, tests/ere, tests/spencer1-locale:
+       Prefer re_shell, not re_shell_.
+       * tests/init.sh (re_shell): New var, which is exported instead of
+       re_shell_.
+
+       Port to Solaris 10 /bin/sh.
+       Problem reported by Dagobert Michelsen in <http://bugs.gnu.org/16380>.
+       * tests/bre, tests/ere, tests/spencer1-locale:
+       Prefer re_shell_ to SHELL, if re_shell_ is set.
+       * tests/init.sh (re_shell_): Export if it's used.
+
 2014-01-01  Jim Meyering  <meyering@fb.com>
 
+       maint: post-release administrivia
+       * NEWS: Add header line for next release.
+       * .prev-version: Record previous version.
+       * cfg.mk (old_NEWS_hash): Auto-update.
+
        version 2.16
        * NEWS: Record release date.
 
index 2be7292..e618a00 100644 (file)
@@ -45,9 +45,12 @@ gen_start_date = 2009-11-27
 .PHONY: gen-ChangeLog
 gen-ChangeLog:
        $(AM_V_GEN)if test -d .git; then                                \
+         log_fix="$(srcdir)/build-aux/git-log-fix";                    \
+         test -e "$$log_fix"                                           \
+           && amend_git_log="--amend=$$log_fix"                        \
+           || amend_git_log=;                                          \
          $(top_srcdir)/build-aux/gitlog-to-changelog                   \
-           --amend=$(srcdir)/build-aux/git-log-fix                     \
-           --since=$(gen_start_date) > $(distdir)/cl-t;                \
-         rm -f $(distdir)/ChangeLog;                                   \
-         mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
+           $$amend_git_log --since=$(gen_start_date) > $(distdir)/cl-t && \
+           { rm -f $(distdir)/ChangeLog &&                             \
+             mv $(distdir)/cl-t $(distdir)/ChangeLog; }                \
        fi
index a252d68..a506541 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1061,6 +1061,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -1192,7 +1193,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --gnu Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -1449,9 +1449,10 @@ distcheck: dist
          && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
          && am__cwd=`pwd` \
          && $(am__cd) $(distdir)/_build \
-         && ../configure --srcdir=.. --prefix="$$dc_install_base" \
+         && ../configure \
            $(AM_DISTCHECK_CONFIGURE_FLAGS) \
            $(DISTCHECK_CONFIGURE_FLAGS) \
+           --srcdir=.. --prefix="$$dc_install_base" \
          && $(MAKE) $(AM_MAKEFLAGS) \
          && $(MAKE) $(AM_MAKEFLAGS) dvi \
          && $(MAKE) $(AM_MAKEFLAGS) check \
@@ -1625,6 +1626,8 @@ uninstall-am:
        maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
        pdf-am ps ps-am tags tags-am uninstall uninstall-am
 
+.PRECIOUS: Makefile
+
 
 # Shortcut target to make it easier to run expensive tests.
 .PHONY: check-expensive
@@ -1643,11 +1646,14 @@ dist-hook: gen-ChangeLog run-syntax-check
 .PHONY: gen-ChangeLog
 gen-ChangeLog:
        $(AM_V_GEN)if test -d .git; then                                \
+         log_fix="$(srcdir)/build-aux/git-log-fix";                    \
+         test -e "$$log_fix"                                           \
+           && amend_git_log="--amend=$$log_fix"                        \
+           || amend_git_log=;                                          \
          $(top_srcdir)/build-aux/gitlog-to-changelog                   \
-           --amend=$(srcdir)/build-aux/git-log-fix                     \
-           --since=$(gen_start_date) > $(distdir)/cl-t;                \
-         rm -f $(distdir)/ChangeLog;                                   \
-         mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
+           $$amend_git_log --since=$(gen_start_date) > $(distdir)/cl-t && \
+           { rm -f $(distdir)/ChangeLog &&                             \
+             mv $(distdir)/cl-t $(distdir)/ChangeLog; }                \
        fi
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/NEWS b/NEWS
index 6626b54..73a8818 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,89 @@
 GNU grep NEWS                                    -*- outline -*-
 
+* Noteworthy changes in release 2.19 (2014-05-22) [stable]
+
+** Improvements
+
+  Performance has improved, typically by 10% and in some cases by a
+  factor of 200.  However, performance of grep -P in UTF-8 locales has
+  gotten worse as part of the fix for the crashes mentioned below.
+
+** Bug fixes
+
+  grep no longer mishandles patterns like [a-[.z.]], and no longer
+  mishandles patterns like [^a] in locales that have multicharacter
+  collating sequences so that [^a] can match a string of two characters.
+
+  grep no longer mishandles an empty pattern at the end of a pattern list.
+  [bug introduced in grep-2.5]
+
+  grep -C NUM now outputs separators consistently even when NUM is zero,
+  and similarly for grep -A NUM and grep -B NUM.
+  [bug present since "the beginning"]
+
+  grep -f no longer mishandles patterns containing NUL bytes.
+  [bug introduced in grep-2.11]
+
+  Plain grep, grep -E, and grep -F now treat encoding errors in patterns
+  the same way the GNU regular expression matcher treats them, with respect
+  to whether the errors can match parts of multibyte characters in data.
+  [bug present since "the beginning"]
+
+  grep -w no longer mishandles a potential match adjacent to a letter that
+  takes up two or more bytes in a multibyte encoding.
+  Similarly, the patterns '\<', '\>', '\b', and '\B' no longer
+  mishandle word-boundary matches in multibyte locales.
+  [bug present since "the beginning"]
+
+  grep -P now reports an error and exits when given invalid UTF-8 data.
+  Previously it was unreliable, and sometimes crashed or looped.
+  [bug introduced in grep-2.16]
+
+  grep -P now works with -w and -x and backreferences. Before,
+  echo aa|grep -Pw '(.)\1' would fail to match, yet
+  echo aa|grep -Pw '(.)\2' would match.
+
+  grep -Pw now works like grep -w in that the matched string has to be
+  preceded and followed by non-word components or the beginning and end
+  of the line (as opposed to word boundaries before).  Before, this
+  echo a@@a| grep -Pw @@ would match, yet this
+  echo a@@a| grep -w @@ would not.  Now, they both fail to match,
+  per the documentation on how grep's -w works.
+
+  grep -i no longer mishandles patterns containing titlecase characters.
+  For example, in a locale containing the titlecase character
+  'Lj' (U+01C8 LATIN CAPITAL LETTER L WITH SMALL LETTER J),
+  'grep -i Lj' now matches both 'LJ' (U+01C7 LATIN CAPITAL LETTER LJ)
+  and 'lj' (U+01C9 LATIN SMALL LETTER LJ).
+
+
+* 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
index 92a7fe2..880ea03 100644 (file)
@@ -1,6 +1,6 @@
 # generated automatically by aclocal 1.99a -*- Autoconf -*-
 
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
+# Copyright (C) 1996-2014 Free Software Foundation, Inc.
 
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69.112-f181],,
-[m4_warning([this file was generated for autoconf 2.69.112-f181.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69.117-1717],,
+[m4_warning([this file was generated for autoconf 2.69.117-1717.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
 
-# Copyright (C) 2002-2013 Free Software Foundation, Inc.
+# Copyright (C) 2002-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -58,7 +58,7 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -103,15 +103,14 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 # configured tree to be moved without reconfiguration.
 
 AC_DEFUN([AM_AUX_DIR_EXPAND],
-[dnl Rely on autoconf to set up CDPATH properly.
-AC_PREREQ([2.50])dnl
-# expand $ac_aux_dir to an absolute path
-am_aux_dir=`cd $ac_aux_dir && pwd`
+[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
+# Expand $ac_aux_dir to an absolute path.
+am_aux_dir=`cd "$ac_aux_dir" && pwd`
 ])
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
-# Copyright (C) 1997-2013 Free Software Foundation, Inc.
+# Copyright (C) 1997-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -142,7 +141,7 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Copyright (C) 1999-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -330,7 +329,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
-# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Copyright (C) 1999-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -406,7 +405,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 
 # Do all the work for Automake.                             -*- Autoconf -*-
 
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
+# Copyright (C) 1996-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -493,8 +492,8 @@ AM_MISSING_PROG([MAKEINFO], [makeinfo])
 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
-# We need awk for the "check" target.  The system "awk" is bad on
-# some platforms.
+# We need awk for the "check" target (and possibly the TAP driver).  The
+# system "awk" is bad on some platforms.
 AC_REQUIRE([AC_PROG_AWK])dnl
 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
@@ -595,7 +594,7 @@ for _am_header in $config_headers :; do
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -618,7 +617,7 @@ AC_SUBST([install_sh])])
 
 # Check to see how 'make' treats includes.                 -*- Autoconf -*-
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -668,7 +667,7 @@ rm -f confinc confmf
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
-# Copyright (C) 1997-2013 Free Software Foundation, Inc.
+# Copyright (C) 1997-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -707,7 +706,7 @@ fi
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -736,7 +735,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
 AC_DEFUN([_AM_IF_OPTION],
 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
-# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Copyright (C) 1999-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -783,7 +782,7 @@ AC_LANG_POP([C])])
 # For backward compatibility.
 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -802,7 +801,7 @@ AC_DEFUN([AM_RUN_LOG],
 
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
+# Copyright (C) 1996-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -883,7 +882,7 @@ AC_CONFIG_COMMANDS_PRE(
 rm -f conftest.file
 ])
 
-# Copyright (C) 2009-2013 Free Software Foundation, Inc.
+# Copyright (C) 2009-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -943,7 +942,7 @@ AC_SUBST([AM_BACKSLASH])dnl
 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
 ])
 
-# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+# Copyright (C) 2001-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -971,7 +970,7 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
-# Copyright (C) 2006-2013 Free Software Foundation, Inc.
+# Copyright (C) 2006-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -990,7 +989,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
 # Check how to create a tarball.                            -*- Autoconf -*-
 
-# Copyright (C) 2004-2013 Free Software Foundation, Inc.
+# Copyright (C) 2004-2014 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
index 531136b..a85b723 100755 (executable)
@@ -3,7 +3,7 @@
 
 scriptversion=2012-10-14.11; # UTC
 
-# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Copyright (C) 1999-2014 Free Software Foundation, Inc.
 # Written by Tom Tromey <tromey@cygnus.com>.
 #
 # This program is free software; you can redistribute it and/or modify
index 4438cd7..1f5c50c 100755 (executable)
@@ -2,7 +2,7 @@
 # Attempt to guess a canonical system name.
 #   Copyright 1992-2014 Free Software Foundation, Inc.
 
-timestamp='2014-01-01'
+timestamp='2014-03-23'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -149,7 +149,7 @@ Linux|GNU|GNU/*)
        LIBC=gnu
        #endif
        EOF
-       eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
+       eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
        ;;
 esac
 
@@ -826,7 +826,7 @@ EOF
     *:MINGW*:*)
        echo ${UNAME_MACHINE}-pc-mingw32
        exit ;;
-    i*:MSYS*:*)
+    *:MSYS*:*)
        echo ${UNAME_MACHINE}-pc-msys
        exit ;;
     i*:windows32*:*)
@@ -969,10 +969,10 @@ EOF
        eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
        test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; }
        ;;
-    or1k:Linux:*:*)
-       echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+    openrisc*:Linux:*:*)
+       echo or1k-unknown-linux-${LIBC}
        exit ;;
-    or32:Linux:*:*)
+    or32:Linux:*:* | or1k*:Linux:*:*)
        echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
        exit ;;
     padre:Linux:*:*)
@@ -1371,154 +1371,6 @@ EOF
        exit ;;
 esac
 
-eval $set_cc_for_build
-cat >$dummy.c <<EOF
-#ifdef _SEQUENT_
-# include <sys/types.h>
-# include <sys/utsname.h>
-#endif
-main ()
-{
-#if defined (sony)
-#if defined (MIPSEB)
-  /* BFD wants "bsd" instead of "newsos".  Perhaps BFD should be changed,
-     I don't know....  */
-  printf ("mips-sony-bsd\n"); exit (0);
-#else
-#include <sys/param.h>
-  printf ("m68k-sony-newsos%s\n",
-#ifdef NEWSOS4
-       "4"
-#else
-       ""
-#endif
-       ); exit (0);
-#endif
-#endif
-
-#if defined (__arm) && defined (__acorn) && defined (__unix)
-  printf ("arm-acorn-riscix\n"); exit (0);
-#endif
-
-#if defined (hp300) && !defined (hpux)
-  printf ("m68k-hp-bsd\n"); exit (0);
-#endif
-
-#if defined (NeXT)
-#if !defined (__ARCHITECTURE__)
-#define __ARCHITECTURE__ "m68k"
-#endif
-  int version;
-  version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
-  if (version < 4)
-    printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
-  else
-    printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
-  exit (0);
-#endif
-
-#if defined (MULTIMAX) || defined (n16)
-#if defined (UMAXV)
-  printf ("ns32k-encore-sysv\n"); exit (0);
-#else
-#if defined (CMU)
-  printf ("ns32k-encore-mach\n"); exit (0);
-#else
-  printf ("ns32k-encore-bsd\n"); exit (0);
-#endif
-#endif
-#endif
-
-#if defined (__386BSD__)
-  printf ("i386-pc-bsd\n"); exit (0);
-#endif
-
-#if defined (sequent)
-#if defined (i386)
-  printf ("i386-sequent-dynix\n"); exit (0);
-#endif
-#if defined (ns32000)
-  printf ("ns32k-sequent-dynix\n"); exit (0);
-#endif
-#endif
-
-#if defined (_SEQUENT_)
-    struct utsname un;
-
-    uname(&un);
-
-    if (strncmp(un.version, "V2", 2) == 0) {
-       printf ("i386-sequent-ptx2\n"); exit (0);
-    }
-    if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
-       printf ("i386-sequent-ptx1\n"); exit (0);
-    }
-    printf ("i386-sequent-ptx\n"); exit (0);
-
-#endif
-
-#if defined (vax)
-# if !defined (ultrix)
-#  include <sys/param.h>
-#  if defined (BSD)
-#   if BSD == 43
-      printf ("vax-dec-bsd4.3\n"); exit (0);
-#   else
-#    if BSD == 199006
-      printf ("vax-dec-bsd4.3reno\n"); exit (0);
-#    else
-      printf ("vax-dec-bsd\n"); exit (0);
-#    endif
-#   endif
-#  else
-    printf ("vax-dec-bsd\n"); exit (0);
-#  endif
-# else
-    printf ("vax-dec-ultrix\n"); exit (0);
-# endif
-#endif
-
-#if defined (alliant) && defined (i860)
-  printf ("i860-alliant-bsd\n"); exit (0);
-#endif
-
-  exit (1);
-}
-EOF
-
-$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
-       { echo "$SYSTEM_NAME"; exit; }
-
-# Apollos put the system type in the environment.
-
-test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
-
-# Convex versions that predate uname can use getsysinfo(1)
-
-if [ -x /usr/convex/getsysinfo ]
-then
-    case `getsysinfo -f cpu_type` in
-    c1*)
-       echo c1-convex-bsd
-       exit ;;
-    c2*)
-       if getsysinfo -f scalar_acc
-       then echo c32-convex-bsd
-       else echo c2-convex-bsd
-       fi
-       exit ;;
-    c34*)
-       echo c34-convex-bsd
-       exit ;;
-    c38*)
-       echo c38-convex-bsd
-       exit ;;
-    c4*)
-       echo c4-convex-bsd
-       exit ;;
-    esac
-fi
-
 cat >&2 <<EOF
 $0: unable to guess system type
 
index 092cff0..d654d03 100755 (executable)
@@ -2,7 +2,7 @@
 # Configuration validation subroutine script.
 #   Copyright 1992-2014 Free Software Foundation, Inc.
 
-timestamp='2014-01-01'
+timestamp='2014-05-01'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -283,8 +283,10 @@ case $basic_machine in
        | mips64vr5900 | mips64vr5900el \
        | mipsisa32 | mipsisa32el \
        | mipsisa32r2 | mipsisa32r2el \
+       | mipsisa32r6 | mipsisa32r6el \
        | mipsisa64 | mipsisa64el \
        | mipsisa64r2 | mipsisa64r2el \
+       | mipsisa64r6 | mipsisa64r6el \
        | mipsisa64sb1 | mipsisa64sb1el \
        | mipsisa64sr71k | mipsisa64sr71kel \
        | mipsr5900 | mipsr5900el \
@@ -296,8 +298,7 @@ case $basic_machine in
        | nds32 | nds32le | nds32be \
        | nios | nios2 | nios2eb | nios2el \
        | ns16k | ns32k \
-       | open8 \
-       | or1k | or32 \
+       | open8 | or1k | or1knd | or32 \
        | pdp10 | pdp11 | pj | pjl \
        | powerpc | powerpc64 | powerpc64le | powerpcle \
        | pyramid \
@@ -402,8 +403,10 @@ case $basic_machine in
        | mips64vr5900-* | mips64vr5900el-* \
        | mipsisa32-* | mipsisa32el-* \
        | mipsisa32r2-* | mipsisa32r2el-* \
+       | mipsisa32r6-* | mipsisa32r6el-* \
        | mipsisa64-* | mipsisa64el-* \
        | mipsisa64r2-* | mipsisa64r2el-* \
+       | mipsisa64r6-* | mipsisa64r6el-* \
        | mipsisa64sb1-* | mipsisa64sb1el-* \
        | mipsisa64sr71k-* | mipsisa64sr71kel-* \
        | mipsr5900-* | mipsr5900el-* \
@@ -415,6 +418,7 @@ case $basic_machine in
        | nios-* | nios2-* | nios2eb-* | nios2el-* \
        | none-* | np1-* | ns16k-* | ns32k-* \
        | open8-* \
+       | or1k*-* \
        | orion-* \
        | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
        | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
@@ -1376,7 +1380,7 @@ case $os in
              | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
              | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
              | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
-             | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
+             | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* | -tirtos*)
        # Remember, each alternative MUST END IN *, to match a version number.
                ;;
        -qnx*)
@@ -1594,9 +1598,6 @@ case $basic_machine in
        mips*-*)
                os=-elf
                ;;
-       or1k-*)
-               os=-elf
-               ;;
        or32-*)
                os=-coff
                ;;
index f9ec9df..b2e7b09 100755 (executable)
@@ -2,7 +2,7 @@
 # gendocs.sh -- generate a GNU manual in many formats.  This script is
 #   mentioned in maintain.texi.  See the help message below for usage details.
 
-scriptversion=2013-10-10.09
+scriptversion=2014-05-01.10
 
 # Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013
 # Free Software Foundation, Inc.
@@ -78,6 +78,9 @@ Options:
   --html ARG   pass ARG to makeinfo or texi2html for HTML targets.
   --info ARG   pass ARG to makeinfo for Info, instead of --no-split.
   --no-ascii   skip generating the plain text output.
+  --no-html    skip generating the html output.
+  --no-info    skip generating the info output.
+  --no-tex     skip generating the dvi and pdf output.
   --source ARG include ARG in tar archive of sources.
   --split HOW  make split HTML by node, section, chapter; default node.
 
@@ -139,10 +142,13 @@ PACKAGE=
 EMAIL=webmasters@gnu.org  # please override with --email
 commonarg= # passed to all makeinfo/texi2html invcations.
 dirargs=   # passed to all tools (-I dir).
-dirs=      # -I's directories.
+dirs=      # -I directories.
 htmlarg=
 infoarg=--no-split
 generate_ascii=true
+generate_html=true
+generate_info=true
+generate_tex=true
 outdir=manual
 source_extra=
 split=node
@@ -159,6 +165,9 @@ while test $# -gt 0; do
     --html)      shift; htmlarg=$1;;
     --info)      shift; infoarg=$1;;
     --no-ascii)  generate_ascii=false;;
+    --no-html)   generate_ascii=false;;
+    --no-info)   generate_info=false;;
+    --no-tex)    generate_tex=false;;
     --source)    shift; source_extra=$1;;
     --split)     shift; split=$1;;
     --texi2html) use_texi2html=1;;
@@ -221,8 +230,9 @@ calcsize()
 
 # copy_images OUTDIR HTML-FILE...
 # -------------------------------
-# Copy all the images needed by the HTML-FILEs into OUTDIR.  Look
-# for them in the -I directories.
+# Copy all the images needed by the HTML-FILEs into OUTDIR.
+# Look for them in . and the -I directories; this is simpler than what
+# makeinfo supports with -I, but hopefully it will suffice.
 copy_images()
 {
   local odir
@@ -232,7 +242,7 @@ copy_images()
 BEGIN {
   \$me = '$prog';
   \$odir = '$odir';
-  @dirs = qw($dirs);
+  @dirs = qw($dirs);
 }
 " -e '
 /<img src="(.*?)"/g && ++$need{$1};
@@ -270,32 +280,39 @@ echo "Making output for $srcfile"
 echo " in `pwd`"
 mkdir -p "$outdir/"
 
-cmd="$SETLANG $MAKEINFO -o $PACKAGE.info $commonarg $infoarg \"$srcfile\""
-echo "Generating info... ($cmd)"
-rm -f $PACKAGE.info* # get rid of any strays
-eval "$cmd"
-tar czf "$outdir/$PACKAGE.info.tar.gz" $PACKAGE.info*
-ls -l "$outdir/$PACKAGE.info.tar.gz"
-info_tgz_size=`calcsize "$outdir/$PACKAGE.info.tar.gz"`
-# do not mv the info files, there's no point in having them available
-# separately on the web.
-
-cmd="$SETLANG $TEXI2DVI $dirargs \"$srcfile\""
-printf "\nGenerating dvi... ($cmd)\n"
-eval "$cmd"
-# compress/finish dvi:
-gzip -f -9 $PACKAGE.dvi
-dvi_gz_size=`calcsize $PACKAGE.dvi.gz`
-mv $PACKAGE.dvi.gz "$outdir/"
-ls -l "$outdir/$PACKAGE.dvi.gz"
-
-cmd="$SETLANG $TEXI2DVI --pdf $dirargs \"$srcfile\""
-printf "\nGenerating pdf... ($cmd)\n"
-eval "$cmd"
-pdf_size=`calcsize $PACKAGE.pdf`
-mv $PACKAGE.pdf "$outdir/"
-ls -l "$outdir/$PACKAGE.pdf"
+# \f
+if $generate_info; then
+  cmd="$SETLANG $MAKEINFO -o $PACKAGE.info $commonarg $infoarg \"$srcfile\""
+  echo "Generating info... ($cmd)"
+  rm -f $PACKAGE.info* # get rid of any strays
+  eval "$cmd"
+  tar czf "$outdir/$PACKAGE.info.tar.gz" $PACKAGE.info*
+  ls -l "$outdir/$PACKAGE.info.tar.gz"
+  info_tgz_size=`calcsize "$outdir/$PACKAGE.info.tar.gz"`
+  # do not mv the info files, there's no point in having them available
+  # separately on the web.
+fi  # end info
+
+# \f
+if $generate_tex; then
+  cmd="$SETLANG $TEXI2DVI $dirargs \"$srcfile\""
+  printf "\nGenerating dvi... ($cmd)\n"
+  eval "$cmd"
+  # compress/finish dvi:
+  gzip -f -9 $PACKAGE.dvi
+  dvi_gz_size=`calcsize $PACKAGE.dvi.gz`
+  mv $PACKAGE.dvi.gz "$outdir/"
+  ls -l "$outdir/$PACKAGE.dvi.gz"
+
+  cmd="$SETLANG $TEXI2DVI --pdf $dirargs \"$srcfile\""
+  printf "\nGenerating pdf... ($cmd)\n"
+  eval "$cmd"
+  pdf_size=`calcsize $PACKAGE.pdf`
+  mv $PACKAGE.pdf "$outdir/"
+  ls -l "$outdir/$PACKAGE.pdf"
+fi # end tex (dvi + pdf)
 
+# \f
 if $generate_ascii; then
   opt="-o $PACKAGE.txt --no-split --no-headers $commonarg"
   cmd="$SETLANG $MAKEINFO $opt \"$srcfile\""
@@ -308,6 +325,9 @@ if $generate_ascii; then
   ls -l "$outdir/$PACKAGE.txt" "$outdir/$PACKAGE.txt.gz"
 fi
 
+# \f
+
+if $generate_html; then
 # Split HTML at level $1.  Used for texi2html.
 html_split()
 {
@@ -382,7 +402,9 @@ else # use texi2html:
   html_split chapter
   html_split section
 fi
+fi # end html
 
+# \f
 printf "\nMaking .tar.gz for sources...\n"
 d=`dirname $srcfile`
 (
@@ -393,6 +415,8 @@ d=`dirname $srcfile`
 )
 texi_tgz_size=`calcsize "$outdir/$PACKAGE.texi.tar.gz"`
 
+# \f
+# Do everything again through docbook.
 if test -n "$docbook"; then
   opt="-o - --docbook $commonarg"
   cmd="$SETLANG $MAKEINFO $opt \"$srcfile\" >${srcdir}/$PACKAGE-db.xml"
@@ -431,7 +455,8 @@ if test -n "$docbook"; then
   mv $PACKAGE-db.pdf "$outdir/"
 fi
 
-printf "\nMaking index file...\n"
+# \f
+printf "\nMaking index.html for $PACKAGE...\n"
 if test -z "$use_texi2html"; then
   CONDS="/%%IF  *HTML_SECTION%%/,/%%ENDIF  *HTML_SECTION%%/d;\
          /%%IF  *HTML_CHAPTER%%/,/%%ENDIF  *HTML_CHAPTER%%/d"
index 0436737..0b0fdcb 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/sh
 # install - install a program, script, or datafile
 
-scriptversion=2013-10-30.23; # UTC
+scriptversion=2013-12-25.23; # UTC
 
 # This originates from X11R5 (mit/util/scripts/install.sh), which was
 # later released in X11R6 (xc/config/util/install.sh) with the
@@ -82,7 +82,7 @@ dir_arg=
 dst_arg=
 
 copy_on_change=false
-no_target_directory=
+is_target_a_directory=possibly
 
 usage="\
 Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
@@ -139,14 +139,16 @@ while test $# -ne 0; do
 
     -s) stripcmd=$stripprog;;
 
-    -t) dst_arg=$2
+    -t)
+        is_target_a_directory=always
+        dst_arg=$2
         # Protect names problematic for 'test' and other utilities.
         case $dst_arg in
           -* | [=\(\)!]) dst_arg=./$dst_arg;;
         esac
         shift;;
 
-    -T) no_target_directory=true;;
+    -T) is_target_a_directory=never;;
 
     --version) echo "$0 $scriptversion"; exit $?;;
 
@@ -161,6 +163,16 @@ while test $# -ne 0; do
   shift
 done
 
+# We allow the use of options -d and -T together, by making -d
+# take the precedence; this is for compatibility with GNU install.
+
+if test -n "$dir_arg"; then
+  if test -n "$dst_arg"; then
+    echo "$0: target directory not allowed when installing a directory." >&2
+    exit 1
+  fi
+fi
+
 if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
   # When -d is used, all remaining arguments are directories to create.
   # When -t is used, the destination is already specified.
@@ -192,6 +204,15 @@ if test $# -eq 0; then
 fi
 
 if test -z "$dir_arg"; then
+  if test $# -gt 1 || test "$is_target_a_directory" = always; then
+    if test ! -d "$dst_arg"; then
+      echo "$0: $dst_arg: Is not a directory." >&2
+      exit 1
+    fi
+  fi
+fi
+
+if test -z "$dir_arg"; then
   do_exit='(exit $ret); exit $ret'
   trap "ret=129; $do_exit" 1
   trap "ret=130; $do_exit" 2
@@ -253,7 +274,7 @@ do
     # If destination is a directory, append the input filename; won't work
     # if double slashes aren't ignored.
     if test -d "$dst"; then
-      if test -n "$no_target_directory"; then
+      if test "$is_target_a_directory" = never; then
         echo "$0: $dst_arg: Is a directory" >&2
         exit 1
       fi
index cdea514..f62bbae 100755 (executable)
@@ -1,9 +1,9 @@
 #! /bin/sh
 # Common wrapper for a few potentially missing GNU programs.
 
-scriptversion=2012-06-26.16; # UTC
+scriptversion=2013-10-28.13; # UTC
 
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
+# Copyright (C) 1996-2014 Free Software Foundation, Inc.
 # Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
 
 # This program is free software; you can redistribute it and/or modify
@@ -160,7 +160,7 @@ give_advice ()
       ;;
    autom4te*)
       echo "You might have modified some maintainer files that require"
-      echo "the 'automa4te' program to be rebuilt."
+      echo "the 'autom4te' program to be rebuilt."
       program_details 'autom4te'
       ;;
     bison*|yacc*)
index 32bf39e..8e575b0 100755 (executable)
@@ -1,9 +1,9 @@
 #! /bin/sh
 # test-driver - basic testsuite driver script.
 
-scriptversion=2012-06-27.10; # UTC
+scriptversion=2013-07-13.22; # UTC
 
-# Copyright (C) 2011-2013 Free Software Foundation, Inc.
+# Copyright (C) 2011-2014 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -44,13 +44,12 @@ print_usage ()
 Usage:
   test-driver --test-name=NAME --log-file=PATH --trs-file=PATH
               [--expect-failure={yes|no}] [--color-tests={yes|no}]
-              [--enable-hard-errors={yes|no}] [--] TEST-SCRIPT
+              [--enable-hard-errors={yes|no}] [--]
+              TEST-SCRIPT [TEST-SCRIPT-ARGUMENTS]
 The '--test-name', '--log-file' and '--trs-file' options are mandatory.
 END
 }
 
-# TODO: better error handling in option parsing (in particular, ensure
-# TODO: $log_file, $trs_file and $test_name are defined).
 test_name= # Used for reporting.
 log_file=  # Where to save the output of the test script.
 trs_file=  # Where to save the metadata of the test run.
@@ -69,10 +68,23 @@ while test $# -gt 0; do
   --enable-hard-errors) enable_hard_errors=$2; shift;;
   --) shift; break;;
   -*) usage_error "invalid option: '$1'";;
+   *) break;;
   esac
   shift
 done
 
+missing_opts=
+test x"$test_name" = x && missing_opts="$missing_opts --test-name"
+test x"$log_file"  = x && missing_opts="$missing_opts --log-file"
+test x"$trs_file"  = x && missing_opts="$missing_opts --trs-file"
+if test x"$missing_opts" != x; then
+  usage_error "the following mandatory options are missing:$missing_opts"
+fi
+
+if test $# -eq 0; then
+  usage_error "missing argument"
+fi
+
 if test $color_tests = yes; then
   # Keep this in sync with 'lib/am/check.am:$(am__tty_colors)'.
   red='\e[0;31m' # Red.
@@ -94,11 +106,14 @@ trap "st=143; $do_exit" 15
 # Test script is run here.
 "$@" >$log_file 2>&1
 estatus=$?
+
 if test $enable_hard_errors = no && test $estatus -eq 99; then
-  estatus=1
+  tweaked_estatus=1
+else
+  tweaked_estatus=$estatus
 fi
 
-case $estatus:$expect_failure in
+case $tweaked_estatus:$expect_failure in
   0:yes) col=$red res=XPASS recheck=yes gcopy=yes;;
   0:*)   col=$grn res=PASS  recheck=no  gcopy=no;;
   77:*)  col=$blu res=SKIP  recheck=no  gcopy=yes;;
@@ -107,6 +122,12 @@ case $estatus:$expect_failure in
   *:*)   col=$red res=FAIL  recheck=yes gcopy=yes;;
 esac
 
+# Report the test outcome and exit status in the logs, so that one can
+# know whether the test passed or failed simply by looking at the '.log'
+# file, without the need of also peaking into the corresponding '.trs'
+# file (automake bug#11814).
+echo "$res $test_name (exit status: $estatus)" >>$log_file
+
 # Report outcome to console.
 echo "${col}${res}${std}: $test_name"
 
index bfd765d..cfb5c56 100644 (file)
@@ -3,11 +3,11 @@
 % Load plain if necessary, i.e., if running under initex.
 \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
 %
-\def\texinfoversion{2013-09-11.11}
+\def\texinfoversion{2014-05-05.10}
 %
 % Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
 % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-% 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+% 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 %
 % This texinfo.tex file is free software: you can redistribute it and/or
 % modify it under the terms of the GNU General Public License as
@@ -1138,10 +1138,12 @@ output) for that.)}
 
 \ifpdf
   %
-  % Color manipulation macros based on pdfcolor.tex,
+  % Color manipulation macros using ideas from pdfcolor.tex,
   % except using rgb instead of cmyk; the latter is said to render as a
   % very dark gray on-screen and a very dark halftone in print, instead
-  % of actual black.
+  % of actual black. The dark red here is dark enough to print on paper as
+  % nearly black, but still distinguishable for online viewing.  We use
+  % black by default, though.
   \def\rgbDarkRed{0.50 0.09 0.12}
   \def\rgbBlack{0 0 0}
   %
@@ -1251,10 +1253,9 @@ output) for that.)}
   % used to mark target names; must be expandable.
   \def\pdfmkpgn#1{#1}
   %
-  % by default, use a color that is dark enough to print on paper as
-  % nearly black, but still distinguishable for online viewing.
-  \def\urlcolor{\rgbDarkRed}
-  \def\linkcolor{\rgbDarkRed}
+  % by default, use black for everything.
+  \def\urlcolor{\rgbBlack}
+  \def\linkcolor{\rgbBlack}
   \def\endlink{\setcolor{\maincolor}\pdfendlink}
   %
   % Adding outlines to PDF; macros for calculating structure of outlines
@@ -2145,7 +2146,7 @@ end
   \let\tenttsl=\secttsl
   \def\curfontsize{sec}%
   \def\lsize{subsec}\def\lllsize{reduced}%
-  \resetmathfonts \setleading{16pt}}
+  \resetmathfonts \setleading{17pt}}
 \def\subsecfonts{%
   \let\tenrm=\ssecrm \let\tenit=\ssecit \let\tensl=\ssecsl
   \let\tenbf=\ssecbf \let\tentt=\ssectt \let\smallcaps=\ssecsc
@@ -2574,37 +2575,21 @@ end
 \let\file=\code
 \let\option=\code
 
-% @uref (abbreviation for `urlref') takes an optional (comma-separated)
-% second argument specifying the text to display and an optional third
-% arg as text to display instead of (rather than in addition to) the url
-% itself.  First (mandatory) arg is the url.
-% (This \urefnobreak definition isn't used now, leaving it for a while
-% for comparison.)
-\def\urefnobreak#1{\dourefnobreak #1,,,\finish}
-\def\dourefnobreak#1,#2,#3,#4\finish{\begingroup
-  \unsepspaces
-  \pdfurl{#1}%
-  \setbox0 = \hbox{\ignorespaces #3}%
-  \ifdim\wd0 > 0pt
-    \unhbox0 % third arg given, show only that
-  \else
-    \setbox0 = \hbox{\ignorespaces #2}%
-    \ifdim\wd0 > 0pt
-      \ifpdf
-        \unhbox0             % PDF: 2nd arg given, show only it
-      \else
-        \unhbox0\ (\code{#1})% DVI: 2nd arg given, show both it and url
-      \fi
-    \else
-      \code{#1}% only url given, so show it
-    \fi
-  \fi
-  \endlink
-\endgroup}
+% @uref (abbreviation for `urlref') aka @url takes an optional
+% (comma-separated) second argument specifying the text to display and
+% an optional third arg as text to display instead of (rather than in
+% addition to) the url itself.  First (mandatory) arg is the url.
+
+% TeX-only option to allow changing PDF output to show only the second
+% arg (if given), and not the url (which is then just the link target).
+\newif\ifurefurlonlylink
 
-% This \urefbreak definition is the active one.
+% The main macro is \urefbreak, which allows breaking at expected
+% places within the url.  (There used to be another version, which
+% didn't support automatic breaking.)
 \def\urefbreak{\begingroup \urefcatcodes \dourefbreak}
 \let\uref=\urefbreak
+%
 \def\dourefbreak#1{\urefbreakfinish #1,,,\finish}
 \def\urefbreakfinish#1,#2,#3,#4\finish{% doesn't work in @example
   \unsepspaces
@@ -2613,12 +2598,19 @@ end
   \ifdim\wd0 > 0pt
     \unhbox0 % third arg given, show only that
   \else
-    \setbox0 = \hbox{\ignorespaces #2}%
+    \setbox0 = \hbox{\ignorespaces #2}% look for second arg
     \ifdim\wd0 > 0pt
       \ifpdf
-        \unhbox0             % PDF: 2nd arg given, show only it
+        \ifurefurlonlylink
+          % PDF plus option to not display url, show just arg
+          \unhbox0             
+        \else
+          % PDF, normally display both arg and url for consistency,
+          % visibility, if the pdf is eventually used to print, etc.
+          \unhbox0\ (\urefcode{#1})%
+        \fi
       \else
-        \unhbox0\ (\urefcode{#1})% DVI: 2nd arg given, show both it and url
+        \unhbox0\ (\urefcode{#1})% DVI, always show arg and url
       \fi
     \else
       \urefcode{#1}% only url given, so show it
@@ -2658,8 +2650,10 @@ end
 % we put a little stretch before and after the breakable chars, to help
 % line breaking of long url's.  The unequal skips make look better in
 % cmtt at least, especially for dots.
-\def\urefprestretch{\urefprebreak \hskip0pt plus.13em }
-\def\urefpoststretch{\urefpostbreak \hskip0pt plus.1em }
+\def\urefprestretchamount{.13em}
+\def\urefpoststretchamount{.1em}
+\def\urefprestretch{\urefprebreak \hskip0pt plus\urefprestretchamount\relax}
+\def\urefpoststretch{\urefpostbreak \hskip0pt plus\urefprestretchamount\relax}
 %
 \def\urefcodeamp{\urefprestretch \&\urefpoststretch}
 \def\urefcodedot{\urefprestretch .\urefpoststretch}
@@ -3691,7 +3685,7 @@ end
   \parskip=\smallskipamount
   \ifdim\parskip=0pt \parskip=2pt \fi
   %
-  % Try typesetting the item mark that if the document erroneously says
+  % Try typesetting the item mark so that if the document erroneously says
   % something like @itemize @samp (intending @table), there's an error
   % right away at the @itemize.  It's not the best error message in the
   % world, but it's better than leaving it to the @item.  This means if
@@ -3941,19 +3935,23 @@ end
 }
 
 % multitable-only commands.
-%
-% @headitem starts a heading row, which we typeset in bold.
-% Assignments have to be global since we are inside the implicit group
-% of an alignment entry.  \everycr resets \everytab so we don't have to
+% 
+% @headitem starts a heading row, which we typeset in bold.  Assignments
+% have to be global since we are inside the implicit group of an
+% alignment entry.  \everycr below resets \everytab so we don't have to
 % undo it ourselves.
 \def\headitemfont{\b}% for people to use in the template row; not changeable
 \def\headitem{%
   \checkenv\multitable
   \crcr
+  \gdef\headitemcrhook{\nobreak}% attempt to avoid page break after headings
   \global\everytab={\bf}% can't use \headitemfont since the parsing differs
   \the\everytab % for the first item
 }%
 %
+% default for tables with no headings.
+\let\headitemcrhook=\relax
+%
 % A \tab used to include \hskip1sp.  But then the space in a template
 % line is not enough.  That is bad.  So let's go back to just `&' until
 % we again encounter the problem the 1sp was intended to solve.
@@ -3984,15 +3982,15 @@ end
   %
   \everycr = {%
     \noalign{%
-      \global\everytab={}%
+      \global\everytab={}% Reset from possible headitem.
       \global\colcount=0 % Reset the column counter.
-      % Check for saved footnotes, etc.
+      %
+      % Check for saved footnotes, etc.:
       \checkinserts
-      % Keeps underfull box messages off when table breaks over pages.
-      %\filbreak
-       % Maybe so, but it also creates really weird page breaks when the
-       % table breaks over pages. Wouldn't \vfil be better?  Wait until the
-       % problem manifests itself, so it can be fixed for real --karl.
+      %
+      % Perhaps a \nobreak, then reset:
+      \headitemcrhook
+      \global\let\headitemcrhook=\relax
     }%
   }%
   %
@@ -4434,7 +4432,7 @@ end
   % complicated, when \tex is in effect and \{ is a \delimiter again.
   % We can't use \lbracecmd and \rbracecmd because texindex assumes
   % braces and backslashes are used only as delimiters.  Perhaps we
-  % should define @lbrace and @rbrace commands a la @comma.
+  % should use @lbracechar and @rbracechar?
   \def\{{{\tt\char123}}%
   \def\}{{\tt\char125}}%
   %
@@ -4455,8 +4453,7 @@ end
   % @end macro
   % ...
   % @funindex commtest
-  %
-  % The above is not enough to reproduce the bug, but it gives the flavor.
+  % This is not enough to reproduce the bug, but it gives the flavor.
   %
   % Sample whatsit resulting:
   % .@write3{\entry{xyz}{@folio }{@code {xyz@endinput }}}
@@ -4657,8 +4654,21 @@ end
   \definedummyword\verb
   \definedummyword\w
   \definedummyword\xref
+  %
+  % Consider:
+  %   @macro mkind{arg1,arg2}
+  %   @cindex \arg2\
+  %   @end macro
+  %   @mkind{foo, bar}
+  % The space after the comma will end up in the temporary definition
+  % that we make for arg2 (see \parsemargdef ff.).  We want all this to be
+  % expanded for the sake of the index, so we end up just seeing "bar".
+  \let\xeatspaces = \eatspaces
 }
 
+% For testing: output @{ and @} in index sort strings as \{ and \}.
+\newif\ifusebracesinindexes
+
 % \indexnofonts is used when outputting the strings to sort the index
 % by, and when constructing control sequence names.  It eliminates all
 % control sequences and just writes whatever the best ASCII sort string
@@ -4687,11 +4697,16 @@ end
   % Unfortunately, texindex is not prepared to handle braces in the
   % content at all.  So for index sorting, we map @{ and @} to strings
   % starting with |, since that ASCII character is between ASCII { and }.
-  \def\{{|a}%
-  \def\lbracechar{|a}%
+  \ifusebracesinindexes
+    \def\lbracechar{\lbracecmd}%
+    \def\rbracechar{\rbracecmd}%
+  \else
+    \def\lbracechar{|a}%
+    \def\rbracechar{|b}%
+  \fi
+  \let\{=\lbracechar
+  \let\}=\rbracechar
   %
-  \def\}{|b}%
-  \def\rbracechar{|b}%
   %
   % Non-English letters.
   \def\AA{AA}%
@@ -6419,8 +6434,6 @@ end
                                % side, and for 6pt waste from
                                % each corner char, and rule thickness
   \normbskip=\baselineskip \normpskip=\parskip \normlskip=\lineskip
-  % Flag to tell @lisp, etc., not to narrow margin.
-  \let\nonarrowing = t%
   %
   % If this cartouche directly follows a sectioning command, we need the
   % \parskip glue (backspaced over by default) or the cartouche can
@@ -6587,9 +6600,13 @@ end
 
 
 % @raggedright does more-or-less normal line breaking but no right
-% justification.  From plain.tex.
+% justification.  From plain.tex.  Don't stretch around special
+% characters in urls in this environment, since the stretch at the right
+% should be enough.
 \envdef\raggedright{%
-  \rightskip0pt plus2em \spaceskip.3333em \xspaceskip.5em\relax
+  \rightskip0pt plus2.4em \spaceskip.3333em \xspaceskip.5em\relax
+  \def\urefprestretchamount{0pt}%
+  \def\urefpoststretchamount{0pt}%
 }
 \let\Eraggedright\par
 
@@ -7482,7 +7499,7 @@ end
 
 % Parse the optional {params} list.  Set up \paramno and \paramlist
 % so \defmacro knows what to do.  Define \macarg.BLAH for each BLAH
-% in the params list to some hook where the argument si to be expanded.  If
+% in the params list to some hook where the argument is to be expanded.  If
 % there are less than 10 arguments that hook is to be replaced by ##N where N
 % is the position in that list, that is to say the macro arguments are to be
 % defined `a la TeX in the macro body.  
@@ -8344,6 +8361,7 @@ end
 \gdef\footnote{%
   \let\indent=\ptexindent
   \let\noindent=\ptexnoindent
+  %
   \global\advance\footnoteno by \@ne
   \edef\thisfootno{$^{\the\footnoteno}$}%
   %
@@ -8367,6 +8385,11 @@ end
 %
 \gdef\dofootnote{%
   \insert\footins\bgroup
+  %
+  % Nested footnotes are not supported in TeX, that would take a lot
+  % more work.  (\startsavinginserts does not suffice.)
+  \let\footnote=\errfootnote
+  %
   % We want to typeset this text as a normal paragraph, even if the
   % footnote reference occurs in (for example) a display environment.
   % So reset some parameters.
@@ -8404,13 +8427,19 @@ end
 }
 }%end \catcode `\@=11
 
+\def\errfootnote{%
+  \errhelp=\EMsimple
+  \errmessage{Nested footnotes not supported in texinfo.tex,
+    even though they work in makeinfo; sorry}
+}
+
 % In case a @footnote appears in a vbox, save the footnote text and create
 % the real \insert just after the vbox finished.  Otherwise, the insertion
 % would be lost.
 % Similarly, if a @footnote appears inside an alignment, save the footnote
 % text to a box and make the \insert when a row of the table is finished.
 % And the same can be done for other insert classes.  --kasal, 16nov03.
-
+%
 % Replace the \insert primitive by a cheating macro.
 % Deeper inside, just make sure that the saved insertions are not spilled
 % out prematurely.
diff --git a/cfg.mk b/cfg.mk
index 8b77705..0a68c7d 100644 (file)
--- a/cfg.mk
+++ b/cfg.mk
@@ -51,7 +51,7 @@ export VERBOSE = yes
 # 1127556 9e
 export XZ_OPT = -6e
 
-old_NEWS_hash = 6b8be8ef5a7ad6246be2a5eda617962e
+old_NEWS_hash = cf462898af132251fed0f8d38c8c02c2
 
 # Many m4 macros names once began with 'jm_'.
 # Make sure that none are inadvertently reintroduced.
@@ -86,7 +86,8 @@ exclude_file_name_regexp--sc_bindtextdomain = ^tests/get-mb-cur-max\.c$$
 exclude_file_name_regexp--sc_prohibit_strcmp = /colorize-.*\.c$$
 exclude_file_name_regexp--sc_prohibit_xalloc_without_use = ^src/kwset\.c$$
 exclude_file_name_regexp--sc_prohibit_tab_based_indentation = \
-  (Makefile|\.(am|mk)$$|^gl/lib/.*\.c\.diff$$)
-exclude_file_name_regexp--sc_space_tab = ^gl/lib/.*\.c\.diff$$
+  (Makefile|\.(am|mk)$$)
 exclude_file_name_regexp--sc_error_message_uppercase = ^src/dfa\.c$$
 exclude_file_name_regexp--sc_prohibit_strncpy = ^src/dfa\.c$$
+
+exclude_file_name_regexp--sc_prohibit_doubled_word = ^tests/count-newline$$
index 206986b..1230615 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,11 +1,11 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69.112-f181 for GNU grep 2.16.
+# Generated by GNU Autoconf 2.69.117-1717 for GNU grep 2.19.
 #
 # Report bugs to <bug-grep@gnu.org>.
 #
 #
-# Copyright (C) 1992-1996, 1998-2013 Free Software Foundation, Inc.
+# Copyright (C) 1992-1996, 1998-2014 Free Software Foundation, Inc.
 #
 #
 # This configure script is free software; the Free Software Foundation
@@ -553,8 +553,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='GNU grep'
 PACKAGE_TARNAME='grep'
-PACKAGE_VERSION='2.16'
-PACKAGE_STRING='GNU grep 2.16'
+PACKAGE_VERSION='2.19'
+PACKAGE_STRING='GNU grep 2.19'
 PACKAGE_BUGREPORT='bug-grep@gnu.org'
 PACKAGE_URL='http://www.gnu.org/software/grep/'
 
@@ -936,6 +936,7 @@ GNULIB_CANONICALIZE_FILE_NAME
 GNULIB_CALLOC_POSIX
 GNULIB_ATOLL
 GNULIB__EXIT
+SED
 WINDOWS_64_BIT_OFF_T
 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
 NEXT_SYS_TYPES_H
@@ -2055,7 +2056,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures GNU grep 2.16 to adapt to many kinds of systems.
+\`configure' configures GNU grep 2.19 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -2126,7 +2127,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of GNU grep 2.16:";;
+     short | recursive ) echo "Configuration of GNU grep 2.19:";;
    esac
   cat <<\_ACEOF
 
@@ -2246,10 +2247,10 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-GNU grep configure 2.16
-generated by GNU Autoconf 2.69.112-f181
+GNU grep configure 2.19
+generated by GNU Autoconf 2.69.117-1717
 
-Copyright (C) 2013 Free Software Foundation, Inc.
+Copyright (C) 2014 Free Software Foundation, Inc.
 This configure script is free software; the Free Software Foundation
 gives unlimited permission to copy, distribute and modify it.
 _ACEOF
@@ -2383,7 +2384,7 @@ else
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 if (sizeof ($2))
         return 0;
@@ -2396,7 +2397,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 if (sizeof (($2)))
            return 0;
@@ -2504,7 +2505,7 @@ choke me
 #endif
 
 int
-main ()
+main (void)
 {
 return $2 ();
   ;
@@ -2586,7 +2587,7 @@ else
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 #ifndef $as_decl_name
 #ifdef __cplusplus
@@ -2628,7 +2629,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 static int test_array [1 - 2 * !(($2) >= 0)];
 test_array [0] = 0;
@@ -2645,7 +2646,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
 test_array [0] = 0;
@@ -2672,7 +2673,7 @@ else
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 static int test_array [1 - 2 * !(($2) < 0)];
 test_array [0] = 0;
@@ -2689,7 +2690,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
 test_array [0] = 0;
@@ -2724,7 +2725,7 @@ while test "x$ac_lo" != "x$ac_hi"; do
 /* end confdefs.h.  */
 $4
 int
-main ()
+main (void)
 {
 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
 test_array [0] = 0;
@@ -2754,7 +2755,7 @@ static unsigned long int ulongval () { return $2; }
 #include <stdio.h>
 #include <stdlib.h>
 int
-main ()
+main (void)
 {
 
   FILE *f = fopen ("conftest.val", "w");
@@ -2813,7 +2814,7 @@ else
 /* end confdefs.h.  */
 $5
 int
-main ()
+main (void)
 {
 static $2 ac_aggr;
 if (ac_aggr.$3)
@@ -2829,7 +2830,7 @@ else
 /* end confdefs.h.  */
 $5
 int
-main ()
+main (void)
 {
 static $2 ac_aggr;
 if (sizeof ac_aggr.$3)
@@ -2857,8 +2858,8 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by GNU grep $as_me 2.16, which was
-generated by GNU Autoconf 2.69.112-f181.  Invocation command line was
+It was created by GNU grep $as_me 2.19, which was
+generated by GNU Autoconf 2.69.117-1717.  Invocation command line was
 
   $ $0 $@
 
@@ -3531,8 +3532,8 @@ test "$program_suffix" != NONE &&
 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
 program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"`
 
-# expand $ac_aux_dir to an absolute path
-am_aux_dir=`cd $ac_aux_dir && pwd`
+# Expand $ac_aux_dir to an absolute path.
+am_aux_dir=`cd "$ac_aux_dir" && pwd`
 
 if test x"${MISSING+set}" != xset; then
   case $am_aux_dir in
@@ -3853,7 +3854,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='grep'
- VERSION='2.16'
+ VERSION='2.19'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3881,8 +3882,8 @@ AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
 
 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
 
-# We need awk for the "check" target.  The system "awk" is bad on
-# some platforms.
+# We need awk for the "check" target (and possibly the TAP driver).  The
+# system "awk" is bad on some platforms.
 # Always define AMTAR for backward compatibility.  Yes, it's still used
 # in the wild :-(  We should find a proper way to deprecate it ...
 AMTAR='$${TAR-tar}'
@@ -4456,7 +4457,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -4596,7 +4597,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 #include <stdio.h>
 int
-main ()
+main (void)
 {
 FILE *f = fopen ("conftest.out", "w");
  return ferror (f) || fclose (f) != 0;
@@ -4660,7 +4661,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -4711,7 +4712,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 #ifndef __GNUC__
        choke me
@@ -4752,7 +4753,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -4767,7 +4768,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -4783,7 +4784,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -4968,7 +4969,7 @@ struct anonymous
 } v1;
 
 int
-main ()
+main (void)
 {
 
   // Check bool.
@@ -5151,7 +5152,7 @@ test_varargs (const char *format, ...)
   return *str && number && fnumber;
 }
 int
-main ()
+main (void)
 {
 
   // Check bool.
@@ -5277,7 +5278,7 @@ int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, i
 int argc;
 char **argv;
 int
-main ()
+main (void)
 {
 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
   ;
@@ -5345,7 +5346,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -6167,7 +6168,7 @@ else
 #         define __EXTENSIONS__ 1
           $ac_includes_default
 int
-main ()
+main (void)
 {
 
   ;
@@ -6208,7 +6209,7 @@ else
           #include <wchar.h>
           mbstate_t x;
 int
-main ()
+main (void)
 {
 
   ;
@@ -6225,7 +6226,7 @@ else
              #include <wchar.h>
              mbstate_t x;
 int
-main ()
+main (void)
 {
 
   ;
@@ -6310,7 +6311,7 @@ else
                        && LARGE_OFF_T % 2147483647 == 1)
                       ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -6356,7 +6357,7 @@ else
                        && LARGE_OFF_T % 2147483647 == 1)
                       ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -6380,7 +6381,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
                        && LARGE_OFF_T % 2147483647 == 1)
                       ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -6425,7 +6426,7 @@ else
                        && LARGE_OFF_T % 2147483647 == 1)
                       ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -6449,7 +6450,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
                        && LARGE_OFF_T % 2147483647 == 1)
                       ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -6716,6 +6717,8 @@ fi
   # Code from module mbuiter:
   # Code from module memchr:
   # Code from module memchr-tests:
+  # Code from module memchr2:
+  # Code from module memchr2-tests:
   # Code from module mempcpy:
   # Code from module memrchr:
   # Code from module memrchr-tests:
@@ -6998,7 +7001,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
 #ifndef __cplusplus
@@ -7089,7 +7092,7 @@ else
 /* end confdefs.h.  */
 #include <alloca.h>
 int
-main ()
+main (void)
 {
 char *p = (char *) alloca (2 * sizeof (int));
                          if (p) return 0;
@@ -7140,7 +7143,7 @@ void *alloca (size_t);
 #endif
 
 int
-main ()
+main (void)
 {
 char *p = (char *) alloca (1);
                                    if (p) return 0;
@@ -7464,7 +7467,7 @@ else
 /* end confdefs.h.  */
 #include <langinfo.h>
 int
-main ()
+main (void)
 {
 char* cs = nl_langinfo(CODESET); return !cs;
   ;
@@ -8427,7 +8430,7 @@ else
 /* end confdefs.h.  */
 $ac_includes_default
 int
-main ()
+main (void)
 {
 
          char buf[100];
@@ -8458,7 +8461,7 @@ else
 $ac_includes_default
        extern char *strerror_r ();
 int
-main ()
+main (void)
 {
 char buf[100];
          char x = *strerror_r (0, buf, sizeof buf);
@@ -8575,7 +8578,7 @@ else
             };
 
 int
-main ()
+main (void)
 {
 
             int result = !constants;
@@ -8717,7 +8720,7 @@ else
 /* end confdefs.h.  */
 #include <sys/types.h>
 int
-main ()
+main (void)
 {
 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
   ;
@@ -8764,7 +8767,7 @@ $ac_includes_default
 #include <time.h>
 #include <wchar.h>
 int
-main ()
+main (void)
 {
 mbstate_t x; return sizeof x;
   ;
@@ -8927,7 +8930,7 @@ else
                 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -9084,7 +9087,7 @@ else
 #include <sys/stat.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -9134,7 +9137,7 @@ else
 /* end confdefs.h.  */
 $ac_includes_default
 int
-main ()
+main (void)
 {
 struct stat sbuf;
               /* Linux will dereference the symlink and fail, as required by
@@ -9232,7 +9235,7 @@ else
 #        endif
 
 int
-main ()
+main (void)
 {
 
 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
@@ -9281,7 +9284,7 @@ else
 /* end confdefs.h.  */
 #include <unistd.h>
 int
-main ()
+main (void)
 {
 extern
            #ifdef __cplusplus
@@ -9757,7 +9760,7 @@ nocrash_init (void)
 
 
 int
-main ()
+main (void)
 {
 
              int result = 0;
@@ -9875,7 +9878,7 @@ else
                 #include <string.h>
 
 int
-main ()
+main (void)
 {
 static const struct option long_options[] =
                   {
@@ -9969,7 +9972,7 @@ typedef int * int_ptr;
        return ip[0];
        }
 int
-main ()
+main (void)
 {
 int s[1];
        int * $ac_kw t = s;
@@ -10160,7 +10163,7 @@ else
             #endif
 
 int
-main ()
+main (void)
 {
 static struct timeval x; x.tv_sec = x.tv_usec;
   ;
@@ -10196,7 +10199,7 @@ else
               #endif
 
 int
-main ()
+main (void)
 {
 static struct timeval x;
               typedef int verify_tv_sec_type[
@@ -10239,7 +10242,7 @@ else
 #include <time.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -11034,7 +11037,7 @@ else
 #include <iconv.h>
 
 int
-main ()
+main (void)
 {
 iconv_t cd = iconv_open("","");
            iconv(cd,NULL,NULL,NULL,NULL);
@@ -11058,7 +11061,7 @@ rm -f core conftest.err conftest.$ac_objext \
 #include <iconv.h>
 
 int
-main ()
+main (void)
 {
 iconv_t cd = iconv_open("","");
              iconv(cd,NULL,NULL,NULL,NULL);
@@ -11262,7 +11265,7 @@ size_t iconv();
 #endif
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -11368,7 +11371,7 @@ else
                      ? 1 : -1)];
       int i = 63;
 int
-main ()
+main (void)
 {
 /* Test availability of runtime routines for shift and division.  */
       long long int llmax = 9223372036854775807ll;
@@ -11422,7 +11425,7 @@ else
                  # define LLONG_MAX (HALF - 1 + HALF)
                  #endif
 int
-main ()
+main (void)
 {
 long long int n = 1;
                  int i;
@@ -11810,7 +11813,7 @@ struct s {
 };
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -11875,7 +11878,7 @@ static const char *macro_values[] =
   };
 
 int
-main ()
+main (void)
 {
 
   const char **mv;
@@ -12055,7 +12058,7 @@ else
 
             int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -12133,7 +12136,7 @@ else
               extern $gltype foo;
               extern $gltype1 foo;
 int
-main ()
+main (void)
 {
 
   ;
@@ -12205,7 +12208,7 @@ else
               extern $gltype foo;
               extern $gltype1 foo;
 int
-main ()
+main (void)
 {
 
   ;
@@ -12385,7 +12388,7 @@ else
 #include <inttypes.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -12441,7 +12444,7 @@ char *p = PRId32;
 #endif
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -12506,7 +12509,7 @@ else
 #include <wchar.h>
             wint_t foo = (wchar_t)'\0';
 int
-main ()
+main (void)
 {
 
   ;
@@ -12654,7 +12657,7 @@ else
                           Linux libc5 i18n is broken.
                           #endif
 int
-main ()
+main (void)
 {
 
   ;
@@ -12788,7 +12791,7 @@ else
             wctype_t a;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -12828,7 +12831,7 @@ else
             wctrans_t a;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -12873,7 +12876,7 @@ else
 #include <wctype.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -12991,7 +12994,7 @@ else
 #include <stddef.h>
             wchar_t foo = (wchar_t)'\0';
 int
-main ()
+main (void)
 {
 
   ;
@@ -13032,7 +13035,7 @@ else
       int test[2 * (sizeof NULL == sizeof (void *)) -1];
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -13159,7 +13162,7 @@ else
 extern void xyzzy ();
 #pragma weak xyzzy
 int
-main ()
+main (void)
 {
 xyzzy();
   ;
@@ -13236,7 +13239,7 @@ fi
 /* end confdefs.h.  */
 #include <pthread.h>
 int
-main ()
+main (void)
 {
 pthread_mutex_lock((pthread_mutex_t*)0);
                pthread_mutexattr_init((pthread_mutexattr_t*)0);
@@ -13272,7 +13275,7 @@ extern "C"
 #endif
 char pthread_kill ();
 int
-main ()
+main (void)
 {
 return pthread_kill ();
   ;
@@ -13325,7 +13328,7 @@ extern "C"
 #endif
 char pthread_kill ();
 int
-main ()
+main (void)
 {
 return pthread_kill ();
   ;
@@ -13369,7 +13372,7 @@ extern "C"
 #endif
 char pthread_kill ();
 int
-main ()
+main (void)
 {
 return pthread_kill ();
   ;
@@ -13424,7 +13427,7 @@ printf "%s\n" "#define USE_POSIX_THREADS_WEAK 1" >>confdefs.h
 #include <synch.h>
 
 int
-main ()
+main (void)
 {
 thr_self();
   ;
@@ -13979,7 +13982,7 @@ printf "%s\n" "$ac_cv_libpth_libs" >&6; }
 /* end confdefs.h.  */
 #include <pth.h>
 int
-main ()
+main (void)
 {
 pth_self();
   ;
@@ -14137,6 +14140,79 @@ printf "%s\n" "$gl_cv_next_sys_types_h" >&6; }
 
 
 
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
+printf %s "checking for a sed that does not truncate output... " >&6; }
+if ${ac_cv_path_SED+:} false; then :
+  printf %s "(cached) " >&6
+else
+            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
+     for ac_i in 1 2 3 4 5 6 7; do
+       ac_script="$ac_script$as_nl$ac_script"
+     done
+     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
+     { ac_script=; unset ac_script;}
+     if test -z "$SED"; then
+  ac_path_SED_found=false
+  # Loop through the user's path and test for each of PROGNAME-LIST
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  case $as_dir in #(((
+    '') as_dir=./ ;;
+    */) ;;
+    *) as_dir=$as_dir/ ;;
+  esac
+    for ac_prog in sed gsed; do
+    for ac_exec_ext in '' $ac_executable_extensions; do
+      ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
+      as_fn_executable_p "$ac_path_SED" || continue
+# Check for GNU ac_path_SED and select it if it is found.
+  # Check for GNU $ac_path_SED
+case `"$ac_path_SED" --version 2>&1` in
+*GNU*)
+  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
+*)
+  ac_count=0
+  printf %s 0123456789 >"conftest.in"
+  while :
+  do
+    cat "conftest.in" "conftest.in" >"conftest.tmp"
+    mv "conftest.tmp" "conftest.in"
+    cp "conftest.in" "conftest.nl"
+    printf "%s\n" '' >> "conftest.nl"
+    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
+    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+    as_fn_arith $ac_count + 1 && ac_count=$as_val
+    if test $ac_count -gt ${ac_path_SED_max-0}; then
+      # Best one so far, save it but keep looking for a better one
+      ac_cv_path_SED="$ac_path_SED"
+      ac_path_SED_max=$ac_count
+    fi
+    # 10*(2^10) chars as input seems more than enough
+    test $ac_count -gt 10 && break
+  done
+  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+      $ac_path_SED_found && break 3
+    done
+  done
+  done
+IFS=$as_save_IFS
+  if test -z "$ac_cv_path_SED"; then
+    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
+  fi
+else
+  ac_cv_path_SED=$SED
+fi
+
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
+printf "%s\n" "$ac_cv_path_SED" >&6; }
+ SED="$ac_cv_path_SED"
+  rm -f conftest.sed
+
 
   GNULIB__EXIT=0;
   GNULIB_ATOLL=0;
@@ -14229,7 +14305,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
              choke me
@@ -14288,7 +14364,7 @@ else
             #endif
 
 int
-main ()
+main (void)
 {
 return ! malloc (0);
   ;
@@ -15519,7 +15595,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 
   int result = 0;
@@ -15603,7 +15679,7 @@ else
 #include <limits.h>
             int x = MIN (42, 17);
 int
-main ()
+main (void)
 {
 
   ;
@@ -15640,7 +15716,7 @@ else
 #include <sys/param.h>
             int x = MIN (42, 17);
 int
-main ()
+main (void)
 {
 
   ;
@@ -15698,7 +15774,7 @@ else
 /* end confdefs.h.  */
 #include <sys/types.h>
 int
-main ()
+main (void)
 {
 int x = sizeof (ssize_t *) + sizeof (ssize_t);
             return !x;
@@ -15774,7 +15850,7 @@ else
              _Bool *pq = &q;
 
 int
-main ()
+main (void)
 {
 
              bool e = &s;
@@ -15951,7 +16027,7 @@ else
            #include <errno.h>
 
 int
-main ()
+main (void)
 {
 int result = 0;
            char *str;
@@ -16077,7 +16153,7 @@ else
 #include <string.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -16191,7 +16267,7 @@ else
 #include <time.h>
 
 int
-main ()
+main (void)
 {
 static struct timespec x; x.tv_sec = x.tv_nsec;
   ;
@@ -16224,7 +16300,7 @@ else
 #include <sys/time.h>
 
 int
-main ()
+main (void)
 {
 static struct timespec x; x.tv_sec = x.tv_nsec;
   ;
@@ -16253,7 +16329,7 @@ else
 #include <pthread.h>
 
 int
-main ()
+main (void)
 {
 static struct timespec x; x.tv_sec = x.tv_nsec;
   ;
@@ -16608,7 +16684,7 @@ else
 
            extern struct { int foo; } environ;
 int
-main ()
+main (void)
 {
 environ.foo = 1;
   ;
@@ -16662,7 +16738,7 @@ else
 /* end confdefs.h.  */
 #include <locale.h>
 int
-main ()
+main (void)
 {
 return LC_MESSAGES
   ;
@@ -16697,7 +16773,7 @@ else
 /* end confdefs.h.  */
 #include <CoreFoundation/CFPreferences.h>
 int
-main ()
+main (void)
 {
 CFPreferencesCopyAppValue(NULL, NULL)
   ;
@@ -16731,7 +16807,7 @@ else
 /* end confdefs.h.  */
 #include <CoreFoundation/CFLocale.h>
 int
-main ()
+main (void)
 {
 CFLocaleCopyCurrent();
   ;
@@ -16976,7 +17052,7 @@ else
 #include <inttypes.h>
 
 int
-main ()
+main (void)
 {
 uintmax_t i = (uintmax_t) -1; return !i;
   ;
@@ -17011,7 +17087,7 @@ else
 #include <sys/types.h>
             #include <stdint.h>
 int
-main ()
+main (void)
 {
 uintmax_t i = (uintmax_t) -1; return !i;
   ;
@@ -17056,7 +17132,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 intmax_t x = -1; return !x;
   ;
@@ -17157,7 +17233,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
             #include <sys/param.h>
 
 int
-main ()
+main (void)
 {
 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
                     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
@@ -17177,7 +17253,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
                #include <sys/param.h>
 
 int
-main ()
+main (void)
 {
 #if BYTE_ORDER != BIG_ENDIAN
                 not big endian
@@ -17203,7 +17279,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 #include <limits.h>
 
 int
-main ()
+main (void)
 {
 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
              bogus endian macros
@@ -17220,7 +17296,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
 #include <limits.h>
 
 int
-main ()
+main (void)
 {
 #ifndef _BIG_ENDIAN
                 not big endian
@@ -17262,7 +17338,7 @@ short int ascii_mm[] =
                extern int foo;
 
 int
-main ()
+main (void)
 {
 return use_ascii (foo) == use_ebcdic (foo);
   ;
@@ -17288,7 +17364,7 @@ else
 /* end confdefs.h.  */
 $ac_includes_default
 int
-main ()
+main (void)
 {
 
             /* Are we little or big endian?  From Harbison&Steele.  */
@@ -18100,7 +18176,7 @@ else
 #include <ctype.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -18150,7 +18226,7 @@ else
              #include <dirent.h>
 
 int
-main ()
+main (void)
 {
 DIR *dp = opendir (".");
              struct dirent *e;
@@ -18203,7 +18279,7 @@ else
 #include <dirent.h>
 
 int
-main ()
+main (void)
 {
 struct dirent dp; dp.d_type = 0;
   ;
@@ -18336,7 +18412,7 @@ else
 #include <dirent.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -18475,7 +18551,7 @@ else
            #include <sys/types.h>
            #include <dirent.h>
 int
-main ()
+main (void)
 {
 DIR *dir_p = opendir("."); (void) dir_p->DIR_FD_MEMBER_NAME;
   ;
@@ -18656,7 +18732,7 @@ else
 #include <fcntl.h>
 #include <errno.h>
 int
-main ()
+main (void)
 {
 int result = 0;
 #ifdef FD_CLOEXEC
@@ -18778,7 +18854,7 @@ else
 /* end confdefs.h.  */
 #include <error.h>
 int
-main ()
+main (void)
 {
 error_at_line (0, 0, "", 0, "an error occurred");
   ;
@@ -18871,7 +18947,7 @@ else
 #include <fcntl.h>
 
 int
-main ()
+main (void)
 {
 return open(".", O_RDONLY) < 0;
   ;
@@ -18962,7 +19038,7 @@ else
 #include <errno.h>
 
 int
-main ()
+main (void)
 {
 int result = 0;
       if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
@@ -19021,7 +19097,7 @@ choke me
 #endif
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -19039,7 +19115,7 @@ choke me
 #endif
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -19229,7 +19305,7 @@ else
 #include <fcntl.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -19330,7 +19406,7 @@ DIR *fdopendir (int);
 #endif
 
 int
-main ()
+main (void)
 {
 int result = 0;
      int fd = open ("conftest.c", O_RDONLY);
@@ -19445,7 +19521,7 @@ else
             }
 
 int
-main ()
+main (void)
 {
 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
             char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
@@ -19637,7 +19713,7 @@ else
 /* end confdefs.h.  */
 $fp_headers
 int
-main ()
+main (void)
 {
 return ! __fpending (stdin);
   ;
@@ -19734,7 +19810,7 @@ else
 /* end confdefs.h.  */
 #include <stdio.h>
 int
-main ()
+main (void)
 {
 FILE *fp = stdin; (void) ($ac_expr);
   ;
@@ -20059,7 +20135,7 @@ else
 
         #include <unistd.h>
 int
-main ()
+main (void)
 {
 int size = getdtablesize();
            if (dup2 (0, getdtablesize()) != -1)
@@ -20345,7 +20421,7 @@ else
           #include <stdlib.h>
 
 int
-main ()
+main (void)
 {
 
           time_t t = 0;
@@ -20399,7 +20475,7 @@ else
               int gettimeofday (struct timeval *restrict, void *restrict);
 
 int
-main ()
+main (void)
 {
 /* glibc uses struct timezone * rather than the POSIX void *
                  if _GNU_SOURCE is defined.  However, since the only portable
@@ -20424,7 +20500,7 @@ else
 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -20736,7 +20812,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 #ifdef __NO_INLINE__
                #error "inline is not effective"
@@ -20784,7 +20860,7 @@ printf "%s\n" "#define HAVE_INLINE 1" >>confdefs.h
            extern intptr_t foo;
            extern $gltype1 foo;
 int
-main ()
+main (void)
 {
 
   ;
@@ -20828,7 +20904,7 @@ else
             #endif
             int test[CONDITION ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -20880,7 +20956,7 @@ else
             #endif
             int test[CONDITION ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -20934,7 +21010,7 @@ else
             #endif
             int test[CONDITION ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -20986,7 +21062,7 @@ else
             #endif
             int test[CONDITION ? 1 : -1];
 int
-main ()
+main (void)
 {
 
   ;
@@ -21310,7 +21386,7 @@ else
 int a = CODESET;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -21341,7 +21417,7 @@ else
 int a = T_FMT_AMPM;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -21372,7 +21448,7 @@ else
 int a = ERA;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -21403,7 +21479,7 @@ else
 int a = YESEXPR;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -21445,7 +21521,7 @@ else
 #include <langinfo.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -21517,7 +21593,7 @@ else
             int x = LC_MESSAGES;
             int y = sizeof (((struct lconv *) 0)->decimal_point);
 int
-main ()
+main (void)
 {
 
   ;
@@ -21553,7 +21629,7 @@ else
 #include <locale.h>
               locale_t x;
 int
-main ()
+main (void)
 {
 
   ;
@@ -21593,7 +21669,7 @@ else
             int x = sizeof (l.decimal_point);
             int y = sizeof (l.int_p_cs_precedes);
 int
-main ()
+main (void)
 {
 
   ;
@@ -21703,7 +21779,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -21798,7 +21874,7 @@ fi
 
       #include <pthread.h>
 int
-main ()
+main (void)
 {
 
 #if __FreeBSD__ == 4
@@ -21866,7 +21942,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 
   /* Exit with success only if stdin is seekable.  */
@@ -22004,6 +22080,7 @@ printf "%s\n" "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
 
 
 
+
       for ac_header in stdlib.h
 do :
   ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
@@ -22040,7 +22117,7 @@ else
             #endif
 
 int
-main ()
+main (void)
 {
 return ! malloc (0);
   ;
@@ -23760,7 +23837,7 @@ else
 #include <langinfo.h>
 
 int
-main ()
+main (void)
 {
 return !*nl_langinfo(YESEXPR);
 
@@ -23852,7 +23929,7 @@ else
 $ac_includes_default
                      #include "obstack.h"
 int
-main ()
+main (void)
 {
 struct obstack mem;
                       #define obstack_chunk_alloc malloc
@@ -24363,7 +24440,7 @@ else
             #endif
 
 int
-main ()
+main (void)
 {
 return ! realloc (0, 0);
   ;
@@ -24514,7 +24591,7 @@ else
             #endif
 
 int
-main ()
+main (void)
 {
 int result = 0;
             static struct re_pattern_buffer regex;
@@ -24841,7 +24918,7 @@ else
 /* end confdefs.h.  */
 #include <sys/types.h>
 int
-main ()
+main (void)
 {
 int x = sizeof (ssize_t *) + sizeof (ssize_t);
             return !x;
@@ -24889,7 +24966,7 @@ else
 #include <sys/stat.h>
 
 int
-main ()
+main (void)
 {
 struct stat st; return stat (".", &st) != stat ("./", &st);
   ;
@@ -24932,7 +25009,7 @@ else
 #include <sys/stat.h>
 
 int
-main ()
+main (void)
 {
 int result = 0;
       struct stat st;
@@ -25015,7 +25092,7 @@ else
 /* end confdefs.h.  */
 #include <stdarg.h>
 int
-main ()
+main (void)
 {
 
 #ifndef va_copy
@@ -25141,7 +25218,7 @@ else
 /* end confdefs.h.  */
 #include <stdarg.h>
 int
-main ()
+main (void)
 {
 
 #ifndef __va_copy
@@ -25231,7 +25308,7 @@ else
       int test[2 * (sizeof NULL == sizeof (void *)) -1];
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -25458,7 +25535,7 @@ else
 #include <stdio.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -25579,7 +25656,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -25737,7 +25814,7 @@ else
 #include <string.h>
 
 int
-main ()
+main (void)
 {
 if (!*strerror (-2)) return 1;
   ;
@@ -25887,7 +25964,7 @@ else
 /* end confdefs.h.  */
 $ac_includes_default
 int
-main ()
+main (void)
 {
 
 #define S "foobar"
@@ -26383,7 +26460,7 @@ else
 #include <sys/stat.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -26548,7 +26625,7 @@ else
 #endif
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -27044,7 +27121,7 @@ else
 #include <wchar.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -27731,7 +27808,7 @@ else
                           Linux libc5 i18n is broken.
                           #endif
 int
-main ()
+main (void)
 {
 
   ;
@@ -27865,7 +27942,7 @@ else
             wctype_t a;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -27905,7 +27982,7 @@ else
             wctrans_t a;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -27950,7 +28027,7 @@ else
 #include <wctype.h>
 
 int
-main ()
+main (void)
 {
 #undef $gl_func
   (void) $gl_func;
@@ -30809,6 +30886,83 @@ printf "%s\n" "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
 
 
 
+  # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
+  # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
+  # irrelevant for anonymous mappings.
+  ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
+if test "x$ac_cv_func_mmap" = xyes; then :
+  gl_have_mmap=yes
+else
+  gl_have_mmap=no
+fi
+
+
+  # Try to allow MAP_ANONYMOUS.
+  gl_have_mmap_anonymous=no
+  if test $gl_have_mmap = yes; then
+    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
+printf %s "checking for MAP_ANONYMOUS... " >&6; }
+    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+#include <sys/mman.h>
+#ifdef MAP_ANONYMOUS
+    I cannot identify this map
+#endif
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
+  gl_have_mmap_anonymous=yes
+fi
+rm -rf conftest*
+
+    if test $gl_have_mmap_anonymous != yes; then
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+#include <sys/mman.h>
+#ifdef MAP_ANON
+    I cannot identify this map
+#endif
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
+
+printf "%s\n" "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
+
+         gl_have_mmap_anonymous=yes
+fi
+rm -rf conftest*
+
+    fi
+    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
+printf "%s\n" "$gl_have_mmap_anonymous" >&6; }
+    if test $gl_have_mmap_anonymous = yes; then
+
+printf "%s\n" "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
+
+    fi
+  fi
+
+
+  :
+
+
+
+
+
+
+  :
+
+
+
+
+
+
+
+
   { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
 printf %s "checking for a traditional french locale... " >&6; }
 if ${gt_cv_locale_fr+:} false; then :
@@ -31136,7 +31290,7 @@ else
 /* end confdefs.h.  */
 $ac_includes_default
 int
-main ()
+main (void)
 {
 
     /* Put it in env.  */
@@ -31327,7 +31481,7 @@ else
        #include <string.h>
 
 int
-main ()
+main (void)
 {
 
        int result = 0;
@@ -32045,7 +32199,7 @@ fi
                  extern unsigned long foo;
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -32376,7 +32530,7 @@ else
 #include <unistd.h>
 
 int
-main ()
+main (void)
 {
 int result = 0;
              if (!symlink ("a", "conftest.link/"))
@@ -32490,7 +32644,7 @@ extern
 int unsetenv (const char *name);
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -32535,7 +32689,7 @@ else
        extern char **environ;
 
 int
-main ()
+main (void)
 {
 
        char entry1[] = "a=1";
@@ -33313,7 +33467,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33351,7 +33505,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
   nw="$nw -Wlong-long"              # C90 is anachronistic (lib/gethrxtime.h)
   nw="$nw -Wc++-compat"             # We don't care about C++ compilers
   nw="$nw -Wundef"                  # Warns on '#if GNULIB_FOO' etc in gnulib
-  nw="$nw -Wtraditional"            # Warns on #elif which we use often
-  nw="$nw -Wcast-qual"              # Too many warnings for now
-  nw="$nw -Wconversion"             # Too many warnings for now
   nw="$nw -Wsystem-headers"         # Don't let system headers trigger warnings
-  nw="$nw -Wsign-conversion"        # Too many warnings for now
-  nw="$nw -Wtraditional-conversion" # Too many warnings for now
-  nw="$nw -Wunreachable-code"       # Too many warnings for now
   nw="$nw -Wpadded"                 # Our structs are not padded
-  nw="$nw -Wredundant-decls"        # openat.h declares e.g., mkdirat
-  nw="$nw -Wlogical-op"             # any use of fwrite provokes this
-  nw="$nw -Wformat-nonliteral"      # who.c and pinky.c strftime uses
   nw="$nw -Wvla"                    # warnings in gettext.h
-  nw="$nw -Wnested-externs"         # use of XARGMATCH/verify_function__
-  nw="$nw -Wswitch-enum"            # Too many warnings for now
   nw="$nw -Wswitch-default"         # Too many warnings for now
-  nw="$nw -Wstack-protector"        # not worth working around
-  # things I might fix soon:
-  nw="$nw -Wfloat-equal"            # sort.c, seq.c
-  nw="$nw -Wmissing-format-attribute" # copy.c
-  nw="$nw -Wunsafe-loop-optimizations" # a few src/*.c
-  nw="$nw -Winline"                 # system.h's readdir_ignoring_dot_and_dotdot
-  nw="$nw -Wstrict-overflow"        # expr.c, pr.c, tr.c, factor.c
-  # ?? -Wstrict-overflow
+  nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
+  nw="$nw -Winline"                 # streq.h's streq4, streq6 and strcaseeq6
+  nw="$nw -Wstrict-overflow"        # regexec.c
 
 
 
@@ -33424,7 +33562,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33461,7 +33599,7 @@ void f (void)
                }
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33494,7 +33632,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33569,7 +33707,6 @@ printf "%s\n" "$gl_cv_cc_uninitialized_supported" >&6; }
     -Wmissing-include-dirs \
     -Wmissing-parameter-type \
     -Wmissing-prototypes \
-    -Wmudflap \
     -Wmultichar \
     -Wnarrowing \
     -Wnested-externs \
@@ -33679,7 +33816,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33718,7 +33855,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33755,7 +33892,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
 
      # Too many warnings for now
 
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-pointer-sign" >&5
-printf %s "checking whether C compiler handles -Wno-pointer-sign... " >&6; }
-if ${gl_cv_warn_c__Wno_pointer_sign+:} false; then :
-  printf %s "(cached) " >&6
-else
-
-  gl_save_compiler_FLAGS="$CFLAGS"
-  as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wpointer-sign"
-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-  gl_cv_warn_c__Wno_pointer_sign=yes
-else
-  gl_cv_warn_c__Wno_pointer_sign=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
-    conftest$ac_exeext conftest.$ac_ext
-  CFLAGS="$gl_save_compiler_FLAGS"
-
-fi
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_pointer_sign" >&5
-printf "%s\n" "$gl_cv_warn_c__Wno_pointer_sign" >&6; }
-if test "x$gl_cv_warn_c__Wno_pointer_sign" = xyes; then :
-  as_fn_append WARN_CFLAGS " -Wno-pointer-sign"
-fi
-
-     # Too many warnings for now
-
 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
 printf %s "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
 if ${gl_cv_warn_c__Wno_unused_parameter+:} false; then :
@@ -33829,7 +33929,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33869,7 +33969,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33907,12 +34007,7 @@ printf "%s\n" "#define GNULIB_PORTCHECK 1" >>confdefs.h
   # We use a slightly smaller set of warning options for lib/.
   # Remove the following and save the result in GNULIB_WARN_CFLAGS.
   nw=
-  #nw="$nw -Wuninitialized"
   nw="$nw -Wunused-macros"
-  #nw="$nw -Wmissing-prototypes"
-  nw="$nw -Wold-style-definition"
-  nw="$nw -Wcast-align"
-  nw="$nw -Wunsuffixed-float-constants"
 
 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
 printf %s "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
@@ -33926,7 +34021,7 @@ else
 /* end confdefs.h.  */
 
 int
-main ()
+main (void)
 {
 
   ;
@@ -33993,7 +34088,7 @@ else
 #include <$ac_hdr>
 
 int
-main ()
+main (void)
 {
 if ((DIR *) 0)
 return 0;
@@ -34039,7 +34134,7 @@ extern "C"
 #endif
 char opendir ();
 int
-main ()
+main (void)
 {
 return opendir ();
   ;
@@ -34096,7 +34191,7 @@ extern "C"
 #endif
 char opendir ();
 int
-main ()
+main (void)
 {
 return opendir ();
   ;
@@ -34155,7 +34250,7 @@ int closedir ();
 #endif
 
 int
-main ()
+main (void)
 {
 return closedir (opendir (".")) != 0;
   ;
@@ -34539,7 +34634,7 @@ else
 /* end confdefs.h.  */
 #include <CoreFoundation/CFPreferences.h>
 int
-main ()
+main (void)
 {
 CFPreferencesCopyAppValue(NULL, NULL)
   ;
@@ -34573,7 +34668,7 @@ else
 /* end confdefs.h.  */
 #include <CoreFoundation/CFLocale.h>
 int
-main ()
+main (void)
 {
 CFLocaleCopyCurrent();
   ;
@@ -34652,7 +34747,7 @@ extern int _nl_msg_cat_cntr;
 extern int *_nl_domain_bindings;
 
 int
-main ()
+main (void)
 {
 
 bindtextdomain ("", "");
@@ -34720,7 +34815,7 @@ else
 #include <iconv.h>
 
 int
-main ()
+main (void)
 {
 iconv_t cd = iconv_open("","");
            iconv(cd,NULL,NULL,NULL,NULL);
@@ -34744,7 +34839,7 @@ rm -f core conftest.err conftest.$ac_objext \
 #include <iconv.h>
 
 int
-main ()
+main (void)
 {
 iconv_t cd = iconv_open("","");
              iconv(cd,NULL,NULL,NULL,NULL);
@@ -35409,7 +35504,7 @@ extern
 const char *_nl_expand_alias (const char *);
 
 int
-main ()
+main (void)
 {
 
 bindtextdomain ("", "");
@@ -35441,7 +35536,7 @@ extern
 const char *_nl_expand_alias (const char *);
 
 int
-main ()
+main (void)
 {
 
 bindtextdomain ("", "");
@@ -35645,7 +35740,7 @@ extern "C"
 #endif
 char pcre_compile ();
 int
-main ()
+main (void)
 {
 return pcre_compile ();
   ;
@@ -36329,8 +36424,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by GNU grep $as_me 2.16, which was
-generated by GNU Autoconf 2.69.112-f181.  Invocation command line was
+This file was extended by GNU grep $as_me 2.19, which was
+generated by GNU Autoconf 2.69.117-1717.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
   CONFIG_HEADERS  = $CONFIG_HEADERS
@@ -36401,11 +36496,11 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`printf "%s\n" "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-GNU grep config.status 2.16
-configured by $0, generated by GNU Autoconf 2.69.112-f181,
+GNU grep config.status 2.19
+configured by $0, generated by GNU Autoconf 2.69.117-1717,
   with options \\"\$ac_cs_config\\"
 
-Copyright (C) 2013 Free Software Foundation, Inc.
+Copyright (C) 2014 Free Software Foundation, Inc.
 This config.status script is free software; the Free Software Foundation
 gives unlimited permission to copy, distribute and modify it."
 
index 886449b..c301ebe 100644 (file)
@@ -114,29 +114,13 @@ if test "$gl_gcc_warnings" = yes; then
   nw="$nw -Wlong-long"              # C90 is anachronistic (lib/gethrxtime.h)
   nw="$nw -Wc++-compat"             # We don't care about C++ compilers
   nw="$nw -Wundef"                  # Warns on '#if GNULIB_FOO' etc in gnulib
-  nw="$nw -Wtraditional"            # Warns on #elif which we use often
-  nw="$nw -Wcast-qual"              # Too many warnings for now
-  nw="$nw -Wconversion"             # Too many warnings for now
   nw="$nw -Wsystem-headers"         # Don't let system headers trigger warnings
-  nw="$nw -Wsign-conversion"        # Too many warnings for now
-  nw="$nw -Wtraditional-conversion" # Too many warnings for now
-  nw="$nw -Wunreachable-code"       # Too many warnings for now
   nw="$nw -Wpadded"                 # Our structs are not padded
-  nw="$nw -Wredundant-decls"        # openat.h declares e.g., mkdirat
-  nw="$nw -Wlogical-op"             # any use of fwrite provokes this
-  nw="$nw -Wformat-nonliteral"      # who.c and pinky.c strftime uses
   nw="$nw -Wvla"                    # warnings in gettext.h
-  nw="$nw -Wnested-externs"         # use of XARGMATCH/verify_function__
-  nw="$nw -Wswitch-enum"            # Too many warnings for now
   nw="$nw -Wswitch-default"         # Too many warnings for now
-  nw="$nw -Wstack-protector"        # not worth working around
-  # things I might fix soon:
-  nw="$nw -Wfloat-equal"            # sort.c, seq.c
-  nw="$nw -Wmissing-format-attribute" # copy.c
-  nw="$nw -Wunsafe-loop-optimizations" # a few src/*.c
-  nw="$nw -Winline"                 # system.h's readdir_ignoring_dot_and_dotdot
-  nw="$nw -Wstrict-overflow"        # expr.c, pr.c, tr.c, factor.c
-  # ?? -Wstrict-overflow
+  nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
+  nw="$nw -Winline"                 # streq.h's streq4, streq6 and strcaseeq6
+  nw="$nw -Wstrict-overflow"        # regexec.c
 
   gl_MANYWARN_ALL_GCC([ws])
   gl_MANYWARN_COMPLEMENT([ws], [$ws], [$nw])
@@ -145,7 +129,6 @@ if test "$gl_gcc_warnings" = yes; then
   done
   gl_WARN_ADD([-Wno-missing-field-initializers]) # We need this one
   gl_WARN_ADD([-Wno-sign-compare])     # Too many warnings for now
-  gl_WARN_ADD([-Wno-pointer-sign])     # Too many warnings for now
   gl_WARN_ADD([-Wno-unused-parameter]) # Too many warnings for now
 
   # In spite of excluding -Wlogical-op above, it is enabled, as of
@@ -167,12 +150,7 @@ if test "$gl_gcc_warnings" = yes; then
   # We use a slightly smaller set of warning options for lib/.
   # Remove the following and save the result in GNULIB_WARN_CFLAGS.
   nw=
-  #nw="$nw -Wuninitialized"
   nw="$nw -Wunused-macros"
-  #nw="$nw -Wmissing-prototypes"
-  nw="$nw -Wold-style-definition"
-  nw="$nw -Wcast-align"
-  nw="$nw -Wunsuffixed-float-constants"
   gl_WARN_ADD([-Wno-format-nonliteral])
   gl_MANYWARN_COMPLEMENT([GNULIB_WARN_CFLAGS], [$WARN_CFLAGS], [$nw])
   AC_SUBST([GNULIB_WARN_CFLAGS])
index 4e25df5..f58ae3d 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1062,6 +1062,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -1167,7 +1168,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu doc/Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --gnu doc/Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -1619,6 +1619,8 @@ uninstall-man: uninstall-man1
        uninstall-dvi-am uninstall-html-am uninstall-info-am \
        uninstall-man uninstall-man1 uninstall-pdf-am uninstall-ps-am
 
+.PRECIOUS: Makefile
+
 
 grep.1: grep.in.1
        $(AM_V_GEN)rm -f $@ $@-t
index d91de8c..58a6c0e 100644 (file)
@@ -544,23 +544,6 @@ Follow all symbolic links, unlike
 Use line buffering on output.
 This can cause a performance penalty.
 .TP
-.B \-\^\-mmap
-If possible, use the
-.BR mmap (2)
-system call to read input, instead of
-the default
-.BR read (2)
-system call.
-In some situations,
-.B \-\^\-mmap
-yields better performance.
-However,
-.B \-\^\-mmap
-can cause undefined behavior (including core dumps)
-if an input file shrinks while
-.B grep
-is operating, or if an I/O error occurs.
-.TP
 .BR \-U ", " \-\^\-binary
 Treat the file(s) as binary.
 By default, under \s-1MS-DOS\s0 and \s-1MS\s0-Windows,
@@ -1219,7 +1202,7 @@ Back-references are very slow, and may require exponential time.
 .SS "Regular Manual Pages"
 awk(1), cmp(1), diff(1), find(1), gzip(1),
 perl(1), sed(1), sort(1), xargs(1), zgrep(1),
-mmap(2), read(2),
+read(2),
 pcre(3), pcresyntax(3), pcrepattern(3),
 terminfo(5),
 glob(7), regex(7).
index eaa6f4b..5dcb88a 100644 (file)
@@ -25,7 +25,7 @@ grep
 
 `grep' prints lines that contain a match for a pattern.
 
-   This manual is for version 2.16 of GNU Grep.
+   This manual is for version 2.19 of GNU Grep.
 
    This manual is for `grep', a pattern matching engine.
 
@@ -152,7 +152,20 @@ File: grep.info-t,  Node: Matching Control,  Next: General Output Control,  Prev
 `-i'
 `-y'
 `--ignore-case'
-     Ignore case distinctions in both the pattern and the input files.
+     Ignore case distinctions, so that characters that differ only in
+     case match each other.  Although this is straightforward when
+     letters differ in case only via lowercase-uppercase pairs, the
+     behavior is unspecified in other situations.  For example,
+     uppercase "S" has an unusual lowercase counterpart "ſ" (Unicode
+     character U+017F, LATIN SMALL LETTER LONG S) in many locales, and
+     it is unspecified whether this unusual character matches "S" or
+     "s" even though uppercasing it yields "S".  Another example: the
+     lowercase German letter "ß" (U+00DF, LATIN SMALL LETTER SHARP S)
+     is normally capitalized as the two-character string "SS" but it
+     does not match "SS", and it might not match the uppercase letter
+     "ẞ" (U+1E9E, LATIN CAPITAL LETTER SHARP S) even though
+     lowercasing the latter yields the former.
+
      `-y' is an obsolete synonym that is provided for compatibility.
      (`-i' is specified by POSIX.)
 
@@ -377,11 +390,11 @@ their use.
 
 `--group-separator=STRING'
      When `-A', `-B' or `-C' are in use, print STRING instead of `--'
-     around disjoint groups of lines.
+     between groups of lines.
 
 `--no-group-separator'
-     When `-A', `-B' or `-C' are in use, print disjoint groups of lines
-     adjacent to each other.
+     When `-A', `-B' or `-C' are in use, do not print a separator
+     between groups of lines.
 
 
    Here are some points about how `grep' chooses the separator to print
@@ -392,20 +405,19 @@ between prefix fields and line content:
 
    * Context (i.e., non-matching) lines use `-' instead.
 
-   * When no context is specified, matching lines are simply output one
-     right after another.
+   * When context is not specified, matching lines are simply output
+     one right after another.
 
-   * When nonzero context is specified, lines that are adjacent in the
-     input form a group and are output one right after another, while a
-     separator appears by default between disjoint groups on a line of
-     its own and without any prefix.
+   * When context is specified, lines that are adjacent in the input
+     form a group and are output one right after another, while by
+     default a separator appears between non-adjacent groups.
 
-   * The default separator is `--', however whether to include it and
-     its appearance can be changed with the options above.
+   * The default separator is a `--' line; its presence and appearance
+     can be changed with the options above.
 
    * Each group may contain several matching lines when they are close
-     enough to each other that two otherwise adjacent but divided
-     groups connect and can just merge into a single contiguous one.
+     enough to each other that two adjacent groups connect and can
+     merge into a single contiguous one.
 
 \1f
 File: grep.info-t,  Node: File and Directory Selection,  Next: Other Options,  Prev: Context Line Control,  Up: Command-line Options
@@ -503,13 +515,6 @@ File: grep.info-t,  Node: Other Options,  Prev: File and Directory Selection,  U
      Use line buffering on output.  This can cause a performance
      penalty.
 
-`--mmap'
-     This option is deprecated and now elicits a warning, but is
-     otherwise a no-op.  It used to make `grep' read input with the
-     `mmap' system call, instead of the default `read' system call.  On
-     modern systems, `mmap' would rarely if ever yield better
-     performance.
-
 `-U'
 `--binary'
      Treat the file(s) as binary.  By default, under MS-DOS and
@@ -694,8 +699,8 @@ capabilities are stored in an online database and accessed by the
 `LC_COLLATE'
 `LANG'
      These variables specify the locale for the `LC_COLLATE' category,
-     which determines the collating sequence used to interpret range
-     expressions like `[a-z]'.
+     which might affect how range expressions like `[a-z]' are
+     interpreted.
 
 `LC_ALL'
 `LC_CTYPE'
@@ -885,14 +890,14 @@ single digit.
 
    Within a bracket expression, a "range expression" consists of two
 characters separated by a hyphen.  It matches any single character that
-sorts between the two characters, inclusive, using the locale's
-collating sequence and character set.  For example, in the default C
-locale, `[a-d]' is equivalent to `[abcd]'.  Many locales sort
-characters in dictionary order, and in these locales `[a-d]' is
-typically not equivalent to `[abcd]'; it might be equivalent to
-`[aBbCcDd]', for example.  To obtain the traditional interpretation of
-bracket expressions, you can use the `C' locale by setting the `LC_ALL'
-environment variable to the value `C'.
+sorts between the two characters, inclusive.  In the default C locale,
+the sorting sequence is the native character order; for example,
+`[a-d]' is equivalent to `[abcd]'.  In other locales, the sorting
+sequence is not specified, and `[a-d]' might be equivalent to `[abcd]'
+or to `[aBbCcDd]', or it might fail to match any character, or the set
+of characters that it matches might even be erratic.  To obtain the
+traditional interpretation of bracket expressions, you can use the `C'
+locale by setting the `LC_ALL' environment variable to the value `C'.
 
    Finally, certain named classes of characters are predefined within
 bracket expressions, as follows.  Their interpretation depends on the
@@ -1252,23 +1257,19 @@ match.  *Note Invoking::, for more details about how to invoke `grep'.
 
      Standard grep cannot do this, as it is fundamentally line-based.
      Therefore, merely using the `[:space:]' character class does not
-     match newlines in the way you might expect.  However, if your grep
-     is compiled with Perl patterns enabled, the Perl `s' modifier
-     (which makes `.' match newlines) can be used:
-
-          printf 'foo\nbar\n' | grep -P '(?s)foo.*?bar'
+     match newlines in the way you might expect.
 
      With the GNU `grep' option `-z' (*note File and Directory
      Selection::), the input is terminated by null bytes.  Thus, you
-     can match newlines in the input, but the output will be the whole
-     file, so this is really only useful to determine if the pattern is
-     present:
+     can match newlines in the input, but typically if there is a match
+     the entire input is output, so this usage is often combined with
+     output-suppressing options like `-q', e.g.:
 
           printf 'foo\nbar\n' | grep -z -q 'foo[[:space:]]\+bar'
 
-     Failing either of those options, you need to transform the input
-     before giving it to `grep', or turn to `awk', `sed', `perl', or
-     many other utilities that are designed to operate across lines.
+     If this does not suffice, you can transform the input before
+     giving it to `grep', or turn to `awk', `sed', `perl', or many
+     other utilities that are designed to operate across lines.
 
  16. What do `grep', `fgrep', and `egrep' stand for?
 
@@ -1840,7 +1841,7 @@ Index
 * --basic-regexp:                        grep Programs.       (line  16)
 * --before-context:                      Context Line Control.
                                                               (line  17)
-* --binary:                              Other Options.       (line  19)
+* --binary:                              Other Options.       (line  12)
 * --binary-files:                        File and Directory Selection.
                                                               (line  12)
 * --byte-offset:                         Output Line Prefix Control.
@@ -1881,23 +1882,22 @@ Index
                                                               (line  70)
 * --initial-tab:                         Output Line Prefix Control.
                                                               (line  43)
-* --invert-match:                        Matching Control.    (line  27)
+* --invert-match:                        Matching Control.    (line  40)
 * --label:                               Output Line Prefix Control.
                                                               (line  30)
 * --line-buffered:                       Other Options.       (line   7)
 * --line-number:                         Output Line Prefix Control.
                                                               (line  38)
-* --line-regexp:                         Matching Control.    (line  41)
+* --line-regexp:                         Matching Control.    (line  54)
 * --max-count:                           General Output Control.
                                                               (line  42)
-* --mmap:                                Other Options.       (line  11)
 * --no-filename:                         Output Line Prefix Control.
                                                               (line  25)
 * --no-messages:                         General Output Control.
                                                               (line  88)
 * --null:                                Output Line Prefix Control.
                                                               (line  63)
-* --null-data:                           Other Options.       (line  33)
+* --null-data:                           Other Options.       (line  26)
 * --only-matching:                       General Output Control.
                                                               (line  75)
 * --perl-regexp:                         grep Programs.       (line  32)
@@ -1916,7 +1916,7 @@ Index
                                                               (line  12)
 * --with-filename:                       Output Line Prefix Control.
                                                               (line  20)
-* --word-regexp:                         Matching Control.    (line  32)
+* --word-regexp:                         Matching Control.    (line  45)
 * -a:                                    File and Directory Selection.
                                                               (line   8)
 * -A:                                    Context Line Control.
@@ -1966,16 +1966,16 @@ Index
                                                               (line  88)
 * -T:                                    Output Line Prefix Control.
                                                               (line  43)
-* -U:                                    Other Options.       (line  19)
+* -U:                                    Other Options.       (line  12)
 * -u:                                    Output Line Prefix Control.
                                                               (line  53)
-* -v:                                    Matching Control.    (line  27)
+* -v:                                    Matching Control.    (line  40)
 * -V:                                    Generic Program Information.
                                                               (line  12)
-* -w:                                    Matching Control.    (line  32)
-* -x:                                    Matching Control.    (line  41)
+* -w:                                    Matching Control.    (line  45)
+* -x:                                    Matching Control.    (line  54)
 * -y:                                    Matching Control.    (line  21)
-* -z:                                    Other Options.       (line  33)
+* -z:                                    Other Options.       (line  26)
 * -Z:                                    Output Line Prefix Control.
                                                               (line  63)
 * .:                                     Fundamental Structure.
@@ -2006,7 +2006,7 @@ Index
                                                               (line  17)
 * binary files:                          File and Directory Selection.
                                                               (line   8)
-* binary files, MS-DOS/MS-Windows:       Other Options.       (line  19)
+* binary files, MS-DOS/MS-Windows:       Other Options.       (line  12)
 * blank character class:                 Character Classes and Bracket Expressions.
                                                               (line  39)
 * blank characters:                      Character Classes and Bracket Expressions.
@@ -2101,7 +2101,7 @@ Index
 * include files:                         File and Directory Selection.
                                                               (line  70)
 * interval specifications:               Basic vs Extended.   (line  10)
-* invert matching:                       Matching Control.    (line  27)
+* invert matching:                       Matching Control.    (line  40)
 * LANG environment variable:             Environment Variables.
                                                               (line 161)
 * language of messages:                  Environment Variables.
@@ -2137,22 +2137,21 @@ Index
                                                               (line  24)
 * match expression zero or more times:   Fundamental Structure.
                                                               (line  21)
-* match the whole line:                  Matching Control.    (line  41)
+* match the whole line:                  Matching Control.    (line  54)
 * matching basic regular expressions:    grep Programs.       (line  16)
 * matching extended regular expressions: grep Programs.       (line  21)
 * matching fixed strings:                grep Programs.       (line  26)
 * matching Perl regular expressions:     grep Programs.       (line  32)
-* matching whole words:                  Matching Control.    (line  32)
+* matching whole words:                  Matching Control.    (line  45)
 * max-count:                             General Output Control.
                                                               (line  42)
 * mc GREP_COLORS capability:             Environment Variables.
                                                               (line 116)
-* memory mapped input:                   Other Options.       (line  11)
 * message language:                      Environment Variables.
                                                               (line 175)
 * ms GREP_COLORS capability:             Environment Variables.
                                                               (line 108)
-* MS-DOS/MS-Windows binary files:        Other Options.       (line  19)
+* MS-DOS/MS-Windows binary files:        Other Options.       (line  12)
 * MS-DOS/MS-Windows byte offsets:        Output Line Prefix Control.
                                                               (line  53)
 * mt GREP_COLORS capability:             Environment Variables.
@@ -2182,7 +2181,7 @@ Index
                                                               (line 180)
 * print character class:                 Character Classes and Bracket Expressions.
                                                               (line  58)
-* print non-matching lines:              Matching Control.    (line  27)
+* print non-matching lines:              Matching Control.    (line  40)
 * printable characters:                  Character Classes and Bracket Expressions.
                                                               (line  58)
 * punct character class:                 Character Classes and Bracket Expressions.
@@ -2243,7 +2242,7 @@ Index
                                                               (line  76)
 * zero-terminated file names:            Output Line Prefix Control.
                                                               (line  63)
-* zero-terminated lines:                 Other Options.       (line  33)
+* zero-terminated lines:                 Other Options.       (line  26)
 * {,M}:                                  Fundamental Structure.
                                                               (line  33)
 * {N,M}:                                 Fundamental Structure.
@@ -2262,27 +2261,32 @@ Node: Invoking\7f2613
 Node: Command-line Options\7f3360
 Node: Generic Program Information\7f4237
 Node: Matching Control\7f4698
-Node: General Output Control\7f6149
-Ref: General Output Control-Footnote-1\7f10064
-Node: Output Line Prefix Control\7f10133
-Node: Context Line Control\7f13070
-Node: File and Directory Selection\7f15004
-Node: Other Options\7f18572
-Node: Environment Variables\7f20110
-Node: Exit Status\7f29608
-Node: grep Programs\7f30251
-Node: Regular Expressions\7f31671
-Node: Fundamental Structure\7f32825
-Node: Character Classes and Bracket Expressions\7f34552
-Ref: invalid-bracket-expr\7f37743
-Node: The Backslash Character and Special Expressions\7f38920
-Node: Anchoring\7f39921
-Node: Back-references and Subexpressions\7f40366
-Node: Basic vs Extended\7f41078
-Node: Usage\7f42075
-Node: Reporting Bugs\7f49334
-Node: Copying\7f49998
-Node: GNU Free Documentation License\7f51087
-Node: Index\7f76216
+Node: General Output Control\7f6947
+Ref: General Output Control-Footnote-1\7f10862
+Node: Output Line Prefix Control\7f10931
+Node: Context Line Control\7f13868
+Node: File and Directory Selection\7f15696
+Node: Other Options\7f19264
+Node: Environment Variables\7f20507
+Node: Exit Status\7f29986
+Node: grep Programs\7f30629
+Node: Regular Expressions\7f32049
+Node: Fundamental Structure\7f33203
+Node: Character Classes and Bracket Expressions\7f34930
+Ref: invalid-bracket-expr\7f38169
+Node: The Backslash Character and Special Expressions\7f39346
+Node: Anchoring\7f40347
+Node: Back-references and Subexpressions\7f40792
+Node: Basic vs Extended\7f41504
+Node: Usage\7f42501
+Node: Reporting Bugs\7f49585
+Node: Copying\7f50249
+Node: GNU Free Documentation License\7f51338
+Node: Index\7f76467
 \1f
 End Tag Table
+
+\1f
+Local Variables:
+coding: utf-8
+End:
index 473a181..feee0d8 100644 (file)
 @syncodeindex vr cp
 @c %**end of header
 
+@documentencoding UTF-8
+
 @copying
 This manual is for @command{grep}, a pattern matching engine.
 
-Copyright @copyright{} 1999-2002, 2005, 2008-2014 Free Software Foundation,
+Copyright @copyright{} 1999--2002, 2005, 2008--2014 Free Software Foundation,
 Inc.
 
 @quotation
@@ -193,7 +195,19 @@ The empty file contains zero patterns, and therefore matches nothing.
 @opindex -y
 @opindex --ignore-case
 @cindex case insensitive search
-Ignore case distinctions in both the pattern and the input files.
+Ignore case distinctions, so that characters that differ only in case
+match each other.  Although this is straightforward when letters
+differ in case only via lowercase-uppercase pairs, the behavior is
+unspecified in other situations.  For example, uppercase ``S'' has an
+unusual lowercase counterpart ``ſ'' (Unicode character U+017F, LATIN
+SMALL LETTER LONG S) in many locales, and it is unspecified whether
+this unusual character matches ``S'' or ``s'' even though uppercasing
+it yields ``S''.  Another example: the lowercase German letter ``ß''
+(U+00DF, LATIN SMALL LETTER SHARP S) is normally capitalized as the
+two-character string ``SS'' but it does not match ``SS'', and it might
+not match the uppercase letter ``ẞ'' (U+1E9E, LATIN CAPITAL LETTER
+SHARP S) even though lowercasing the latter yields the former.
+
 @option{-y} is an obsolete synonym that is provided for compatibility.
 (@option{-i} is specified by POSIX.)
 
@@ -518,14 +532,13 @@ Print @var{num} lines of leading and trailing output context.
 @opindex --group-separator
 @cindex group separator
 When @option{-A}, @option{-B} or @option{-C} are in use,
-print @var{string} instead of @option{--} around disjoint groups
-of lines.
+print @var{string} instead of @option{--} between groups of lines.
 
 @item --no-group-separator
 @opindex --group-separator
 @cindex group separator
 When @option{-A}, @option{-B} or @option{-C} are in use,
-print disjoint groups of lines adjacent to each other.
+do not print a separator between groups of lines.
 
 @end table
 
@@ -541,26 +554,25 @@ between prefix fields and actual line content.
 Context (i.e., non-matching) lines use @samp{-} instead.
 
 @item
-When no context is specified,
+When context is not specified,
 matching lines are simply output one right after another.
 
 @item
-When nonzero context is specified,
+When context is specified,
 lines that are adjacent in the input form a group
 and are output one right after another, while
-a separator appears by default between disjoint groups on a line
-of its own and without any prefix.
+by default a separator appears between non-adjacent groups.
 
 @item
 The default separator
-is @samp{--}, however whether to include it and its appearance
+is a @samp{--} line; its presence and appearance
 can be changed with the options above.
 
 @item
 Each group may contain
 several matching lines when they are close enough to each other
-that two otherwise adjacent but divided groups connect
-and can just merge into a single contiguous one.
+that two adjacent groups connect and can merge into a single
+contiguous one.
 @end itemize
 
 @node File and Directory Selection
@@ -706,15 +718,6 @@ directory, recursively, following all symbolic links.
 Use line buffering on output.
 This can cause a performance penalty.
 
-@item --mmap
-@opindex --mmap
-@cindex memory mapped input
-This option is deprecated and now elicits a warning, but is otherwise a no-op.
-It used to make @command{grep} read
-input with the @code{mmap} system call, instead of the default @code{read}
-system call.  On modern systems, @code{mmap} would rarely if ever yield
-better performance.
-
 @item -U
 @itemx --binary
 @opindex -U
@@ -960,8 +963,8 @@ They are omitted (i.e., false) by default and become true when specified.
 @cindex national language support
 @cindex NLS
 These variables specify the locale for the @code{LC_COLLATE} category,
-which determines the collating sequence
-used to interpret range expressions like @samp{[a-z]}.
+which might affect how range expressions like @samp{[a-z]} are
+interpreted.
 
 @item LC_ALL
 @itemx LC_CTYPE
@@ -1223,14 +1226,13 @@ For example, the regular expression
 Within a bracket expression, a @dfn{range expression} consists of two
 characters separated by a hyphen.
 It matches any single character that
-sorts between the two characters, inclusive, using the locale's
-collating sequence and character set.
-For example, in the default C
-locale, @samp{[a-d]} is equivalent to @samp{[abcd]}.
-Many locales sort
-characters in dictionary order, and in these locales @samp{[a-d]} is
-typically not equivalent to @samp{[abcd]};
-it might be equivalent to @samp{[aBbCcDd]}, for example.
+sorts between the two characters, inclusive.
+In the default C locale, the sorting sequence is the native character
+order; for example, @samp{[a-d]} is equivalent to @samp{[abcd]}.
+In other locales, the sorting sequence is not specified, and
+@samp{[a-d]} might be equivalent to @samp{[abcd]} or to
+@samp{[aBbCcDd]}, or it might fail to match any character, or the set of
+characters that it matches might even be erratic.
 To obtain the traditional interpretation
 of bracket expressions, you can use the @samp{C} locale by setting the
 @env{LC_ALL} environment variable to the value @samp{C}.
@@ -1715,25 +1717,19 @@ How can I match across lines?
 
 Standard grep cannot do this, as it is fundamentally line-based.
 Therefore, merely using the @code{[:space:]} character class does not
-match newlines in the way you might expect.  However, if your grep is
-compiled with Perl patterns enabled, the Perl @samp{s}
-modifier (which makes @code{.} match newlines) can be used:
-
-@example
-printf 'foo\nbar\n' | grep -P '(?s)foo.*?bar'
-@end example
+match newlines in the way you might expect.
 
 With the GNU @command{grep} option @code{-z} (@pxref{File and
 Directory Selection}), the input is terminated by null bytes.  Thus,
-you can match newlines in the input, but the output will be the whole
-file, so this is really only useful to determine if the pattern is
-present:
+you can match newlines in the input, but typically if there is a match
+the entire input is output, so this usage is often combined with
+output-suppressing options like @option{-q}, e.g.:
 
 @example
 printf 'foo\nbar\n' | grep -z -q 'foo[[:space:]]\+bar'
 @end example
 
-Failing either of those options, you need to transform the input
+If this does not suffice, you can transform the input
 before giving it to @command{grep}, or turn to @command{awk},
 @command{sed}, @command{perl}, or many other utilities that are
 designed to operate across lines.
index 341a372..3ed79fe 100644 (file)
@@ -1,4 +1,4 @@
-@set UPDATED 1 January 2014
-@set UPDATED-MONTH January 2014
-@set EDITION 2.16
-@set VERSION 2.16
+@set UPDATED 10 May 2014
+@set UPDATED-MONTH May 2014
+@set EDITION 2.19
+@set VERSION 2.19
index 341a372..3ed79fe 100644 (file)
@@ -1,4 +1,4 @@
-@set UPDATED 1 January 2014
-@set UPDATED-MONTH January 2014
-@set EDITION 2.16
-@set VERSION 2.16
+@set UPDATED 10 May 2014
+@set UPDATED-MONTH May 2014
+@set EDITION 2.19
+@set VERSION 2.19
index b8b28bd..0e11d68 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -136,7 +136,8 @@ TESTS = test-alloca-opt$(EXEEXT) test-argmatch$(EXEEXT) \
        test-mbsinit.sh test-mbsrtowcs1.sh test-mbsrtowcs2.sh \
        test-mbsrtowcs3.sh test-mbsrtowcs4.sh test-mbsstr1$(EXEEXT) \
        test-mbsstr2.sh test-mbsstr3.sh test-memchr$(EXEEXT) \
-       test-memrchr$(EXEEXT) test-nl_langinfo.sh test-open$(EXEEXT) \
+       test-memchr2$(EXEEXT) test-memrchr$(EXEEXT) \
+       test-nl_langinfo.sh test-open$(EXEEXT) \
        test-openat-safer$(EXEEXT) test-openat$(EXEEXT) \
        test-pathmax$(EXEEXT) test-pipe$(EXEEXT) \
        test-quotearg-simple$(EXEEXT) test-read$(EXEEXT) \
@@ -195,10 +196,10 @@ check_PROGRAMS = test-alloca-opt$(EXEEXT) test-argmatch$(EXEEXT) \
        test-mbscasecmp$(EXEEXT) test-mbsinit$(EXEEXT) \
        test-mbsrtowcs$(EXEEXT) test-mbsstr1$(EXEEXT) \
        test-mbsstr2$(EXEEXT) test-mbsstr3$(EXEEXT) \
-       test-memchr$(EXEEXT) test-memrchr$(EXEEXT) \
-       test-nl_langinfo$(EXEEXT) test-open$(EXEEXT) \
-       test-openat-safer$(EXEEXT) test-openat$(EXEEXT) \
-       test-pathmax$(EXEEXT) test-pipe$(EXEEXT) \
+       test-memchr$(EXEEXT) test-memchr2$(EXEEXT) \
+       test-memrchr$(EXEEXT) test-nl_langinfo$(EXEEXT) \
+       test-open$(EXEEXT) test-openat-safer$(EXEEXT) \
+       test-openat$(EXEEXT) test-pathmax$(EXEEXT) test-pipe$(EXEEXT) \
        test-quotearg-simple$(EXEEXT) test-read$(EXEEXT) \
        test-realloc-gnu$(EXEEXT) test-regex$(EXEEXT) \
        test-setenv$(EXEEXT) test-setlocale1$(EXEEXT) \
@@ -656,6 +657,11 @@ test_memchr_OBJECTS = test-memchr.$(OBJEXT)
 test_memchr_LDADD = $(LDADD)
 test_memchr_DEPENDENCIES = libtests.a ../lib/libgreputils.a libtests.a \
        $(am__DEPENDENCIES_1)
+test_memchr2_SOURCES = test-memchr2.c
+test_memchr2_OBJECTS = test-memchr2.$(OBJEXT)
+test_memchr2_LDADD = $(LDADD)
+test_memchr2_DEPENDENCIES = libtests.a ../lib/libgreputils.a \
+       libtests.a $(am__DEPENDENCIES_1)
 test_memrchr_SOURCES = test-memrchr.c
 test_memrchr_OBJECTS = test-memrchr.$(OBJEXT)
 test_memrchr_LDADD = $(LDADD)
@@ -936,8 +942,8 @@ SOURCES = $(libtests_a_SOURCES) $(EXTRA_libtests_a_SOURCES) \
        test-malloca.c test-mbrtowc.c test-mbrtowc-w32.c \
        test-mbscasecmp.c test-mbsinit.c test-mbsrtowcs.c \
        test-mbsstr1.c test-mbsstr2.c test-mbsstr3.c test-memchr.c \
-       test-memrchr.c test-nl_langinfo.c test-open.c test-openat.c \
-       test-openat-safer.c test-pathmax.c test-pipe.c \
+       test-memchr2.c test-memrchr.c test-nl_langinfo.c test-open.c \
+       test-openat.c test-openat-safer.c test-pathmax.c test-pipe.c \
        test-quotearg-simple.c test-read.c test-realloc-gnu.c \
        test-regex.c test-setenv.c test-setlocale1.c test-setlocale2.c \
        test-snprintf.c test-stat.c test-stdbool.c test-stddef.c \
@@ -972,8 +978,8 @@ DIST_SOURCES = $(libtests_a_SOURCES) $(EXTRA_libtests_a_SOURCES) \
        test-malloca.c test-mbrtowc.c test-mbrtowc-w32.c \
        test-mbscasecmp.c test-mbsinit.c test-mbsrtowcs.c \
        test-mbsstr1.c test-mbsstr2.c test-mbsstr3.c test-memchr.c \
-       test-memrchr.c test-nl_langinfo.c test-open.c test-openat.c \
-       test-openat-safer.c test-pathmax.c test-pipe.c \
+       test-memchr2.c test-memrchr.c test-nl_langinfo.c test-open.c \
+       test-openat.c test-openat-safer.c test-pathmax.c test-pipe.c \
        test-quotearg-simple.c test-read.c test-realloc-gnu.c \
        test-regex.c test-setenv.c test-setlocale1.c test-setlocale2.c \
        test-snprintf.c test-stat.c test-stdbool.c test-stddef.c \
@@ -2029,6 +2035,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -2179,9 +2186,10 @@ EXTRA_DIST = test-alloca-opt.c test-argmatch.c macros.h \
        test-mbsrtowcs4.sh test-mbsrtowcs.c signature.h macros.h \
        test-mbsstr1.c test-mbsstr2.sh test-mbsstr2.c test-mbsstr3.sh \
        test-mbsstr3.c macros.h test-memchr.c zerosize-ptr.h \
-       signature.h macros.h test-memrchr.c zerosize-ptr.h signature.h \
-       macros.h test-nl_langinfo.sh test-nl_langinfo.c signature.h \
-       macros.h test-open.h test-open.c signature.h macros.h \
+       signature.h macros.h test-memchr2.c zerosize-ptr.h macros.h \
+       test-memrchr.c zerosize-ptr.h signature.h macros.h \
+       test-nl_langinfo.sh test-nl_langinfo.c signature.h macros.h \
+       test-open.h test-open.c signature.h macros.h \
        test-openat-safer.c macros.h test-openat.c test-open.h \
        signature.h macros.h test-pathmax.c pipe.c test-pipe.c \
        signature.h macros.h putenv.c test-quotearg-simple.c \
@@ -2321,7 +2329,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am $(srcdir)/gnulib.mk $(am__configur
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign gnulib-tests/Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --foreign gnulib-tests/Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -2626,6 +2633,10 @@ test-memchr$(EXEEXT): $(test_memchr_OBJECTS) $(test_memchr_DEPENDENCIES) $(EXTRA
        @rm -f test-memchr$(EXEEXT)
        $(AM_V_CCLD)$(LINK) $(test_memchr_OBJECTS) $(test_memchr_LDADD) $(LIBS)
 
+test-memchr2$(EXEEXT): $(test_memchr2_OBJECTS) $(test_memchr2_DEPENDENCIES) $(EXTRA_test_memchr2_DEPENDENCIES) 
+       @rm -f test-memchr2$(EXEEXT)
+       $(AM_V_CCLD)$(LINK) $(test_memchr2_OBJECTS) $(test_memchr2_LDADD) $(LIBS)
+
 test-memrchr$(EXEEXT): $(test_memrchr_OBJECTS) $(test_memrchr_DEPENDENCIES) $(EXTRA_test_memrchr_DEPENDENCIES) 
        @rm -f test-memrchr$(EXEEXT)
        $(AM_V_CCLD)$(LINK) $(test_memrchr_OBJECTS) $(test_memrchr_LDADD) $(LIBS)
@@ -2949,6 +2960,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-mbsstr2.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-mbsstr3.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-memchr.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-memchr2.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-memrchr.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-nl_langinfo.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-open.Po@am__quote@
@@ -3152,7 +3164,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
        if test -n "$$am__remaking_logs"; then \
          echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
               "recursion detected" >&2; \
-       else \
+       elif test -n "$$redo_logs"; then \
          am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
        fi; \
        if $(am__make_dryrun); then :; else \
@@ -3844,6 +3856,13 @@ test-memchr.log: test-memchr$(EXEEXT)
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+test-memchr2.log: test-memchr2$(EXEEXT)
+       @p='test-memchr2$(EXEEXT)'; \
+       b='test-memchr2'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 test-memrchr.log: test-memrchr$(EXEEXT)
        @p='test-memrchr$(EXEEXT)'; \
        b='test-memrchr'; \
@@ -4483,6 +4502,8 @@ uninstall-am:
        mostlyclean-local pdf pdf-am ps ps-am recheck tags tags-am \
        uninstall uninstall-am
 
+.PRECIOUS: Makefile
+
 
 # We need the following in order to create <float.h> when the system
 # doesn't have one that works with the given compiler.
index 2aaf249..386064d 100644 (file)
@@ -692,6 +692,14 @@ EXTRA_DIST += test-memchr.c zerosize-ptr.h signature.h macros.h
 
 ## end   gnulib module memchr-tests
 
+## begin gnulib module memchr2-tests
+
+TESTS += test-memchr2
+check_PROGRAMS += test-memchr2
+EXTRA_DIST += test-memchr2.c zerosize-ptr.h macros.h
+
+## end   gnulib module memchr2-tests
+
 ## begin gnulib module memrchr-tests
 
 TESTS += test-memrchr
index b5c2e3f..fbd293d 100644 (file)
@@ -201,6 +201,8 @@ else
       *x*) opts_=-x ;;
       *) opts_= ;;
     esac
+    re_shell=$re_shell_
+    export re_shell
     exec "$re_shell_" $opts_ "$0" --no-reexec "$@"
     echo "$ME_: exec failed" 1>&2
     exit 127
index 96a887f..743511e 100644 (file)
@@ -29,28 +29,21 @@ SIGNATURE_CHECK (fdopen, FILE *, (int, const char *));
 int
 main (void)
 {
-  /* Test behaviour for invalid file descriptors.  */
-  {
-    FILE *fp;
-
-    errno = 0;
-    fp = fdopen (-1, "r");
-    if (fp == NULL)
-      ASSERT (errno == EBADF);
-    else
-      fclose (fp);
-  }
-  {
-    FILE *fp;
-
-    close (99);
-    errno = 0;
-    fp = fdopen (99, "r");
-    if (fp == NULL)
-      ASSERT (errno == EBADF);
-    else
-      fclose (fp);
-  }
+  /* Test behavior on failure.  POSIX makes it hard to check for
+     failure, since the behavior is not well-defined on invalid file
+     descriptors, so try fdopen 1000 times and if that's not enough to
+     fail due to EMFILE, so be it.  */
+
+  int i;
+  for (i = 0; i < 1000; i++)
+    {
+      errno = 0;
+      if (! fdopen (STDOUT_FILENO, "w"))
+        {
+          ASSERT (errno != 0);
+          break;
+        }
+    }
 
   return 0;
 }
diff --git a/gnulib-tests/test-memchr2.c b/gnulib-tests/test-memchr2.c
new file mode 100644 (file)
index 0000000..dc131c3
--- /dev/null
@@ -0,0 +1,100 @@
+/*
+ * Copyright (C) 2008-2014 Free Software Foundation, Inc.
+ * Written by Eric Blake
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#include <config.h>
+
+#include "memchr2.h"
+
+#include <stdlib.h>
+#include <string.h>
+
+#include "zerosize-ptr.h"
+#include "macros.h"
+
+/* Calculating void * + int is not portable, so this wrapper converts
+   to char * to make the tests easier to write.  */
+#define MEMCHR2 (char *) memchr2
+
+int
+main (void)
+{
+  size_t n = 0x100000;
+  char *input = malloc (n);
+  ASSERT (input);
+
+  input[0] = 'a';
+  input[1] = 'b';
+  memset (input + 2, 'c', 1024);
+  memset (input + 1026, 'd', n - 1028);
+  input[n - 2] = 'e';
+  input[n - 1] = 'a';
+
+  /* Basic behavior tests.  */
+  ASSERT (MEMCHR2 (input, 'a', 'b', n) == input);
+  ASSERT (MEMCHR2 (input, 'b', 'a', n) == input);
+
+  ASSERT (MEMCHR2 (input, 'a', 'b', 0) == NULL);
+  ASSERT (MEMCHR2 (zerosize_ptr (), 'a', 'b', 0) == NULL);
+
+  ASSERT (MEMCHR2 (input, 'b', 'd', n) == input + 1);
+  ASSERT (MEMCHR2 (input + 2, 'b', 'd', n - 2) == input + 1026);
+
+  ASSERT (MEMCHR2 (input, 'd', 'e', n) == input + 1026);
+  ASSERT (MEMCHR2 (input, 'e', 'd', n) == input + 1026);
+
+  ASSERT (MEMCHR2 (input + 1, 'a', 'e', n - 1) == input + n - 2);
+  ASSERT (MEMCHR2 (input + 1, 'e', 'a', n - 1) == input + n - 2);
+
+  ASSERT (MEMCHR2 (input, 'f', 'g', n) == NULL);
+  ASSERT (MEMCHR2 (input, 'f', '\0', n) == NULL);
+
+  ASSERT (MEMCHR2 (input, 'a', 'a', n) == input);
+  ASSERT (MEMCHR2 (input + 1, 'a', 'a', n - 1) == input + n - 1);
+  ASSERT (MEMCHR2 (input, 'f', 'f', n) == NULL);
+
+  /* Check that a very long haystack is handled quickly if one of the
+     two bytes is found near the beginning.  */
+  {
+    size_t repeat = 10000;
+    for (; repeat > 0; repeat--)
+      {
+        ASSERT (MEMCHR2 (input, 'c', 'e', n) == input + 2);
+        ASSERT (MEMCHR2 (input, 'e', 'c', n) == input + 2);
+        ASSERT (MEMCHR2 (input, 'c', '\0', n) == input + 2);
+        ASSERT (MEMCHR2 (input, '\0', 'c', n) == input + 2);
+      }
+  }
+
+  /* Alignment tests.  */
+  {
+    int i, j;
+    for (i = 0; i < 32; i++)
+      {
+        for (j = 0; j < 256; j++)
+          input[i + j] = j;
+        for (j = 0; j < 256; j++)
+          {
+            ASSERT (MEMCHR2 (input + i, j, 0xff, 256) == input + i + j);
+            ASSERT (MEMCHR2 (input + i, 0xff, j, 256) == input + i + j);
+          }
+      }
+  }
+
+  free (input);
+
+  return 0;
+}
index 5161afc..e274aa8 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -51,7 +51,7 @@
 # the same distribution terms as the rest of that program.
 #
 # Generated by gnulib-tool.
-# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl --lib=libgreputils --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=gnulib-tests --aux-dir=build-aux --with-tests --avoid=lock-tests --makefile-name=gnulib.mk --no-conditional-dependencies --no-libtool --macro-prefix=gl alloca announce-gen argmatch binary-io btowc c-ctype closeout do-release-commit-and-tag error exclude fcntl-h fnmatch fstatat fts getopt-gnu getpagesize gettext-h git-version-gen gitlog-to-changelog gnu-web-doc-update gnupload ignore-value intprops inttypes isatty isblank iswctype largefile locale lseek maintainer-makefile malloc-gnu manywarnings mbrlen mbrtowc memchr mempcpy minmax obstack openat-safer perl progname propername quote readme-release realloc-gnu regex safe-read same-inode ssize_t stddef stdlib stpcpy strerror string strtoull strtoumax sys_stat unistd unlocked-io update-copyright useless-if-before-free version-etc-fsf wchar wcrtomb wctob wctype-h xalloc xstrtoimax
+# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl --lib=libgreputils --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=gnulib-tests --aux-dir=build-aux --with-tests --avoid=lock-tests --makefile-name=gnulib.mk --no-conditional-dependencies --no-libtool --macro-prefix=gl alloca announce-gen argmatch binary-io btowc c-ctype closeout do-release-commit-and-tag error exclude fcntl-h fnmatch fstatat fts getopt-gnu getpagesize gettext-h git-version-gen gitlog-to-changelog gnu-web-doc-update gnupload ignore-value intprops inttypes isatty isblank iswctype largefile locale lseek maintainer-makefile malloc-gnu manywarnings mbrlen mbrtowc memchr memchr2 mempcpy minmax obstack openat-safer perl progname propername quote readme-release realloc-gnu regex safe-read same-inode ssize_t stddef stdlib stpcpy strerror string strtoull strtoumax sys_stat unistd unlocked-io update-copyright useless-if-before-free version-etc-fsf wchar wcrtomb wctob wctype-h xalloc xstrtoimax
 
 VPATH = @srcdir@
 am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
@@ -238,11 +238,11 @@ am__libgreputils_a_SOURCES_DIST = argmatch.c binary-io.h binary-io.c \
        gettext.h hash.c i-ring.c localcharset.h localcharset.c \
        glthread/lock.h glthread/lock.c malloca.c mbchar.c mbiter.h \
        mbiter.c mbscasecmp.c mbslen.c mbsstr.c mbuiter.h mbuiter.c \
-       minmax.h openat-die.c openat-safer.c progname.h progname.c \
-       propername.h propername.c quotearg.c safe-read.c save-cwd.c \
-       striconv.h striconv.c strnlen1.h strnlen1.c \
-       glthread/threadlib.c trim.c unistd.c dup-safer.c fd-safer.c \
-       pipe-safer.c unistr/u8-mbtoucr.c unistr/u8-uctomb.c \
+       memchr2.h memchr2.c minmax.h openat-die.c openat-safer.c \
+       progname.h progname.c propername.h propername.c quotearg.c \
+       safe-read.c save-cwd.c striconv.h striconv.c strnlen1.h \
+       strnlen1.c glthread/threadlib.c trim.c unistd.c dup-safer.c \
+       fd-safer.c pipe-safer.c unistr/u8-mbtoucr.c unistr/u8-uctomb.c \
        unistr/u8-uctomb-aux.c uniwidth/width.c version-etc.h \
        version-etc.c version-etc-fsf.c wctype-h.c xmalloc.c \
        xalloc-die.c xstriconv.h xstriconv.c xstrtoimax.c xstrtol.c \
@@ -264,17 +264,17 @@ am_libgreputils_a_OBJECTS = argmatch.$(OBJEXT) binary-io.$(OBJEXT) \
        localcharset.$(OBJEXT) glthread/lock.$(OBJEXT) \
        malloca.$(OBJEXT) mbchar.$(OBJEXT) mbiter.$(OBJEXT) \
        mbscasecmp.$(OBJEXT) mbslen.$(OBJEXT) mbsstr.$(OBJEXT) \
-       mbuiter.$(OBJEXT) openat-die.$(OBJEXT) openat-safer.$(OBJEXT) \
-       progname.$(OBJEXT) propername.$(OBJEXT) quotearg.$(OBJEXT) \
-       safe-read.$(OBJEXT) save-cwd.$(OBJEXT) striconv.$(OBJEXT) \
-       strnlen1.$(OBJEXT) glthread/threadlib.$(OBJEXT) trim.$(OBJEXT) \
-       unistd.$(OBJEXT) dup-safer.$(OBJEXT) fd-safer.$(OBJEXT) \
-       pipe-safer.$(OBJEXT) $(am__objects_1) $(am__objects_2) \
-       $(am__objects_3) version-etc.$(OBJEXT) \
-       version-etc-fsf.$(OBJEXT) wctype-h.$(OBJEXT) xmalloc.$(OBJEXT) \
-       xalloc-die.$(OBJEXT) xstriconv.$(OBJEXT) xstrtoimax.$(OBJEXT) \
-       xstrtol.$(OBJEXT) xstrtoul.$(OBJEXT) xstrtol-error.$(OBJEXT) \
-       colorize.$(OBJEXT)
+       mbuiter.$(OBJEXT) memchr2.$(OBJEXT) openat-die.$(OBJEXT) \
+       openat-safer.$(OBJEXT) progname.$(OBJEXT) propername.$(OBJEXT) \
+       quotearg.$(OBJEXT) safe-read.$(OBJEXT) save-cwd.$(OBJEXT) \
+       striconv.$(OBJEXT) strnlen1.$(OBJEXT) \
+       glthread/threadlib.$(OBJEXT) trim.$(OBJEXT) unistd.$(OBJEXT) \
+       dup-safer.$(OBJEXT) fd-safer.$(OBJEXT) pipe-safer.$(OBJEXT) \
+       $(am__objects_1) $(am__objects_2) $(am__objects_3) \
+       version-etc.$(OBJEXT) version-etc-fsf.$(OBJEXT) \
+       wctype-h.$(OBJEXT) xmalloc.$(OBJEXT) xalloc-die.$(OBJEXT) \
+       xstriconv.$(OBJEXT) xstrtoimax.$(OBJEXT) xstrtol.$(OBJEXT) \
+       xstrtoul.$(OBJEXT) xstrtol-error.$(OBJEXT) colorize.$(OBJEXT)
 libgreputils_a_OBJECTS = $(am_libgreputils_a_OBJECTS)
 AM_V_P = $(am__v_P_@AM_V@)
 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
@@ -1103,6 +1103,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -1247,11 +1248,11 @@ EXTRA_DIST = alloca.c alloca.in.h $(top_srcdir)/build-aux/announce-gen \
        malloc.c malloca.h malloca.valgrind mbchar.h mbrlen.c \
        mbrtowc.c mbsinit.c mbsrtowcs-impl.h mbsrtowcs-state.c \
        mbsrtowcs.c str-kmp.h mbtowc-impl.h mbtowc.c memchr.c \
-       memchr.valgrind mempcpy.c memrchr.c msvc-inval.c msvc-inval.h \
-       msvc-nothrow.c msvc-nothrow.h nl_langinfo.c obstack.c \
-       obstack.h open.c openat.c openat.h fcntl--.h fcntl-safer.h \
-       dirent-private.h opendir.c pathmax.h quote.h quote.h \
-       quotearg.h read.c dirent-private.h readdir.c \
+       memchr.valgrind memchr2.valgrind mempcpy.c memrchr.c \
+       msvc-inval.c msvc-inval.h msvc-nothrow.c msvc-nothrow.h \
+       nl_langinfo.c obstack.c obstack.h open.c openat.c openat.h \
+       fcntl--.h fcntl-safer.h dirent-private.h opendir.c pathmax.h \
+       quote.h quote.h quotearg.h read.c dirent-private.h readdir.c \
        $(top_srcdir)/README-release realloc.c realloc.c regcomp.c \
        regex.c regex.h regex_internal.c regex_internal.h regexec.c \
        safe-read.h same-inode.h save-cwd.h \
@@ -1303,14 +1304,15 @@ libgreputils_a_SOURCES = argmatch.c binary-io.h binary-io.c \
        gettext.h hash.c i-ring.c localcharset.h localcharset.c \
        glthread/lock.h glthread/lock.c malloca.c mbchar.c mbiter.h \
        mbiter.c mbscasecmp.c mbslen.c mbsstr.c mbuiter.h mbuiter.c \
-       minmax.h openat-die.c openat-safer.c progname.h progname.c \
-       propername.h propername.c quotearg.c safe-read.c save-cwd.c \
-       striconv.h striconv.c strnlen1.h strnlen1.c \
-       glthread/threadlib.c trim.c unistd.c dup-safer.c fd-safer.c \
-       pipe-safer.c $(am__append_1) $(am__append_2) $(am__append_3) \
-       version-etc.h version-etc.c version-etc-fsf.c wctype-h.c \
-       xmalloc.c xalloc-die.c xstriconv.h xstriconv.c xstrtoimax.c \
-       xstrtol.c xstrtoul.c xstrtol-error.c colorize.c colorize.h
+       memchr2.h memchr2.c minmax.h openat-die.c openat-safer.c \
+       progname.h progname.c propername.h propername.c quotearg.c \
+       safe-read.c save-cwd.c striconv.h striconv.c strnlen1.h \
+       strnlen1.c glthread/threadlib.c trim.c unistd.c dup-safer.c \
+       fd-safer.c pipe-safer.c $(am__append_1) $(am__append_2) \
+       $(am__append_3) version-etc.h version-etc.c version-etc-fsf.c \
+       wctype-h.c xmalloc.c xalloc-die.c xstriconv.h xstriconv.c \
+       xstrtoimax.c xstrtol.c xstrtoul.c xstrtol-error.c colorize.c \
+       colorize.h
 libgreputils_a_LIBADD = $(gl_LIBOBJS) @ALLOCA@ $(LIBOBJS) $(ALLOCA)
 libgreputils_a_DEPENDENCIES = $(gl_LIBOBJS) @ALLOCA@ $(LIBOBJS) \
        $(ALLOCA)
@@ -1363,7 +1365,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am $(srcdir)/gnulib.mk $(am__configur
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lib/Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --gnu lib/Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -1505,6 +1506,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mbtowc.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mbuiter.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memchr.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memchr2.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mempcpy.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memrchr.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msvc-inval.Po@am__quote@
@@ -1800,6 +1802,8 @@ uninstall-am: uninstall-local
        mostlyclean-generic mostlyclean-local pdf pdf-am ps ps-am tags \
        tags-am uninstall uninstall-am uninstall-local
 
+.PRECIOUS: Makefile
+
 
 # We need the following in order to create <alloca.h> when the system
 # doesn't have one that works with the given compiler.
index 0865cee..14b59b7 100644 (file)
@@ -32,6 +32,7 @@
 #include <stdlib.h>
 #include <string.h>
 #include <wctype.h>
+#include <regex.h>
 
 #include "exclude.h"
 #include "hash.h"
@@ -39,6 +40,7 @@
 #include "fnmatch.h"
 #include "xalloc.h"
 #include "verify.h"
+#include "filename.h"
 
 #if USE_UNLOCKED_IO
 # include "unlocked-io.h"
@@ -73,8 +75,12 @@ verify (((EXCLUDE_ANCHORED | EXCLUDE_INCLUDE | EXCLUDE_WILDCARDS)
 
 struct patopts
   {
-    char const *pattern;
     int options;
+    union
+    {
+      char const *pattern;
+      regex_t re;
+    } v;
   };
 
 /* An array of pattern-options pairs.  */
@@ -104,13 +110,33 @@ struct exclude_segment
     } v;
   };
 
+struct pattern_buffer
+  {
+    struct pattern_buffer *next;
+    char *base;
+  };
+
 /* The exclude structure keeps a singly-linked list of exclude segments,
    maintained in reverse order.  */
 struct exclude
   {
     struct exclude_segment *head;
+    struct pattern_buffer *patbuf;
   };
 
+/* Register BUF in the pattern buffer list of EX.  ADD_FUNC (see
+   add_exclude_file and add_exclude_fp below) can use this function
+   if it modifies the pattern, to ensure the allocated memory will be
+   properly reclaimed upon calling free_exclude. */
+void
+exclude_add_pattern_buffer (struct exclude *ex, char *buf)
+{
+  struct pattern_buffer *pbuf = xmalloc (sizeof *pbuf);
+  pbuf->base = buf;
+  pbuf->next = ex->patbuf;
+  ex->patbuf = pbuf;
+}
+
 /* Return true if STR has or may have wildcards, when matched with OPTIONS.
    Return false if STR definitely does not have wildcards.  */
 bool
@@ -120,8 +146,20 @@ fnmatch_pattern_has_wildcards (const char *str, int options)
     {
       switch (*str++)
         {
+       case '.':
+       case '{':
+       case '}':
+       case '(':
+       case ')':
+         if (options & EXCLUDE_REGEX)
+           return true;
+         break;
+
         case '\\':
-          str += ! (options & FNM_NOESCAPE) && *str;
+         if (options & EXCLUDE_REGEX)
+           continue;
+         else
+           str += ! (options & FNM_NOESCAPE) && *str;
           break;
 
         case '+': case '@': case '!':
@@ -243,9 +281,16 @@ new_exclude_segment (struct exclude *ex, enum exclude_type type, int options)
 static void
 free_exclude_segment (struct exclude_segment *seg)
 {
+  size_t i;
+
   switch (seg->type)
     {
     case exclude_pattern:
+      for (i = 0; i < seg->v.pat.exclude_count; i++)
+       {
+         if (seg->v.pat.exclude[i].options & EXCLUDE_REGEX)
+           regfree (&seg->v.pat.exclude[i].v.re);
+       }
       free (seg->v.pat.exclude);
       break;
 
@@ -261,12 +306,23 @@ void
 free_exclude (struct exclude *ex)
 {
   struct exclude_segment *seg;
+  struct pattern_buffer *pbuf;
+
   for (seg = ex->head; seg; )
     {
       struct exclude_segment *next = seg->next;
       free_exclude_segment (seg);
       seg = next;
     }
+
+  for (pbuf = ex->patbuf; pbuf; )
+    {
+      struct pattern_buffer *next = pbuf->next;
+      free (pbuf->base);
+      free (pbuf);
+      pbuf = next;
+    }
+
   free (ex);
 }
 
@@ -331,11 +387,21 @@ exclude_fnmatch (char const *pattern, char const *f, int options)
   if (! (options & EXCLUDE_ANCHORED))
     for (p = f; *p && ! matched; p++)
       if (*p == '/' && p[1] != '/')
-        matched = ((*matcher) (pattern, p + 1, options) == 0);
+       matched = ((*matcher) (pattern, p + 1, options) == 0);
 
   return matched;
 }
 
+bool
+exclude_patopts (struct patopts const *opts, char const *f)
+{
+  int options = opts->options;
+
+  return (options & EXCLUDE_REGEX)
+          ? regexec (&opts->v.re, f, 0, NULL, 0) == 0
+          : exclude_fnmatch (opts->v.pattern, f, options);
+}
+
 /* Return true if the exclude_pattern segment SEG matches F.  */
 
 static bool
@@ -347,9 +413,7 @@ file_pattern_matches (struct exclude_segment const *seg, char const *f)
 
   for (i = 0; i < exclude_count; i++)
     {
-      char const *pattern = exclude[i].pattern;
-      int options = exclude[i].options;
-      if (exclude_fnmatch (pattern, f, options))
+      if (exclude_patopts (exclude + i, f))
         return true;
     }
   return false;
@@ -454,17 +518,17 @@ void
 add_exclude (struct exclude *ex, char const *pattern, int options)
 {
   struct exclude_segment *seg;
+  struct exclude_pattern *pat;
+  struct patopts *patopts;
 
-  if ((options & EXCLUDE_WILDCARDS)
+  if ((options & (EXCLUDE_REGEX|EXCLUDE_WILDCARDS))
       && fnmatch_pattern_has_wildcards (pattern, options))
     {
-      struct exclude_pattern *pat;
-      struct patopts *patopts;
-
       if (! (ex->head && ex->head->type == exclude_pattern
-             && ((ex->head->options & EXCLUDE_INCLUDE)
-                 == (options & EXCLUDE_INCLUDE))))
-        new_exclude_segment (ex, exclude_pattern, options);
+            && ((ex->head->options & EXCLUDE_INCLUDE)
+                == (options & EXCLUDE_INCLUDE))))
+       new_exclude_segment (ex, exclude_pattern, options);
+
       seg = ex->head;
 
       pat = &seg->v.pat;
@@ -472,8 +536,51 @@ add_exclude (struct exclude *ex, char const *pattern, int options)
         pat->exclude = x2nrealloc (pat->exclude, &pat->exclude_alloc,
                                    sizeof *pat->exclude);
       patopts = &pat->exclude[pat->exclude_count++];
-      patopts->pattern = pattern;
+
       patopts->options = options;
+      if (options & EXCLUDE_REGEX)
+       {
+         int rc;
+         int cflags = REG_NOSUB|REG_EXTENDED|
+                      ((options & FNM_CASEFOLD) ? REG_ICASE : 0);
+
+         if (options & FNM_LEADING_DIR)
+           {
+             char *tmp;
+             size_t len = strlen (pattern);
+
+             while (len > 0 && ISSLASH (pattern[len-1]))
+               --len;
+
+             if (len == 0)
+               rc = 1;
+             else
+               {
+                 tmp = xmalloc (len + 7);
+                 memcpy (tmp, pattern, len);
+                 strcpy (tmp + len, "(/.*)?");
+                 rc = regcomp (&patopts->v.re, tmp, cflags);
+                 free (tmp);
+               }
+           }
+         else
+           rc = regcomp (&patopts->v.re, pattern, cflags);
+
+         if (rc)
+           {
+             pat->exclude_count--;
+             return;
+           }
+       }
+      else
+       {
+         if (options & EXCLUDE_ALLOC)
+           {
+             pattern = xstrdup (pattern);
+             exclude_add_pattern_buffer (ex, (char*) pattern);
+           }
+         patopts->v.pattern = pattern;
+       }
     }
   else
     {
@@ -498,45 +605,39 @@ add_exclude (struct exclude *ex, char const *pattern, int options)
 /* Use ADD_FUNC to append to EX the patterns in FILE_NAME, each with
    OPTIONS.  LINE_END terminates each pattern in the file.  If
    LINE_END is a space character, ignore trailing spaces and empty
-   lines in FILE.  Return -1 on failure, 0 on success.  */
+   lines in FP.  Return -1 on failure, 0 on success.  */
 
 int
-add_exclude_file (void (*add_func) (struct exclude *, char const *, int),
-                  struct exclude *ex, char const *file_name, int options,
-                  char line_end)
+add_exclude_fp (void (*add_func) (struct exclude *, char const *, int, void *),
+               struct exclude *ex, FILE *fp, int options,
+               char line_end,
+               void *data)
 {
-  bool use_stdin = file_name[0] == '-' && !file_name[1];
-  FILE *in;
   char *buf = NULL;
   char *p;
-  char const *pattern;
+  char *pattern;
   char const *lim;
   size_t buf_alloc = 0;
   size_t buf_count = 0;
   int c;
   int e = 0;
 
-  if (use_stdin)
-    in = stdin;
-  else if (! (in = fopen (file_name, "r")))
-    return -1;
-
-  while ((c = getc (in)) != EOF)
+  while ((c = getc (fp)) != EOF)
     {
       if (buf_count == buf_alloc)
         buf = x2realloc (buf, &buf_alloc);
       buf[buf_count++] = c;
     }
 
-  if (ferror (in))
-    e = errno;
-
-  if (!use_stdin && fclose (in) != 0)
+  if (ferror (fp))
     e = errno;
 
   buf = xrealloc (buf, buf_count + 1);
   buf[buf_count] = line_end;
   lim = buf + buf_count + ! (buf_count == 0 || buf[buf_count - 1] == line_end);
+
+  exclude_add_pattern_buffer (ex, buf);
+
   pattern = buf;
 
   for (p = buf; p < lim; p++)
@@ -554,7 +655,7 @@ add_exclude_file (void (*add_func) (struct exclude *, char const *, int),
           }
 
         *pattern_end = '\0';
-        (*add_func) (ex, pattern, options);
+        (*add_func) (ex, pattern, options, data);
 
       next_pattern:
         pattern = p + 1;
@@ -563,3 +664,32 @@ add_exclude_file (void (*add_func) (struct exclude *, char const *, int),
   errno = e;
   return e ? -1 : 0;
 }
+
+static void
+call_addfn (struct exclude *ex, char const *pattern, int options, void *data)
+{
+  void (**addfnptr) (struct exclude *, char const *, int) = data;
+  (*addfnptr) (ex, pattern, options);
+}
+
+int
+add_exclude_file (void (*add_func) (struct exclude *, char const *, int),
+                 struct exclude *ex, char const *file_name, int options,
+                 char line_end)
+{
+  bool use_stdin = file_name[0] == '-' && !file_name[1];
+  FILE *in;
+  int rc = 0;
+
+  if (use_stdin)
+    in = stdin;
+  else if (! (in = fopen (file_name, "r")))
+    return -1;
+
+  rc = add_exclude_fp (call_addfn, ex, in, options, line_end, &add_func);
+
+  if (!use_stdin && fclose (in) != 0)
+    rc = -1;
+
+  return rc;
+}
index 45dbe69..9555218 100644 (file)
@@ -20,6 +20,7 @@
 #define _GL_EXCLUDE_H 1
 
 #include <stdbool.h>
+#include <stdio.h>
 
 /* Written by Paul Eggert <eggert@twinsun.com>
    and Sergey Poznyakoff <gray@gnu.org> */
    option, these characters are ordinary and fnmatch is not used.  */
 #define EXCLUDE_WILDCARDS (1 << 28)
 
+/* Patterns are POSIX extended regular expressions */
+#define EXCLUDE_REGEX     (1 << 27)
+
+/* Allocate storage for the pattern */
+#define EXCLUDE_ALLOC     (1 << 26)
+
 struct exclude;
 
 bool fnmatch_pattern_has_wildcards (const char *, int) _GL_ATTRIBUTE_PURE;
@@ -46,7 +53,10 @@ void free_exclude (struct exclude *);
 void add_exclude (struct exclude *, char const *, int);
 int add_exclude_file (void (*) (struct exclude *, char const *, int),
                       struct exclude *, char const *, int, char);
+int add_exclude_fp (void (*) (struct exclude *, char const *, int, void *),
+                   struct exclude *, FILE *, int, char, void *);
 bool excluded_file_name (struct exclude const *, char const *);
-bool exclude_fnmatch (char const *pattern, char const *f, int options);
+void exclude_add_pattern_buffer (struct exclude *ex, char *buf);
+bool exclude_fnmatch (char const *, char const *, int);
 
 #endif /* _GL_EXCLUDE_H */
index bc3c3c1..500e92c 100644 (file)
--- a/lib/fts.c
+++ b/lib/fts.c
@@ -1447,19 +1447,21 @@ fts_build (register FTS *sp, int type)
         nitems = 0;
         while (cur->fts_dirp) {
                 bool is_dir;
+                size_t d_namelen;
                 struct dirent *dp = readdir(cur->fts_dirp);
                 if (dp == NULL)
                         break;
                 if (!ISSET(FTS_SEEDOT) && ISDOT(dp->d_name))
                         continue;
 
-                if ((p = fts_alloc (sp, dp->d_name,
-                                    _D_EXACT_NAMLEN (dp))) == NULL)
+                d_namelen = _D_EXACT_NAMLEN (dp);
+                p = fts_alloc (sp, dp->d_name, d_namelen);
+                if (!p)
                         goto mem1;
-                if (_D_EXACT_NAMLEN (dp) >= maxlen) {
+                if (d_namelen >= maxlen) {
                         /* include space for NUL */
                         oldaddr = sp->fts_path;
-                        if (! fts_palloc(sp, _D_EXACT_NAMLEN (dp) + len + 1)) {
+                        if (! fts_palloc(sp, d_namelen + len + 1)) {
                                 /*
                                  * No more memory.  Save
                                  * errno, free up the current structure and the
@@ -1483,7 +1485,7 @@ mem1:                           saved_errno = errno;
                         maxlen = sp->fts_pathlen - len;
                 }
 
-                new_len = len + _D_EXACT_NAMLEN (dp);
+                new_len = len + d_namelen;
                 if (new_len < len) {
                         /*
                          * In the unlikely event that we would end up
index beb6f27..5e307ed 100644 (file)
@@ -21,7 +21,7 @@
 # the same distribution terms as the rest of that program.
 #
 # Generated by gnulib-tool.
-# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl --lib=libgreputils --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=gnulib-tests --aux-dir=build-aux --with-tests --avoid=lock-tests --makefile-name=gnulib.mk --no-conditional-dependencies --no-libtool --macro-prefix=gl alloca announce-gen argmatch binary-io btowc c-ctype closeout do-release-commit-and-tag error exclude fcntl-h fnmatch fstatat fts getopt-gnu getpagesize gettext-h git-version-gen gitlog-to-changelog gnu-web-doc-update gnupload ignore-value intprops inttypes isatty isblank iswctype largefile locale lseek maintainer-makefile malloc-gnu manywarnings mbrlen mbrtowc memchr mempcpy minmax obstack openat-safer perl progname propername quote readme-release realloc-gnu regex safe-read same-inode ssize_t stddef stdlib stpcpy strerror string strtoull strtoumax sys_stat unistd unlocked-io update-copyright useless-if-before-free version-etc-fsf wchar wcrtomb wctob wctype-h xalloc xstrtoimax
+# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl --lib=libgreputils --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=gnulib-tests --aux-dir=build-aux --with-tests --avoid=lock-tests --makefile-name=gnulib.mk --no-conditional-dependencies --no-libtool --macro-prefix=gl alloca announce-gen argmatch binary-io btowc c-ctype closeout do-release-commit-and-tag error exclude fcntl-h fnmatch fstatat fts getopt-gnu getpagesize gettext-h git-version-gen gitlog-to-changelog gnu-web-doc-update gnupload ignore-value intprops inttypes isatty isblank iswctype largefile locale lseek maintainer-makefile malloc-gnu manywarnings mbrlen mbrtowc memchr memchr2 mempcpy minmax obstack openat-safer perl progname propername quote readme-release realloc-gnu regex safe-read same-inode ssize_t stddef stdlib stpcpy strerror string strtoull strtoumax sys_stat unistd unlocked-io update-copyright useless-if-before-free version-etc-fsf wchar wcrtomb wctob wctype-h xalloc xstrtoimax
 
 
 MOSTLYCLEANFILES += core *.stackdump
@@ -1200,6 +1200,14 @@ EXTRA_libgreputils_a_SOURCES += memchr.c
 
 ## end   gnulib module memchr
 
+## begin gnulib module memchr2
+
+libgreputils_a_SOURCES += memchr2.h memchr2.c
+
+EXTRA_DIST += memchr2.valgrind
+
+## end   gnulib module memchr2
+
 ## begin gnulib module mempcpy
 
 
diff --git a/lib/memchr2.c b/lib/memchr2.c
new file mode 100644 (file)
index 0000000..3d79f2a
--- /dev/null
@@ -0,0 +1,169 @@
+/* Copyright (C) 1991, 1993, 1996-1997, 1999-2000, 2003-2004, 2006, 2008-2014
+   Free Software Foundation, Inc.
+
+   Based on strlen implementation by Torbjorn Granlund (tege@sics.se),
+   with help from Dan Sahlin (dan@sics.se) and
+   commentary by Jim Blandy (jimb@ai.mit.edu);
+   adaptation to memchr suggested by Dick Karpinski (dick@cca.ucsf.edu),
+   and implemented in glibc by Roland McGrath (roland@ai.mit.edu).
+   Extension to memchr2 implemented by Eric Blake (ebb9@byu.net).
+
+This program is free software: you can redistribute it and/or modify it
+under the terms of the GNU General Public License as published by the
+Free Software Foundation; either version 3 of the License, or any
+later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#include <config.h>
+
+#include "memchr2.h"
+
+#include <limits.h>
+#include <stdint.h>
+#include <string.h>
+
+/* Return the first address of either C1 or C2 (treated as unsigned
+   char) that occurs within N bytes of the memory region S.  If
+   neither byte appears, return NULL.  */
+void *
+memchr2 (void const *s, int c1_in, int c2_in, size_t n)
+{
+  /* On 32-bit hardware, choosing longword to be a 32-bit unsigned
+     long instead of a 64-bit uintmax_t tends to give better
+     performance.  On 64-bit hardware, unsigned long is generally 64
+     bits already.  Change this typedef to experiment with
+     performance.  */
+  typedef unsigned long int longword;
+
+  const unsigned char *char_ptr;
+  void const *void_ptr;
+  const longword *longword_ptr;
+  longword repeated_one;
+  longword repeated_c1;
+  longword repeated_c2;
+  unsigned char c1;
+  unsigned char c2;
+
+  c1 = (unsigned char) c1_in;
+  c2 = (unsigned char) c2_in;
+
+  if (c1 == c2)
+    return memchr (s, c1, n);
+
+  /* Handle the first few bytes by reading one byte at a time.
+     Do this until VOID_PTR is aligned on a longword boundary.  */
+  for (void_ptr = s;
+       n > 0 && (uintptr_t) void_ptr % sizeof (longword) != 0;
+       --n)
+    {
+      char_ptr = void_ptr;
+      if (*char_ptr == c1 || *char_ptr == c2)
+        return (void *) void_ptr;
+      void_ptr = char_ptr + 1;
+    }
+
+  longword_ptr = void_ptr;
+
+  /* All these elucidatory comments refer to 4-byte longwords,
+     but the theory applies equally well to any size longwords.  */
+
+  /* Compute auxiliary longword values:
+     repeated_one is a value which has a 1 in every byte.
+     repeated_c1 has c1 in every byte.
+     repeated_c2 has c2 in every byte.  */
+  repeated_one = 0x01010101;
+  repeated_c1 = c1 | (c1 << 8);
+  repeated_c2 = c2 | (c2 << 8);
+  repeated_c1 |= repeated_c1 << 16;
+  repeated_c2 |= repeated_c2 << 16;
+  if (0xffffffffU < (longword) -1)
+    {
+      repeated_one |= repeated_one << 31 << 1;
+      repeated_c1 |= repeated_c1 << 31 << 1;
+      repeated_c2 |= repeated_c2 << 31 << 1;
+      if (8 < sizeof (longword))
+        {
+          size_t i;
+
+          for (i = 64; i < sizeof (longword) * 8; i *= 2)
+            {
+              repeated_one |= repeated_one << i;
+              repeated_c1 |= repeated_c1 << i;
+              repeated_c2 |= repeated_c2 << i;
+            }
+        }
+    }
+
+  /* Instead of the traditional loop which tests each byte, we will test a
+     longword at a time.  The tricky part is testing if *any of the four*
+     bytes in the longword in question are equal to c1 or c2.  We first use
+     an xor with repeated_c1 and repeated_c2, respectively.  This reduces
+     the task to testing whether *any of the four* bytes in longword1 or
+     longword2 is zero.
+
+     Let's consider longword1.  We compute tmp1 =
+       ((longword1 - repeated_one) & ~longword1) & (repeated_one << 7).
+     That is, we perform the following operations:
+       1. Subtract repeated_one.
+       2. & ~longword1.
+       3. & a mask consisting of 0x80 in every byte.
+     Consider what happens in each byte:
+       - If a byte of longword1 is zero, step 1 and 2 transform it into 0xff,
+         and step 3 transforms it into 0x80.  A carry can also be propagated
+         to more significant bytes.
+       - If a byte of longword1 is nonzero, let its lowest 1 bit be at
+         position k (0 <= k <= 7); so the lowest k bits are 0.  After step 1,
+         the byte ends in a single bit of value 0 and k bits of value 1.
+         After step 2, the result is just k bits of value 1: 2^k - 1.  After
+         step 3, the result is 0.  And no carry is produced.
+     So, if longword1 has only non-zero bytes, tmp1 is zero.
+     Whereas if longword1 has a zero byte, call j the position of the least
+     significant zero byte.  Then the result has a zero at positions 0, ...,
+     j-1 and a 0x80 at position j.  We cannot predict the result at the more
+     significant bytes (positions j+1..3), but it does not matter since we
+     already have a non-zero bit at position 8*j+7.
+
+     Similarly, we compute tmp2 =
+       ((longword2 - repeated_one) & ~longword2) & (repeated_one << 7).
+
+     The test whether any byte in longword1 or longword2 is zero is equivalent
+     to testing whether tmp1 is nonzero or tmp2 is nonzero.  We can combine
+     this into a single test, whether (tmp1 | tmp2) is nonzero.  */
+
+  while (n >= sizeof (longword))
+    {
+      longword longword1 = *longword_ptr ^ repeated_c1;
+      longword longword2 = *longword_ptr ^ repeated_c2;
+
+      if (((((longword1 - repeated_one) & ~longword1)
+            | ((longword2 - repeated_one) & ~longword2))
+           & (repeated_one << 7)) != 0)
+        break;
+      longword_ptr++;
+      n -= sizeof (longword);
+    }
+
+  char_ptr = (const unsigned char *) longword_ptr;
+
+  /* At this point, we know that either n < sizeof (longword), or one of the
+     sizeof (longword) bytes starting at char_ptr is == c1 or == c2.  On
+     little-endian machines, we could determine the first such byte without
+     any further memory accesses, just by looking at the (tmp1 | tmp2) result
+     from the last loop iteration.  But this does not work on big-endian
+     machines.  Choose code that works in both cases.  */
+
+  for (; n > 0; --n, ++char_ptr)
+    {
+      if (*char_ptr == c1 || *char_ptr == c2)
+        return (void *) char_ptr;
+    }
+
+  return NULL;
+}
diff --git a/lib/memchr2.h b/lib/memchr2.h
new file mode 100644 (file)
index 0000000..220c2b5
--- /dev/null
@@ -0,0 +1,32 @@
+/* Scan memory for the first of two bytes.
+   Copyright (C) 2008-2014 Free Software Foundation, Inc.
+
+   This program is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 3 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#include <stddef.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* Return the first address of either C1 or C2 (treated as unsigned
+   char) that occurs within N bytes of the memory region S.  If
+   neither byte appears, return NULL.  */
+
+extern void *memchr2 (void const *s, int c1, int c2, size_t n)
+  _GL_ATTRIBUTE_PURE;
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/lib/memchr2.valgrind b/lib/memchr2.valgrind
new file mode 100644 (file)
index 0000000..778fe86
--- /dev/null
@@ -0,0 +1,14 @@
+# Suppress a valgrind message about use of uninitialized memory in memchr2().
+# Like memchr, it is safe to overestimate the length when the terminator
+# is guaranteed to be found.  In this case, we may end up reading a word
+# that is partially uninitialized, but this use is OK for a speedup.
+{
+    memchr2-value4
+    Memcheck:Value4
+    fun:memchr2
+}
+{
+    memchr2-value8
+    Memcheck:Value8
+    fun:memchr2
+}
index 9cd356c..2db87b3 100644 (file)
@@ -1,19 +1,21 @@
 /* obstack.c - subroutines used implicitly by object stack macros
+   Copyright (C) 1988-2014 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-   Copyright (C) 1988-1994, 1996-2006, 2009-2014 Free Software Foundation, Inc.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU General Public
+   License as published by the Free Software Foundation; either
+   version 3 of the License, or (at your option) any later version.
 
-   This program is free software: you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
+   The GNU C Library is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   General Public License for more details.
+
+   You should have received a copy of the GNU General Public
+   License along with the GNU C Library; if not, see
+   <http://www.gnu.org/licenses/>.  */
 
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #ifdef _LIBC
 # include <obstack.h>
@@ -49,6 +51,7 @@
 
 #ifndef ELIDE_CODE
 
+
 # include <stdint.h>
 
 /* Determine default alignment.  */
@@ -67,10 +70,10 @@ struct fooalign
    But in fact it might be less smart and round addresses to as much as
    DEFAULT_ROUNDING.  So we prepare for it to do that.  */
 enum
-  {
-    DEFAULT_ALIGNMENT = offsetof (struct fooalign, u),
-    DEFAULT_ROUNDING = sizeof (union fooround)
-  };
+{
+  DEFAULT_ALIGNMENT = offsetof (struct fooalign, u),
+  DEFAULT_ROUNDING = sizeof (union fooround)
+};
 
 /* When we copy a long block of data, this is the unit to do it with.
    On some machines, copying successive ints does not work;
@@ -104,7 +107,7 @@ int obstack_exit_failure = EXIT_FAILURE;
 /* A looong time ago (before 1994, anyway; we're not sure) this global variable
    was used by non-GNU-C macros to avoid multiple evaluation.  The GNU C
    library still exports it because somebody might use it.  */
-struct obstack *_obstack_compat;
+struct obstack *_obstack_compat = 0;
 compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
 #  endif
 # endif
@@ -116,19 +119,19 @@ compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
    do not allow (expr) ? void : void.  */
 
 # define CALL_CHUNKFUN(h, size) \
-  (((h) -> use_extra_arg) \
-   ? (*(h)->chunkfun) ((h)->extra_arg, (size)) \
-   : (*(struct _obstack_chunk *(*) (long)) (h)->chunkfun) ((size)))
+  (((h)->use_extra_arg)                                                              \
+   ? (*(h)->chunkfun)((h)->extra_arg, (size))                                \
+   : (*(struct _obstack_chunk *(*)(long))(h)->chunkfun)((size)))
 
 # define CALL_FREEFUN(h, old_chunk) \
   do { \
-    if ((h) -> use_extra_arg) \
-      (*(h)->freefun) ((h)->extra_arg, (old_chunk)); \
-    else \
-      (*(void (*) (void *)) (h)->freefun) ((old_chunk)); \
-  } while (0)
+      if ((h)->use_extra_arg)                                                \
+        (*(h)->freefun)((h)->extra_arg, (old_chunk));                        \
+      else                                                                   \
+        (*(void (*)(void *))(h)->freefun)((old_chunk));                              \
+    } while (0)
+
 
-\f
 /* Initialize an obstack H for use.  Specify chunk size SIZE (0 means default).
    Objects start on multiples of ALIGNMENT (0 means use default).
    CHUNKFUN is the function to use to allocate chunks,
@@ -143,7 +146,7 @@ _obstack_begin (struct obstack *h,
                 void *(*chunkfun) (long),
                 void (*freefun) (void *))
 {
-  register struct _obstack_chunk *chunk; /* points to new chunk */
+  struct _obstack_chunk *chunk; /* points to new chunk */
 
   if (alignment == 0)
     alignment = DEFAULT_ALIGNMENT;
@@ -164,19 +167,19 @@ _obstack_begin (struct obstack *h,
       size = 4096 - extra;
     }
 
-  h->chunkfun = (struct _obstack_chunk * (*)(void *, long)) chunkfun;
+  h->chunkfun = (struct _obstack_chunk * (*) (void *, long)) chunkfun;
   h->freefun = (void (*) (void *, struct _obstack_chunk *)) freefun;
   h->chunk_size = size;
   h->alignment_mask = alignment - 1;
   h->use_extra_arg = 0;
 
-  chunk = h->chunk = CALL_CHUNKFUN (h, h -> chunk_size);
+  chunk = h->chunk = CALL_CHUNKFUN (h, h->chunk_size);
   if (!chunk)
     (*obstack_alloc_failed_handler) ();
   h->next_free = h->object_base = __PTR_ALIGN ((char *) chunk, chunk->contents,
                                                alignment - 1);
   h->chunk_limit = chunk->limit
-    = (char *) chunk + h->chunk_size;
+                     = (char *) chunk + h->chunk_size;
   chunk->prev = 0;
   /* The initial chunk now contains no empty object.  */
   h->maybe_empty_object = 0;
@@ -190,7 +193,7 @@ _obstack_begin_1 (struct obstack *h, int size, int alignment,
                   void (*freefun) (void *, void *),
                   void *arg)
 {
-  register struct _obstack_chunk *chunk; /* points to new chunk */
+  struct _obstack_chunk *chunk; /* points to new chunk */
 
   if (alignment == 0)
     alignment = DEFAULT_ALIGNMENT;
@@ -218,13 +221,13 @@ _obstack_begin_1 (struct obstack *h, int size, int alignment,
   h->extra_arg = arg;
   h->use_extra_arg = 1;
 
-  chunk = h->chunk = CALL_CHUNKFUN (h, h -> chunk_size);
+  chunk = h->chunk = CALL_CHUNKFUN (h, h->chunk_size);
   if (!chunk)
     (*obstack_alloc_failed_handler) ();
   h->next_free = h->object_base = __PTR_ALIGN ((char *) chunk, chunk->contents,
                                                alignment - 1);
   h->chunk_limit = chunk->limit
-    = (char *) chunk + h->chunk_size;
+                     = (char *) chunk + h->chunk_size;
   chunk->prev = 0;
   /* The initial chunk now contains no empty object.  */
   h->maybe_empty_object = 0;
@@ -241,11 +244,11 @@ _obstack_begin_1 (struct obstack *h, int size, int alignment,
 void
 _obstack_newchunk (struct obstack *h, int length)
 {
-  register struct _obstack_chunk *old_chunk = h->chunk;
-  register struct _obstack_chunk *new_chunk;
-  register long new_size;
-  register long obj_size = h->next_free - h->object_base;
-  register long i;
+  struct _obstack_chunk *old_chunk = h->chunk;
+  struct _obstack_chunk *new_chunk;
+  long new_size;
+  long obj_size = h->next_free - h->object_base;
+  long i;
   long already;
   char *object_base;
 
@@ -257,7 +260,7 @@ _obstack_newchunk (struct obstack *h, int length)
   /* Allocate and initialize the new chunk.  */
   new_chunk = CALL_CHUNKFUN (h, new_size);
   if (!new_chunk)
-    (*obstack_alloc_failed_handler) ();
+    (*obstack_alloc_failed_handler)();
   h->chunk = new_chunk;
   new_chunk->prev = old_chunk;
   new_chunk->limit = h->chunk_limit = (char *) new_chunk + new_size;
@@ -273,8 +276,8 @@ _obstack_newchunk (struct obstack *h, int length)
     {
       for (i = obj_size / sizeof (COPYING_UNIT) - 1;
            i >= 0; i--)
-        ((COPYING_UNIT *)object_base)[i]
-          = ((COPYING_UNIT *)h->object_base)[i];
+        ((COPYING_UNIT *) object_base)[i]
+          = ((COPYING_UNIT *) h->object_base)[i];
       /* We used to copy the odd few remaining bytes as one extra COPYING_UNIT,
          but that can cross a page boundary on a machine
          which does not do strict alignment for COPYING_UNITS.  */
@@ -289,7 +292,7 @@ _obstack_newchunk (struct obstack *h, int length)
   /* If the object just copied was the only data in OLD_CHUNK,
      free that chunk and remove it from the chain.
      But not if that chunk might contain an empty object.  */
-  if (! h->maybe_empty_object
+  if (!h->maybe_empty_object
       && (h->object_base
           == __PTR_ALIGN ((char *) old_chunk, old_chunk->contents,
                           h->alignment_mask)))
@@ -313,13 +316,13 @@ libc_hidden_def (_obstack_newchunk)
 
 /* Suppress -Wmissing-prototypes warning.  We don't want to declare this in
    obstack.h because it is just for debugging.  */
-int _obstack_allocated_p (struct obstack *h, void *obj) _GL_ATTRIBUTE_PURE;
+int _obstack_allocated_p (struct obstack *h, void *obj) __attribute_pure__;
 
 int
 _obstack_allocated_p (struct obstack *h, void *obj)
 {
-  register struct _obstack_chunk *lp;   /* below addr of any objects in this chunk */
-  register struct _obstack_chunk *plp;  /* point to previous chunk if any */
+  struct _obstack_chunk *lp;    /* below addr of any objects in this chunk */
+  struct _obstack_chunk *plp;   /* point to previous chunk if any */
 
   lp = (h)->chunk;
   /* We use >= rather than > since the object cannot be exactly at
@@ -332,7 +335,7 @@ _obstack_allocated_p (struct obstack *h, void *obj)
     }
   return lp != 0;
 }
-\f
+
 /* Free objects in obstack H, including OBJ and everything allocate
    more recently than OBJ.  If OBJ is zero, free everything in H.  */
 
@@ -341,8 +344,8 @@ _obstack_allocated_p (struct obstack *h, void *obj)
 void
 __obstack_free (struct obstack *h, void *obj)
 {
-  register struct _obstack_chunk *lp;   /* below addr of any objects in this chunk */
-  register struct _obstack_chunk *plp;  /* point to previous chunk if any */
+  struct _obstack_chunk *lp;    /* below addr of any objects in this chunk */
+  struct _obstack_chunk *plp;   /* point to previous chunk if any */
 
   lp = h->chunk;
   /* We use >= because there cannot be an object at the beginning of a chunk.
@@ -373,12 +376,12 @@ __obstack_free (struct obstack *h, void *obj)
    called by non-GCC compilers.  */
 strong_alias (obstack_free, _obstack_free)
 # endif
-\f
+
 int
 _obstack_memory_used (struct obstack *h)
 {
-  register struct _obstack_chunk* lp;
-  register int nbytes = 0;
+  struct _obstack_chunk *lp;
+  int nbytes = 0;
 
   for (lp = h->chunk; lp != 0; lp = lp->prev)
     {
@@ -386,7 +389,7 @@ _obstack_memory_used (struct obstack *h)
     }
   return nbytes;
 }
-\f
+
 /* Define the error handler.  */
 # ifdef _LIBC
 #  include <libintl.h>
index 5eef47f..ebaa622 100644 (file)
@@ -2,89 +2,89 @@
    Copyright (C) 1988-2014 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
-   This program is free software; you can redistribute it and/or
+   The GNU C Library is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public
    License as published by the Free Software Foundation; either
    version 3 of the License, or (at your option) any later version.
 
-   This program is distributed in the hope that it will be useful,
+   The GNU C Library is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    General Public License for more details.
 
    You should have received a copy of the GNU General Public
-   License along with this program; if not, see
+   License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
 /* Summary:
 
-All the apparent functions defined here are macros. The idea
-is that you would use these pre-tested macros to solve a
-very specific set of problems, and they would run fast.
-Caution: no side-effects in arguments please!! They may be
-evaluated MANY times!!
-
-These macros operate a stack of objects.  Each object starts life
-small, and may grow to maturity.  (Consider building a word syllable
-by syllable.)  An object can move while it is growing.  Once it has
-been "finished" it never changes address again.  So the "top of the
-stack" is typically an immature growing object, while the rest of the
-stack is of mature, fixed size and fixed address objects.
-
-These routines grab large chunks of memory, using a function you
-supply, called 'obstack_chunk_alloc'.  On occasion, they free chunks,
-by calling 'obstack_chunk_free'.  You must define them and declare
-them before using any obstack macros.
-
-Each independent stack is represented by a 'struct obstack'.
-Each of the obstack macros expects a pointer to such a structure
-as the first argument.
-
-One motivation for this package is the problem of growing char strings
-in symbol tables.  Unless you are "fascist pig with a read-only mind"
---Gosper's immortal quote from HAKMEM item 154, out of context--you
-would not like to put any arbitrary upper limit on the length of your
-symbols.
-
-In practice this often means you will build many short symbols and a
-few long symbols.  At the time you are reading a symbol you don't know
-how long it is.  One traditional method is to read a symbol into a
-buffer, realloc()ating the buffer every time you try to read a symbol
-that is longer than the buffer.  This is beaut, but you still will
-want to copy the symbol from the buffer to a more permanent
-symbol-table entry say about half the time.
-
-With obstacks, you can work differently.  Use one obstack for all symbol
-names.  As you read a symbol, grow the name in the obstack gradually.
-When the name is complete, finalize it.  Then, if the symbol exists already,
-free the newly read name.
-
-The way we do this is to take a large chunk, allocating memory from
-low addresses.  When you want to build a symbol in the chunk you just
-add chars above the current "high water mark" in the chunk.  When you
-have finished adding chars, because you got to the end of the symbol,
-you know how long the chars are, and you can create a new object.
-Mostly the chars will not burst over the highest address of the chunk,
-because you would typically expect a chunk to be (say) 100 times as
-long as an average object.
-
-In case that isn't clear, when we have enough chars to make up
-the object, THEY ARE ALREADY CONTIGUOUS IN THE CHUNK (guaranteed)
-so we just point to it where it lies.  No moving of chars is
-needed and this is the second win: potentially long strings need
-never be explicitly shuffled. Once an object is formed, it does not
-change its address during its lifetime.
-
-When the chars burst over a chunk boundary, we allocate a larger
-chunk, and then copy the partly formed object from the end of the old
-chunk to the beginning of the new larger chunk.  We then carry on
-accreting characters to the end of the object as we normally would.
-
-A special macro is provided to add a single char at a time to a
-growing object.  This allows the use of register variables, which
-break the ordinary 'growth' macro.
-
-Summary:
+   All the apparent functions defined here are macros. The idea
+   is that you would use these pre-tested macros to solve a
+   very specific set of problems, and they would run fast.
+   Caution: no side-effects in arguments please!! They may be
+   evaluated MANY times!!
+
+   These macros operate a stack of objects.  Each object starts life
+   small, and may grow to maturity.  (Consider building a word syllable
+   by syllable.)  An object can move while it is growing.  Once it has
+   been "finished" it never changes address again.  So the "top of the
+   stack" is typically an immature growing object, while the rest of the
+   stack is of mature, fixed size and fixed address objects.
+
+   These routines grab large chunks of memory, using a function you
+   supply, called 'obstack_chunk_alloc'.  On occasion, they free chunks,
+   by calling 'obstack_chunk_free'.  You must define them and declare
+   them before using any obstack macros.
+
+   Each independent stack is represented by a 'struct obstack'.
+   Each of the obstack macros expects a pointer to such a structure
+   as the first argument.
+
+   One motivation for this package is the problem of growing char strings
+   in symbol tables.  Unless you are "fascist pig with a read-only mind"
+   --Gosper's immortal quote from HAKMEM item 154, out of context--you
+   would not like to put any arbitrary upper limit on the length of your
+   symbols.
+
+   In practice this often means you will build many short symbols and a
+   few long symbols.  At the time you are reading a symbol you don't know
+   how long it is.  One traditional method is to read a symbol into a
+   buffer, realloc()ating the buffer every time you try to read a symbol
+   that is longer than the buffer.  This is beaut, but you still will
+   want to copy the symbol from the buffer to a more permanent
+   symbol-table entry say about half the time.
+
+   With obstacks, you can work differently.  Use one obstack for all symbol
+   names.  As you read a symbol, grow the name in the obstack gradually.
+   When the name is complete, finalize it.  Then, if the symbol exists already,
+   free the newly read name.
+
+   The way we do this is to take a large chunk, allocating memory from
+   low addresses.  When you want to build a symbol in the chunk you just
+   add chars above the current "high water mark" in the chunk.  When you
+   have finished adding chars, because you got to the end of the symbol,
+   you know how long the chars are, and you can create a new object.
+   Mostly the chars will not burst over the highest address of the chunk,
+   because you would typically expect a chunk to be (say) 100 times as
+   long as an average object.
+
+   In case that isn't clear, when we have enough chars to make up
+   the object, THEY ARE ALREADY CONTIGUOUS IN THE CHUNK (guaranteed)
+   so we just point to it where it lies.  No moving of chars is
+   needed and this is the second win: potentially long strings need
+   never be explicitly shuffled. Once an object is formed, it does not
+   change its address during its lifetime.
+
+   When the chars burst over a chunk boundary, we allocate a larger
+   chunk, and then copy the partly formed object from the end of the old
+   chunk to the beginning of the new larger chunk.  We then carry on
+   accreting characters to the end of the object as we normally would.
+
+   A special macro is provided to add a single char at a time to a
+   growing object.  This allows the use of register variables, which
+   break the ordinary 'growth' macro.
+
+   Summary:
         We allocate large chunks.
         We carve out one object at a time from the current chunk.
         Once carved, an object never moves.
@@ -96,14 +96,14 @@ Summary:
         Because of the way we do it, you can "unwind" an obstack
           back to a previous state. (You may remove objects much
           as you would with a stack.)
-*/
+ */
 
 
 /* Don't do the contents of this file more than once.  */
 
 #ifndef _OBSTACK_H
 #define _OBSTACK_H 1
-\f
+
 /* We need the type of a pointer subtraction.  If __PTRDIFF_TYPE__ is
    defined, as with GNU C, use that; that way we don't pollute the
    namespace with <stddef.h>'s symbols.  Otherwise, include <stddef.h>
@@ -129,70 +129,74 @@ Summary:
    relative to B.  Otherwise, use the faster strategy of computing the
    alignment relative to 0.  */
 
-#define __PTR_ALIGN(B, P, A)                                                \
+#define __PTR_ALIGN(B, P, A)                                                 \
   __BPTR_ALIGN (sizeof (PTR_INT_TYPE) < sizeof (void *) ? (B) : (char *) 0, \
                 P, A)
 
 #include <string.h>
 
+#ifndef __attribute_pure__
+# define __attribute_pure__ _GL_ATTRIBUTE_PURE
+#endif
+
 #ifdef __cplusplus
 extern "C" {
 #endif
 
 struct _obstack_chunk           /* Lives at front of each chunk. */
 {
-  char  *limit;                 /* 1 past end of this chunk */
+  char *limit;                  /* 1 past end of this chunk */
   struct _obstack_chunk *prev;  /* address of prior chunk or NULL */
-  char  contents[4];            /* objects begin here */
+  char contents[4];             /* objects begin here */
 };
 
 struct obstack          /* control current object in current chunk */
 {
-  long  chunk_size;             /* preferred size to allocate chunks in */
+  long chunk_size;              /* preferred size to allocate chunks in */
   struct _obstack_chunk *chunk; /* address of current struct obstack_chunk */
-  char  *object_base;           /* address of object we are building */
-  char  *next_free;             /* where to add next char to current object */
-  char  *chunk_limit;           /* address of char after current chunk */
+  char *object_base;            /* address of object we are building */
+  char *next_free;              /* where to add next char to current object */
+  char *chunk_limit;            /* address of char after current chunk */
   union
   {
     PTR_INT_TYPE tempint;
     void *tempptr;
   } temp;                       /* Temporary for some macros.  */
-  int   alignment_mask;         /* Mask of alignment for each object. */
+  int alignment_mask;           /* Mask of alignment for each object. */
   /* These prototypes vary based on 'use_extra_arg', and we use
      casts to the prototypeless function type in all assignments,
      but having prototypes here quiets -Wstrict-prototypes.  */
   struct _obstack_chunk *(*chunkfun) (void *, long);
   void (*freefun) (void *, struct _obstack_chunk *);
   void *extra_arg;              /* first arg for chunk alloc/dealloc funcs */
-  unsigned use_extra_arg:1;     /* chunk alloc/dealloc funcs take extra arg */
-  unsigned maybe_empty_object:1;/* There is a possibility that the current
-                                   chunk contains a zero-length object.  This
-                                   prevents freeing the chunk if we allocate
-                                   a bigger chunk to replace it. */
-  unsigned alloc_failed:1;      /* No longer used, as we now call the failed
-                                   handler on error, but retained for binary
-                                   compatibility.  */
+  unsigned use_extra_arg : 1;     /* chunk alloc/dealloc funcs take extra arg */
+  unsigned maybe_empty_object : 1; /* There is a possibility that the current
+                                      chunk contains a zero-length object.  This
+                                      prevents freeing the chunk if we allocate
+                                      a bigger chunk to replace it. */
+  unsigned alloc_failed : 1;      /* No longer used, as we now call the failed
+                                     handler on error, but retained for binary
+                                     compatibility.  */
 };
 
 /* Declare the external functions we use; they are in obstack.c.  */
 
 extern void _obstack_newchunk (struct obstack *, int);
 extern int _obstack_begin (struct obstack *, int, int,
-                            void *(*) (long), void (*) (void *));
+                           void *(*)(long), void (*)(void *));
 extern int _obstack_begin_1 (struct obstack *, int, int,
-                             void *(*) (void *, long),
-                             void (*) (void *, void *), void *);
-extern int _obstack_memory_used (struct obstack *) _GL_ATTRIBUTE_PURE;
+                             void *(*)(void *, long),
+                             void (*)(void *, void *), void *);
+extern int _obstack_memory_used (struct obstack *) __attribute_pure__;
 
 /* The default name of the function for freeing a chunk is 'obstack_free',
    but gnulib users can override this by defining '__obstack_free'.  */
 #ifndef __obstack_free
 # define __obstack_free obstack_free
 #endif
-extern void __obstack_free (struct obstack *obstack, void *block);
+extern void __obstack_free (struct obstack *, void *);
+
 
-\f
 /* Error handler called when 'obstack_chunk_alloc' failed to allocate
    more memory.  This can be set to a user defined function which
    should either abort gracefully or use longjump - but shouldn't
@@ -201,7 +205,7 @@ extern void (*obstack_alloc_failed_handler) (void);
 
 /* Exit value used when 'print_and_abort' is used.  */
 extern int obstack_exit_failure;
-\f
+
 /* Pointer to beginning of object being allocated or to be allocated next.
    Note that this might not be the final address of the object
    because a new chunk might be needed to hold the final size.  */
@@ -221,43 +225,40 @@ extern int obstack_exit_failure;
 #define obstack_alignment_mask(h) ((h)->alignment_mask)
 
 /* To prevent prototype warnings provide complete argument list.  */
-#define obstack_init(h)                                         \
-  _obstack_begin ((h), 0, 0,                                    \
-                  (void *(*) (long)) obstack_chunk_alloc,       \
-                  (void (*) (void *)) obstack_chunk_free)
+#define obstack_init(h)                                                              \
+  _obstack_begin ((h), 0, 0,                                                 \
+                  (void *(*)(long))obstack_chunk_alloc,                              \
+                  (void (*)(void *))obstack_chunk_free)
 
-#define obstack_begin(h, size)                                  \
-  _obstack_begin ((h), (size), 0,                               \
-                  (void *(*) (long)) obstack_chunk_alloc,       \
-                  (void (*) (void *)) obstack_chunk_free)
+#define obstack_begin(h, size)                                               \
+  _obstack_begin ((h), (size), 0,                                            \
+                  (void *(*)(long))obstack_chunk_alloc,                              \
+                  (void (*)(void *))obstack_chunk_free)
 
 #define obstack_specify_allocation(h, size, alignment, chunkfun, freefun)  \
-  _obstack_begin ((h), (size), (alignment),                                \
-                  (void *(*) (long)) (chunkfun),                           \
-                  (void (*) (void *)) (freefun))
+  _obstack_begin ((h), (size), (alignment),                                  \
+                  (void *(*)(long))(chunkfun),                               \
+                  (void (*)(void *))(freefun))
 
 #define obstack_specify_allocation_with_arg(h, size, alignment, chunkfun, freefun, arg) \
-  _obstack_begin_1 ((h), (size), (alignment),                           \
-                    (void *(*) (void *, long)) (chunkfun),              \
-                    (void (*) (void *, void *)) (freefun), (arg))
+  _obstack_begin_1 ((h), (size), (alignment),                                \
+                    (void *(*)(void *, long))(chunkfun),                     \
+                    (void (*)(void *, void *))(freefun), (arg))
 
 #define obstack_chunkfun(h, newchunkfun) \
-  ((h) -> chunkfun = (struct _obstack_chunk *(*)(void *, long)) (newchunkfun))
+  ((h)->chunkfun = (struct _obstack_chunk *(*)(void *, long))(newchunkfun))
 
 #define obstack_freefun(h, newfreefun) \
-  ((h) -> freefun = (void (*)(void *, struct _obstack_chunk *)) (newfreefun))
+  ((h)->freefun = (void (*)(void *, struct _obstack_chunk *))(newfreefun))
 
-#define obstack_1grow_fast(h,achar) (*((h)->next_free)++ = (achar))
+#define obstack_1grow_fast(h, achar) (*((h)->next_free)++ = (achar))
 
-#define obstack_blank_fast(h,n) ((h)->next_free += (n))
+#define obstack_blank_fast(h, n) ((h)->next_free += (n))
 
 #define obstack_memory_used(h) _obstack_memory_used (h)
-\f
+
 #if defined __GNUC__
-/* NextStep 2.0 cc is really gcc 1.93 but it defines __GNUC__ = 2 and
-   does not implement __extension__.  But that compiler doesn't define
-   __GNUC_MINOR__.  */
-# if __GNUC__ < 2 || (__NeXT__ && !__GNUC_MINOR__)
+# if ! (2 < __GNUC__ + (8 <= __GNUC_MINOR__))
 #  define __extension__
 # endif
 
@@ -266,160 +267,160 @@ extern int obstack_exit_failure;
    without using a global variable.
    Also, we can avoid using the 'temp' slot, to make faster code.  */
 
-# define obstack_object_size(OBSTACK)                                   \
-  __extension__                                                         \
-  ({ struct obstack const *__o = (OBSTACK);                             \
-     (unsigned) (__o->next_free - __o->object_base); })
-
-# define obstack_room(OBSTACK)                                          \
-  __extension__                                                         \
-  ({ struct obstack const *__o = (OBSTACK);                             \
-     (unsigned) (__o->chunk_limit - __o->next_free); })
-
-# define obstack_make_room(OBSTACK,length)                              \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   int __len = (length);                                                \
-   if (__o->chunk_limit - __o->next_free < __len)                       \
-     _obstack_newchunk (__o, __len);                                    \
-   (void) 0; })
-
-# define obstack_empty_p(OBSTACK)                                       \
-  __extension__                                                         \
-  ({ struct obstack const *__o = (OBSTACK);                             \
-     (__o->chunk->prev == 0                                             \
-      && __o->next_free == __PTR_ALIGN ((char *) __o->chunk,            \
-                                        __o->chunk->contents,           \
-                                        __o->alignment_mask)); })
-
-# define obstack_grow(OBSTACK,where,length)                             \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   int __len = (length);                                                \
-   if (__o->next_free + __len > __o->chunk_limit)                       \
-     _obstack_newchunk (__o, __len);                                    \
-   memcpy (__o->next_free, where, __len);                               \
-   __o->next_free += __len;                                             \
-   (void) 0; })
-
-# define obstack_grow0(OBSTACK,where,length)                            \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   int __len = (length);                                                \
-   if (__o->next_free + __len + 1 > __o->chunk_limit)                   \
-     _obstack_newchunk (__o, __len + 1);                                \
-   memcpy (__o->next_free, where, __len);                               \
-   __o->next_free += __len;                                             \
-   *(__o->next_free)++ = 0;                                             \
-   (void) 0; })
-
-# define obstack_1grow(OBSTACK,datum)                                   \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   if (__o->next_free + 1 > __o->chunk_limit)                           \
-     _obstack_newchunk (__o, 1);                                        \
-   obstack_1grow_fast (__o, datum);                                     \
-   (void) 0; })
+# define obstack_object_size(OBSTACK)                                        \
+  __extension__                                                                      \
+    ({ struct obstack const *__o = (OBSTACK);                                \
+       (unsigned) (__o->next_free - __o->object_base); })
+
+# define obstack_room(OBSTACK)                                               \
+  __extension__                                                                      \
+    ({ struct obstack const *__o = (OBSTACK);                                \
+       (unsigned) (__o->chunk_limit - __o->next_free); })
+
+# define obstack_make_room(OBSTACK, length)                                  \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       int __len = (length);                                                 \
+       if (__o->chunk_limit - __o->next_free < __len)                        \
+         _obstack_newchunk (__o, __len);                                     \
+       (void) 0; })
+
+# define obstack_empty_p(OBSTACK)                                            \
+  __extension__                                                                      \
+    ({ struct obstack const *__o = (OBSTACK);                                \
+       (__o->chunk->prev == 0                                                \
+        && __o->next_free == __PTR_ALIGN ((char *) __o->chunk,               \
+                                          __o->chunk->contents,                      \
+                                          __o->alignment_mask)); })
+
+# define obstack_grow(OBSTACK, where, length)                                \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       int __len = (length);                                                 \
+       if (__o->next_free + __len > __o->chunk_limit)                        \
+         _obstack_newchunk (__o, __len);                                     \
+       memcpy (__o->next_free, where, __len);                                \
+       __o->next_free += __len;                                                      \
+       (void) 0; })
+
+# define obstack_grow0(OBSTACK, where, length)                               \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       int __len = (length);                                                 \
+       if (__o->next_free + __len + 1 > __o->chunk_limit)                    \
+         _obstack_newchunk (__o, __len + 1);                                 \
+       memcpy (__o->next_free, where, __len);                                \
+       __o->next_free += __len;                                                      \
+       *(__o->next_free)++ = 0;                                                      \
+       (void) 0; })
+
+# define obstack_1grow(OBSTACK, datum)                                       \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       if (__o->next_free + 1 > __o->chunk_limit)                            \
+         _obstack_newchunk (__o, 1);                                         \
+       obstack_1grow_fast (__o, datum);                                              \
+       (void) 0; })
 
 /* These assume that the obstack alignment is good enough for pointers
    or ints, and that the data added so far to the current object
    shares that much alignment.  */
 
-# define obstack_ptr_grow(OBSTACK,datum)                                \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   if (__o->next_free + sizeof (void *) > __o->chunk_limit)             \
-     _obstack_newchunk (__o, sizeof (void *));                          \
-   obstack_ptr_grow_fast (__o, datum); })                               \
-
-# define obstack_int_grow(OBSTACK,datum)                                \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   if (__o->next_free + sizeof (int) > __o->chunk_limit)                \
-     _obstack_newchunk (__o, sizeof (int));                             \
-   obstack_int_grow_fast (__o, datum); })
-
-# define obstack_ptr_grow_fast(OBSTACK,aptr)                            \
-__extension__                                                           \
-({ struct obstack *__o1 = (OBSTACK);                                    \
-   void *__p1 = __o1->next_free;                                        \
-   *(const void **) __p1 = (aptr);                                      \
-   __o1->next_free += sizeof (const void *);                            \
-   (void) 0; })
-
-# define obstack_int_grow_fast(OBSTACK,aint)                            \
-__extension__                                                           \
-({ struct obstack *__o1 = (OBSTACK);                                    \
-   void *__p1 = __o1->next_free;                                        \
-   *(int *) __p1 = (aint);                                              \
-   __o1->next_free += sizeof (int);                                     \
-   (void) 0; })
-
-# define obstack_blank(OBSTACK,length)                                  \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   int __len = (length);                                                \
-   if (__o->chunk_limit - __o->next_free < __len)                       \
-     _obstack_newchunk (__o, __len);                                    \
-   obstack_blank_fast (__o, __len);                                     \
-   (void) 0; })
-
-# define obstack_alloc(OBSTACK,length)                                  \
-__extension__                                                           \
-({ struct obstack *__h = (OBSTACK);                                     \
-   obstack_blank (__h, (length));                                       \
-   obstack_finish (__h); })
-
-# define obstack_copy(OBSTACK,where,length)                             \
-__extension__                                                           \
-({ struct obstack *__h = (OBSTACK);                                     \
-   obstack_grow (__h, (where), (length));                               \
-   obstack_finish (__h); })
-
-# define obstack_copy0(OBSTACK,where,length)                            \
-__extension__                                                           \
-({ struct obstack *__h = (OBSTACK);                                     \
-   obstack_grow0 (__h, (where), (length));                              \
-   obstack_finish (__h); })
+# define obstack_ptr_grow(OBSTACK, datum)                                    \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       if (__o->next_free + sizeof (void *) > __o->chunk_limit)                      \
+         _obstack_newchunk (__o, sizeof (void *));                           \
+       obstack_ptr_grow_fast (__o, datum); })                                \
+
+# define obstack_int_grow(OBSTACK, datum)                                    \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       if (__o->next_free + sizeof (int) > __o->chunk_limit)                 \
+         _obstack_newchunk (__o, sizeof (int));                                      \
+       obstack_int_grow_fast (__o, datum); })
+
+# define obstack_ptr_grow_fast(OBSTACK, aptr)                                \
+  __extension__                                                                      \
+    ({ struct obstack *__o1 = (OBSTACK);                                     \
+       void *__p1 = __o1->next_free;                                         \
+       *(const void **) __p1 = (aptr);                                       \
+       __o1->next_free += sizeof (const void *);                             \
+       (void) 0; })
+
+# define obstack_int_grow_fast(OBSTACK, aint)                                \
+  __extension__                                                                      \
+    ({ struct obstack *__o1 = (OBSTACK);                                     \
+       void *__p1 = __o1->next_free;                                         \
+       *(int *) __p1 = (aint);                                               \
+       __o1->next_free += sizeof (int);                                              \
+       (void) 0; })
+
+# define obstack_blank(OBSTACK, length)                                              \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       int __len = (length);                                                 \
+       if (__o->chunk_limit - __o->next_free < __len)                        \
+         _obstack_newchunk (__o, __len);                                     \
+       obstack_blank_fast (__o, __len);                                              \
+       (void) 0; })
+
+# define obstack_alloc(OBSTACK, length)                                              \
+  __extension__                                                                      \
+    ({ struct obstack *__h = (OBSTACK);                                              \
+       obstack_blank (__h, (length));                                        \
+       obstack_finish (__h); })
+
+# define obstack_copy(OBSTACK, where, length)                                \
+  __extension__                                                                      \
+    ({ struct obstack *__h = (OBSTACK);                                              \
+       obstack_grow (__h, (where), (length));                                \
+       obstack_finish (__h); })
+
+# define obstack_copy0(OBSTACK, where, length)                               \
+  __extension__                                                                      \
+    ({ struct obstack *__h = (OBSTACK);                                              \
+       obstack_grow0 (__h, (where), (length));                               \
+       obstack_finish (__h); })
 
 /* The local variable is named __o1 to avoid a name conflict
    when obstack_blank is called.  */
-# define obstack_finish(OBSTACK)                                        \
-__extension__                                                           \
-({ struct obstack *__o1 = (OBSTACK);                                    \
-   void *__value = (void *) __o1->object_base;                          \
-   if (__o1->next_free == __value)                                      \
-     __o1->maybe_empty_object = 1;                                      \
-   __o1->next_free                                                      \
-     = __PTR_ALIGN (__o1->object_base, __o1->next_free,                 \
-                    __o1->alignment_mask);                              \
-   if (__o1->next_free - (char *)__o1->chunk                            \
-       > __o1->chunk_limit - (char *)__o1->chunk)                       \
-     __o1->next_free = __o1->chunk_limit;                               \
-   __o1->object_base = __o1->next_free;                                 \
-   __value; })
-
-# define obstack_free(OBSTACK, OBJ)                                     \
-__extension__                                                           \
-({ struct obstack *__o = (OBSTACK);                                     \
-   void *__obj = (OBJ);                                                 \
-   if (__obj > (void *)__o->chunk && __obj < (void *)__o->chunk_limit)  \
-     __o->next_free = __o->object_base = (char *)__obj;                 \
-   else (__obstack_free) (__o, __obj); })
-\f
+# define obstack_finish(OBSTACK)                                             \
+  __extension__                                                                      \
+    ({ struct obstack *__o1 = (OBSTACK);                                     \
+       void *__value = (void *) __o1->object_base;                           \
+       if (__o1->next_free == __value)                                       \
+         __o1->maybe_empty_object = 1;                                       \
+       __o1->next_free                                                       \
+         = __PTR_ALIGN (__o1->object_base, __o1->next_free,                  \
+                        __o1->alignment_mask);                               \
+       if (__o1->next_free - (char *) __o1->chunk                            \
+           > __o1->chunk_limit - (char *) __o1->chunk)                       \
+         __o1->next_free = __o1->chunk_limit;                                \
+       __o1->object_base = __o1->next_free;                                  \
+       __value; })
+
+# define obstack_free(OBSTACK, OBJ)                                          \
+  __extension__                                                                      \
+    ({ struct obstack *__o = (OBSTACK);                                              \
+       void *__obj = (OBJ);                                                  \
+       if (__obj > (void *) __o->chunk && __obj < (void *) __o->chunk_limit)  \
+         __o->next_free = __o->object_base = (char *) __obj;                 \
+       else (__obstack_free) (__o, __obj); })
+
 #else /* not __GNUC__ */
 
 # define obstack_object_size(h) \
- (unsigned) ((h)->next_free - (h)->object_base)
 (unsigned) ((h)->next_free - (h)->object_base)
 
-# define obstack_room(h)                \
- (unsigned) ((h)->chunk_limit - (h)->next_free)
+# define obstack_room(h)                                                     \
 (unsigned) ((h)->chunk_limit - (h)->next_free)
 
 # define obstack_empty_p(h) \
((h)->chunk->prev == 0                                                 \
-  && (h)->next_free == __PTR_ALIGN ((char *) (h)->chunk,                \
-                                    (h)->chunk->contents,               \
-                                    (h)->alignment_mask))
 ((h)->chunk->prev == 0                                                     \
+   && (h)->next_free == __PTR_ALIGN ((char *) (h)->chunk,                    \
+                                     (h)->chunk->contents,                   \
+                                     (h)->alignment_mask))
 
 /* Note that the call to _obstack_newchunk is enclosed in (..., 0)
    so that we can avoid having void expressions
@@ -427,83 +428,83 @@ __extension__                                                           \
    Casting the third operand to void was tried before,
    but some compilers won't accept it.  */
 
-# define obstack_make_room(h,length)                                    \
-( (h)->temp.tempint = (length),                                         \
-  (((h)->next_free + (h)->temp.tempint > (h)->chunk_limit)              \
+# define obstack_make_room(h, length)                                        \
+  ((h)->temp.tempint = (length),                                             \
+   (((h)->next_free + (h)->temp.tempint > (h)->chunk_limit)                  \
    ? (_obstack_newchunk ((h), (h)->temp.tempint), 0) : 0))
 
-# define obstack_grow(h,where,length)                                   \
-( (h)->temp.tempint = (length),                                         \
-  (((h)->next_free + (h)->temp.tempint > (h)->chunk_limit)              \
-   ? (_obstack_newchunk ((h), (h)->temp.tempint), 0) : 0),              \
-  memcpy ((h)->next_free, where, (h)->temp.tempint),                    \
-  (h)->next_free += (h)->temp.tempint)
-
-# define obstack_grow0(h,where,length)                                  \
-( (h)->temp.tempint = (length),                                         \
-  (((h)->next_free + (h)->temp.tempint + 1 > (h)->chunk_limit)          \
-   ? (_obstack_newchunk ((h), (h)->temp.tempint + 1), 0) : 0),          \
-  memcpy ((h)->next_free, where, (h)->temp.tempint),                    \
-  (h)->next_free += (h)->temp.tempint,                                  \
-  *((h)->next_free)++ = 0)
-
-# define obstack_1grow(h,datum)                                         \
-( (((h)->next_free + 1 > (h)->chunk_limit)                              \
-   ? (_obstack_newchunk ((h), 1), 0) : 0),                              \
-  obstack_1grow_fast (h, datum))
-
-# define obstack_ptr_grow(h,datum)                                      \
-( (((h)->next_free + sizeof (char *) > (h)->chunk_limit)                \
-   ? (_obstack_newchunk ((h), sizeof (char *)), 0) : 0),                \
-  obstack_ptr_grow_fast (h, datum))
-
-# define obstack_int_grow(h,datum)                                      \
-( (((h)->next_free + sizeof (int) > (h)->chunk_limit)                   \
-   ? (_obstack_newchunk ((h), sizeof (int)), 0) : 0),                   \
-  obstack_int_grow_fast (h, datum))
-
-# define obstack_ptr_grow_fast(h,aptr)                                  \
+# define obstack_grow(h, where, length)                                              \
+  ((h)->temp.tempint = (length),                                             \
+   (((h)->next_free + (h)->temp.tempint > (h)->chunk_limit)                  \
+   ? (_obstack_newchunk ((h), (h)->temp.tempint), 0) : 0),                   \
+   memcpy ((h)->next_free, where, (h)->temp.tempint),                        \
+   (h)->next_free += (h)->temp.tempint)
+
+# define obstack_grow0(h, where, length)                                     \
+  ((h)->temp.tempint = (length),                                             \
+   (((h)->next_free + (h)->temp.tempint + 1 > (h)->chunk_limit)                      \
+   ? (_obstack_newchunk ((h), (h)->temp.tempint + 1), 0) : 0),               \
+   memcpy ((h)->next_free, where, (h)->temp.tempint),                        \
+   (h)->next_free += (h)->temp.tempint,                                              \
+   *((h)->next_free)++ = 0)
+
+# define obstack_1grow(h, datum)                                             \
+  ((((h)->next_free + 1 > (h)->chunk_limit)                                  \
+    ? (_obstack_newchunk ((h), 1), 0) : 0),                                  \
+   obstack_1grow_fast (h, datum))
+
+# define obstack_ptr_grow(h, datum)                                          \
+  ((((h)->next_free + sizeof (char *) > (h)->chunk_limit)                    \
+    ? (_obstack_newchunk ((h), sizeof (char *)), 0) : 0),                    \
+   obstack_ptr_grow_fast (h, datum))
+
+# define obstack_int_grow(h, datum)                                          \
+  ((((h)->next_free + sizeof (int) > (h)->chunk_limit)                       \
+    ? (_obstack_newchunk ((h), sizeof (int)), 0) : 0),                       \
+   obstack_int_grow_fast (h, datum))
+
+# define obstack_ptr_grow_fast(h, aptr)                                              \
   (((const void **) ((h)->next_free += sizeof (void *)))[-1] = (aptr))
 
-# define obstack_int_grow_fast(h,aint)                                  \
+# define obstack_int_grow_fast(h, aint)                                              \
   (((int *) ((h)->next_free += sizeof (int)))[-1] = (aint))
 
-# define obstack_blank(h,length)                                        \
-( (h)->temp.tempint = (length),                                         \
-  (((h)->chunk_limit - (h)->next_free < (h)->temp.tempint)              \
-   ? (_obstack_newchunk ((h), (h)->temp.tempint), 0) : 0),              \
-  obstack_blank_fast (h, (h)->temp.tempint))
-
-# define obstack_alloc(h,length)                                        \
- (obstack_blank ((h), (length)), obstack_finish ((h)))
-
-# define obstack_copy(h,where,length)                                   \
- (obstack_grow ((h), (where), (length)), obstack_finish ((h)))
-
-# define obstack_copy0(h,where,length)                                  \
- (obstack_grow0 ((h), (where), (length)), obstack_finish ((h)))
-
-# define obstack_finish(h)                                              \
-( ((h)->next_free == (h)->object_base                                   \
-   ? (((h)->maybe_empty_object = 1), 0)                                 \
-   : 0),                                                                \
-  (h)->temp.tempptr = (h)->object_base,                                 \
-  (h)->next_free                                                        \
-    = __PTR_ALIGN ((h)->object_base, (h)->next_free,                    \
-                   (h)->alignment_mask),                                \
-  (((h)->next_free - (char *) (h)->chunk                                \
-    > (h)->chunk_limit - (char *) (h)->chunk)                           \
-   ? ((h)->next_free = (h)->chunk_limit) : 0),                          \
-  (h)->object_base = (h)->next_free,                                    \
-  (h)->temp.tempptr)
-
-# define obstack_free(h,obj)                                            \
-( (h)->temp.tempint = (char *) (obj) - (char *) (h)->chunk,             \
-  ((((h)->temp.tempint > 0                                              \
-    && (h)->temp.tempint < (h)->chunk_limit - (char *) (h)->chunk))     \
-   ? (void) ((h)->next_free = (h)->object_base                          \
-             = (h)->temp.tempint + (char *) (h)->chunk)                 \
-   : (__obstack_free) (h, (h)->temp.tempint + (char *) (h)->chunk)))
+# define obstack_blank(h, length)                                            \
+  ((h)->temp.tempint = (length),                                             \
+   (((h)->chunk_limit - (h)->next_free < (h)->temp.tempint)                  \
+   ? (_obstack_newchunk ((h), (h)->temp.tempint), 0) : 0),                   \
+   obstack_blank_fast (h, (h)->temp.tempint))
+
+# define obstack_alloc(h, length)                                            \
 (obstack_blank ((h), (length)), obstack_finish ((h)))
+
+# define obstack_copy(h, where, length)                                              \
 (obstack_grow ((h), (where), (length)), obstack_finish ((h)))
+
+# define obstack_copy0(h, where, length)                                     \
 (obstack_grow0 ((h), (where), (length)), obstack_finish ((h)))
+
+# define obstack_finish(h)                                                   \
+  (((h)->next_free == (h)->object_base                                       \
+    ? (((h)->maybe_empty_object = 1), 0)                                     \
+    : 0),                                                                    \
+   (h)->temp.tempptr = (h)->object_base,                                     \
+   (h)->next_free                                                            \
+     = __PTR_ALIGN ((h)->object_base, (h)->next_free,                        \
+                    (h)->alignment_mask),                                    \
+   (((h)->next_free - (char *) (h)->chunk                                    \
+     > (h)->chunk_limit - (char *) (h)->chunk)                               \
+   ? ((h)->next_free = (h)->chunk_limit) : 0),                               \
+   (h)->object_base = (h)->next_free,                                        \
+   (h)->temp.tempptr)
+
+# define obstack_free(h, obj)                                                \
+  ((h)->temp.tempint = (char *) (obj) - (char *) (h)->chunk,                 \
+   ((((h)->temp.tempint > 0                                                  \
+      && (h)->temp.tempint < (h)->chunk_limit - (char *) (h)->chunk))        \
+    ? (void) ((h)->next_free = (h)->object_base                                      \
+                          = (h)->temp.tempint + (char *) (h)->chunk)         \
+    : (__obstack_free) (h, (h)->temp.tempint + (char *) (h)->chunk)))
 
 #endif /* not __GNUC__ */
 
index ac751a1..249d757 100644 (file)
@@ -540,7 +540,7 @@ regerror (errcode, preg, errbuf, errbuf_size)
     size_t errbuf_size;
 #else /* size_t might promote */
 size_t
-regerror (int errcode, const regex_t *_Restrict_ preg _UNUSED_PARAMETER_,
+regerror (int errcode, const regex_t *_Restrict_ preg,
          char *_Restrict_ errbuf, size_t errbuf_size)
 #endif
 {
@@ -1427,7 +1427,7 @@ calc_first (void *extra, bin_tree_t *node)
 
 /* Pass 2: compute NEXT on the tree.  Preorder visit.  */
 static reg_errcode_t
-calc_next (void *extra _UNUSED_PARAMETER_, bin_tree_t *node)
+calc_next (void *extra, bin_tree_t *node)
 {
   switch (node->token.type)
     {
@@ -2806,10 +2806,8 @@ build_range_exp (const reg_syntax_t syntax,
 static reg_errcode_t
 internal_function
 # ifdef RE_ENABLE_I18N
-build_collating_symbol (bitset_t sbcset,
-                        re_charset_t *mbcset _UNUSED_PARAMETER_,
-                       Idx *coll_sym_alloc _UNUSED_PARAMETER_,
-                        const unsigned char *name)
+build_collating_symbol (bitset_t sbcset, re_charset_t *mbcset,
+                       Idx *coll_sym_alloc, const unsigned char *name)
 # else /* not RE_ENABLE_I18N */
 build_collating_symbol (bitset_t sbcset, const unsigned char *name)
 # endif /* not RE_ENABLE_I18N */
@@ -3377,8 +3375,7 @@ parse_bracket_exp (re_string_t *regexp, re_dfa_t *dfa, re_token_t *token,
 
 static reg_errcode_t
 parse_bracket_element (bracket_elem_t *elem, re_string_t *regexp,
-                      re_token_t *token, int token_len,
-                      re_dfa_t *dfa _UNUSED_PARAMETER_,
+                      re_token_t *token, int token_len, re_dfa_t *dfa,
                       reg_syntax_t syntax, bool accept_hyphen)
 {
 #ifdef RE_ENABLE_I18N
@@ -3465,10 +3462,8 @@ parse_bracket_symbol (bracket_elem_t *elem, re_string_t *regexp,
 
 static reg_errcode_t
 #ifdef RE_ENABLE_I18N
-build_equiv_class (bitset_t sbcset,
-                   re_charset_t *mbcset _UNUSED_PARAMETER_,
-                  Idx *equiv_class_alloc _UNUSED_PARAMETER_,
-                  const unsigned char *name)
+build_equiv_class (bitset_t sbcset, re_charset_t *mbcset,
+                  Idx *equiv_class_alloc, const unsigned char *name)
 #else /* not RE_ENABLE_I18N */
 build_equiv_class (bitset_t sbcset, const unsigned char *name)
 #endif /* not RE_ENABLE_I18N */
@@ -3874,7 +3869,7 @@ free_token (re_token_t *node)
    and its children. */
 
 static reg_errcode_t
-free_tree (void *extra _UNUSED_PARAMETER_, bin_tree_t *node)
+free_tree (void *extra, bin_tree_t *node)
 {
   free_token (&node->token);
   return REG_NOERROR;
index 257b37c..c5bb012 100644 (file)
@@ -17,8 +17,6 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
-#include "verify.h"
-#include "intprops.h"
 static void re_string_construct_common (const char *str, Idx len,
                                        re_string_t *pstr,
                                        RE_TRANSLATE_TYPE trans, bool icase,
@@ -313,12 +311,11 @@ build_wcs_upper_buffer (re_string_t *pstr)
                               + byte_idx), remain_len, &pstr->cur_state);
          if (BE (mbclen < (size_t) -2, 1))
            {
-             wchar_t wcu = wc;
-             if (iswlower (wc))
+             wchar_t wcu = towupper (wc);
+             if (wcu != wc)
                {
                  size_t mbcdlen;
 
-                 wcu = towupper (wc);
                  mbcdlen = wcrtomb (buf, wcu, &prev_st);
                  if (BE (mbclen == mbcdlen, 1))
                    memcpy (pstr->mbs + byte_idx, buf, mbclen);
@@ -383,12 +380,11 @@ build_wcs_upper_buffer (re_string_t *pstr)
        mbclen = __mbrtowc (&wc, p, remain_len, &pstr->cur_state);
        if (BE (mbclen < (size_t) -2, 1))
          {
-           wchar_t wcu = wc;
-           if (iswlower (wc))
+           wchar_t wcu = towupper (wc);
+           if (wcu != wc)
              {
                size_t mbcdlen;
 
-               wcu = towupper (wc);
                mbcdlen = wcrtomb ((char *) buf, wcu, &prev_st);
                if (BE (mbclen == mbcdlen, 1))
                  memcpy (pstr->mbs + byte_idx, buf, mbclen);
@@ -540,10 +536,7 @@ build_upper_buffer (re_string_t *pstr)
       int ch = pstr->raw_mbs[pstr->raw_mbs_idx + char_idx];
       if (BE (pstr->trans != NULL, 0))
        ch = pstr->trans[ch];
-      if (islower (ch))
-       pstr->mbs[char_idx] = toupper (ch);
-      else
-       pstr->mbs[char_idx] = ch;
+      pstr->mbs[char_idx] = toupper (ch);
     }
   pstr->valid_len = char_idx;
   pstr->valid_raw_len = char_idx;
@@ -1396,10 +1389,7 @@ static void
 internal_function
 re_node_set_remove_at (re_node_set *set, Idx idx)
 {
-  verify (! TYPE_SIGNED (Idx));
-  /* if (idx < 0)
-     return; */
-  if (idx >= set->nelem)
+  if (idx < 0 || idx >= set->nelem)
     return;
   --set->nelem;
   for (; idx < set->nelem; idx++)
index 0493ceb..f44551b 100644 (file)
@@ -863,8 +863,7 @@ re_string_wchar_at (const re_string_t *pstr, Idx idx)
 # ifndef NOT_IN_libc
 static int
 internal_function __attribute__ ((pure, unused))
-re_string_elem_size_at (const re_string_t *pstr _UNUSED_PARAMETER_,
-                       Idx idx _UNUSED_PARAMETER_)
+re_string_elem_size_at (const re_string_t *pstr, Idx idx)
 {
 #  ifdef _LIBC
   const unsigned char *p, *extra;
index fc05e92..7c91449 100644 (file)
@@ -17,8 +17,6 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
-#include "verify.h"
-#include "intprops.h"
 static reg_errcode_t match_ctx_init (re_match_context_t *cache, int eflags,
                                     Idx n) internal_function;
 static void match_ctx_clean (re_match_context_t *mctx) internal_function;
@@ -375,11 +373,8 @@ re_search_2_stub (struct re_pattern_buffer *bufp,
   Idx len = length1 + length2;
   char *s = NULL;
 
-  verify (! TYPE_SIGNED (Idx));
-  if (BE (len < length1, 0))
-     return -2;
-  /* if (BE (length1 < 0 || length2 < 0 || stop < 0, 0))
-     return -2; */
+  if (BE (length1 < 0 || length2 < 0 || stop < 0 || len < length1, 0))
+    return -2;
 
   /* Concatenate the strings.  */
   if (length2 > 0)
@@ -428,14 +423,11 @@ re_search_stub (struct re_pattern_buffer *bufp,
   Idx last_start = start + range;
 
   /* Check for out-of-range.  */
-  verify (! TYPE_SIGNED (Idx));
-  /* if (BE (start < 0, 0))
-     return -1; */
-  if (BE (start > length, 0))
-     return -1;
+  if (BE (start < 0 || start > length, 0))
+    return -1;
   if (BE (length < last_start || (0 <= range && last_start < start), 0))
     last_start = length;
-  else if (BE (/* last_start < 0 || */ (range < 0 && start <= last_start), 0))
+  else if (BE (last_start < 0 || (range < 0 && start <= last_start), 0))
     last_start = 0;
 
   lock_lock (dfa->lock);
index 5deca39..247f0d8 100644 (file)
@@ -38,8 +38,7 @@
    other system header files; just include the system's <stdint.h>.
    Ideally we should test __BIONIC__ here, but it is only defined after
    <sys/cdefs.h> has been included; hence test __ANDROID__ instead.  */
-#if defined __ANDROID__ \
-    && defined _SYS_TYPES_H_ && !defined __need_size_t
+#if defined __ANDROID__ && defined _GL_INCLUDING_SYS_TYPES_H
 # @INCLUDE_NEXT@ @NEXT_STDINT_H@
 #else
 
index 219ebaf..2c33d58 100644 (file)
 #include "verify.h"
 
 #ifdef UNSIGNED
-# ifndef HAVE_DECL_STRTOULL
+# if HAVE_UNSIGNED_LONG_LONG_INT
+#  ifndef HAVE_DECL_STRTOULL
 "this configure-time declaration test was not run"
-# endif
-# if !HAVE_DECL_STRTOULL && HAVE_UNSIGNED_LONG_LONG_INT
+#  endif
+#  if !HAVE_DECL_STRTOULL
 unsigned long long int strtoull (char const *, char **, int);
+#  endif
 # endif
 
 #else
 
-# ifndef HAVE_DECL_STRTOLL
+# if HAVE_LONG_LONG_INT
+#  ifndef HAVE_DECL_STRTOLL
 "this configure-time declaration test was not run"
-# endif
-# if !HAVE_DECL_STRTOLL && HAVE_LONG_LONG_INT
+#  endif
+#  if !HAVE_DECL_STRTOLL
 long long int strtoll (char const *, char **, int);
+#  endif
 # endif
 #endif
 
index d3a4be1..deb5d67 100644 (file)
@@ -23,7 +23,9 @@
 #ifndef _@GUARD_PREFIX@_SYS_TYPES_H
 
 /* The include_next requires a split double-inclusion guard.  */
+# define _GL_INCLUDING_SYS_TYPES_H
 #@INCLUDE_NEXT@ @NEXT_SYS_TYPES_H@
+# undef _GL_INCLUDING_SYS_TYPES_H
 
 #ifndef _@GUARD_PREFIX@_SYS_TYPES_H
 #define _@GUARD_PREFIX@_SYS_TYPES_H
index 58dc5bf..81abdf4 100644 (file)
 
 /* Some systems don't define struct timespec (e.g., AIX 4.1, Ultrix 4.3).
    Or they define it with the wrong member names or define it in <sys/time.h>
-   (e.g., FreeBSD circa 1997).  Stock Mingw does not define it, but the
-   pthreads-win32 library defines it in <pthread.h>.  */
+   (e.g., FreeBSD circa 1997).  Stock Mingw prior to 3.0 does not define it,
+   but the pthreads-win32 library defines it in <pthread.h>.  */
 # if ! @TIME_H_DEFINES_STRUCT_TIMESPEC@
 #  if @SYS_TIME_H_DEFINES_STRUCT_TIMESPEC@
 #   include <sys/time.h>
 #  elif @PTHREAD_H_DEFINES_STRUCT_TIMESPEC@
 #   include <pthread.h>
-/* The pthreads-win32 <pthread.h> also defines a couple of broken macros.  */
-#   undef asctime_r
-#   undef ctime_r
-#   undef gmtime_r
-#   undef localtime_r
-#   undef rand_r
-#   undef strtok_r
 #  else
 
 #   ifdef __cplusplus
index 39b128a..622b228 100644 (file)
 #endif
 @PRAGMA_COLUMNS@
 
+#ifdef _GL_INCLUDING_UNISTD_H
+/* Special invocation convention:
+   - On Mac OS X 10.3.9 we have a sequence of nested includes
+     <unistd.h> -> <signal.h> -> <pthread.h> -> <unistd.h>
+     In this situation, the functions are not yet declared, therefore we cannot
+     provide the C++ aliases.  */
+
+#@INCLUDE_NEXT@ @NEXT_UNISTD_H@
+
+#else
+/* Normal invocation convention.  */
+
 /* The include_next requires a split double-inclusion guard.  */
 #if @HAVE_UNISTD_H@
+# define _GL_INCLUDING_UNISTD_H
 # @INCLUDE_NEXT@ @NEXT_UNISTD_H@
+# undef _GL_INCLUDING_UNISTD_H
 #endif
 
 /* Get all possible declarations of gethostname().  */
@@ -1539,4 +1553,5 @@ _GL_CXXALIASWARN (write);
 _GL_INLINE_HEADER_END
 
 #endif /* _@GUARD_PREFIX@_UNISTD_H */
+#endif /* _GL_INCLUDING_UNISTD_H */
 #endif /* _@GUARD_PREFIX@_UNISTD_H */
index 5f89145..0bd6bce 100644 (file)
@@ -122,10 +122,9 @@ xnrealloc (void *p, size_t n, size_t s)
 
 /* If P is null, allocate a block of at least *PN such objects;
    otherwise, reallocate P so that it contains more than *PN objects
-   each of S bytes.  *PN must be nonzero unless P is null, and S must
-   be nonzero.  Set *PN to the new number of objects, and return the
-   pointer to the new block.  *PN is never set to zero, and the
-   returned pointer is never null.
+   each of S bytes.  S must be nonzero.  Set *PN to the new number of
+   objects, and return the pointer to the new block.  *PN is never set
+   to zero, and the returned pointer is never null.
 
    Repeated reallocations are guaranteed to make progress, either by
    allocating an initial block with a nonzero size, or by allocating a
@@ -196,13 +195,13 @@ x2nrealloc (void *p, size_t *pn, size_t s)
     }
   else
     {
-      /* Set N = ceil (1.5 * N) so that progress is made if N == 1.
+      /* Set N = floor (1.5 * N) + 1 so that progress is made even if N == 0.
          Check for overflow, so that N * S stays in size_t range.
-         The check is slightly conservative, but an exact check isn't
+         The check may be slightly conservative, but an exact check isn't
          worth the trouble.  */
       if ((size_t) -1 / 3 * 2 / s <= n)
         xalloc_die ();
-      n += (n + 1) / 2;
+      n += n / 2 + 1;
     }
 
   *pn = n;
index b494772..8eca551 100644 (file)
@@ -1,4 +1,4 @@
-# 00gnulib.m4 serial 2
+# 00gnulib.m4 serial 3
 dnl Copyright (C) 2009-2014 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -6,7 +6,23 @@ dnl with or without modifications, as long as this notice is preserved.
 
 dnl This file must be named something that sorts before all other
 dnl gnulib-provided .m4 files.  It is needed until such time as we can
-dnl assume Autoconf 2.64, with its improved AC_DEFUN_ONCE semantics.
+dnl assume Autoconf 2.64, with its improved AC_DEFUN_ONCE and
+dnl m4_divert semantics.
+
+# Until autoconf 2.63, handling of the diversion stack required m4_init
+# to be called first; but this does not happen with aclocal.  Wrapping
+# the entire execution in another layer of the diversion stack fixes this.
+# Worse, prior to autoconf 2.62, m4_wrap depended on the underlying m4
+# for whether it was FIFO or LIFO; in order to properly balance with
+# m4_init, we need to undo our push just before anything wrapped within
+# the m4_init body.  The way to ensure this is to wrap both sides of
+# m4_init with a one-shot macro that does the pop at the right time.
+m4_ifndef([_m4_divert_diversion],
+[m4_divert_push([KILL])
+m4_define([gl_divert_fixup], [m4_divert_pop()m4_define([$0])])
+m4_define([m4_init],
+  [gl_divert_fixup()]m4_defn([m4_init])[gl_divert_fixup()])])
+
 
 # AC_DEFUN_ONCE([NAME], VALUE)
 # ----------------------------
index ae31e80..20ce40e 100644 (file)
@@ -1,4 +1,4 @@
-# gnulib-common.m4 serial 33
+# gnulib-common.m4 serial 34
 dnl Copyright (C) 2007-2014 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -375,3 +375,63 @@ AC_DEFUN([gl_CACHE_VAL_SILENT],
   AC_CACHE_VAL([$1], [$2])
   as_echo_n="$saved_as_echo_n"
 ])
+
+# AS_VAR_COPY was added in autoconf 2.63b
+m4_define_default([AS_VAR_COPY],
+[AS_LITERAL_IF([$1[]$2], [$1=$$2], [eval $1=\$$2])])
+
+# AC_PROG_SED was added in autoconf 2.59b
+m4_ifndef([AC_PROG_SED],
+[AC_DEFUN([AC_PROG_SED],
+[AC_CACHE_CHECK([for a sed that does not truncate output], ac_cv_path_SED,
+    [dnl ac_script should not contain more than 99 commands (for HP-UX sed),
+     dnl but more than about 7000 bytes, to catch a limit in Solaris 8 /usr/ucb/sed.
+     ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
+     for ac_i in 1 2 3 4 5 6 7; do
+       ac_script="$ac_script$as_nl$ac_script"
+     done
+     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
+     AS_UNSET([ac_script])
+     if test -z "$SED"; then
+       ac_path_SED_found=false
+       _AS_PATH_WALK([], [
+         for ac_prog in sed gsed; do
+           for ac_exec_ext in '' $ac_executable_extensions; do
+             ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
+             AS_EXECUTABLE_P(["$ac_path_SED"]) || continue
+             case `"$ac_path_SED" --version 2>&1` in
+               *GNU*) ac_cv_path_SED=$ac_path_SED ac_path_SED_found=:;;
+               *)
+                 ac_count=0
+                 _AS_ECHO_N([0123456789]) >conftest.in
+                 while :
+                 do
+                   cat conftest.in conftest.in >conftest.tmp
+                   mv conftest.tmp conftest.in
+                   cp conftest.in conftest.nl
+                   echo >> conftest.nl
+                   "$ac_path_SED" -f conftest.sed <conftest.nl >conftest.out 2>/dev/null || break
+                   diff conftest.out conftest.nl >/dev/null 2>&1 || break
+                   ac_count=`expr $ac_count + 1`
+                   if test $ac_count -gt ${ac_path_SED_max-0}; then
+                     # Best so far, but keep looking for better
+                     ac_cv_path_SED=$ac_path_SED
+                     ac_path_SED_max=$ac_count
+                   fi
+                   test $ac_count -gt 10 && break
+                 done
+                 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+             esac
+             $ac_path_SED_found && break 3
+           done
+         done])
+       if test -z "$ac_cv_path_SED"; then
+         AC_ERROR([no acceptable sed could be found in \$PATH])
+       fi
+     else
+       ac_cv_path_SED=$SED
+     fi
+ SED="$ac_cv_path_SED"
+ AC_SUBST([SED])dnl
+ rm -f conftest.sed
+])])])
index d613fef..4ee6363 100644 (file)
@@ -221,6 +221,8 @@ AC_DEFUN([gl_EARLY],
   # Code from module mbuiter:
   # Code from module memchr:
   # Code from module memchr-tests:
+  # Code from module memchr2:
+  # Code from module memchr2-tests:
   # Code from module mempcpy:
   # Code from module memrchr:
   # Code from module memrchr-tests:
@@ -628,6 +630,7 @@ AC_DEFUN([gl_INIT],
   gl_SYS_STAT_MODULE_INDICATOR([lstat])
   AC_CONFIG_COMMANDS_PRE([m4_ifdef([AH_HEADER],
     [AC_SUBST([CONFIG_INCLUDE], m4_defn([AH_HEADER]))])])
+  AC_REQUIRE([AC_PROG_SED])
   gl_FUNC_MALLOC_GNU
   if test $REPLACE_MALLOC = 1; then
     AC_LIBOBJ([malloc])
@@ -977,6 +980,9 @@ changequote([, ])dnl
   gl_FUNC_MMAP_ANON
   AC_CHECK_HEADERS_ONCE([sys/mman.h])
   AC_CHECK_FUNCS_ONCE([mprotect])
+  gl_FUNC_MMAP_ANON
+  AC_CHECK_HEADERS_ONCE([sys/mman.h])
+  AC_CHECK_FUNCS_ONCE([mprotect])
   gt_LOCALE_FR
   gt_LOCALE_FR_UTF8
   gl_FUNC_PIPE
@@ -1290,6 +1296,9 @@ AC_DEFUN([gl_FILE_LIST], [
   lib/mbuiter.h
   lib/memchr.c
   lib/memchr.valgrind
+  lib/memchr2.c
+  lib/memchr2.h
+  lib/memchr2.valgrind
   lib/mempcpy.c
   lib/memrchr.c
   lib/minmax.h
@@ -1684,6 +1693,7 @@ AC_DEFUN([gl_FILE_LIST], [
   tests/test-mbsstr3.c
   tests/test-mbsstr3.sh
   tests/test-memchr.c
+  tests/test-memchr2.c
   tests/test-memrchr.c
   tests/test-nl_langinfo.c
   tests/test-nl_langinfo.sh
index 8339d40..e1cee6c 100644 (file)
@@ -146,7 +146,6 @@ AC_DEFUN([gl_MANYWARN_ALL_GCC],
     -Wmissing-include-dirs \
     -Wmissing-parameter-type \
     -Wmissing-prototypes \
-    -Wmudflap \
     -Wmultichar \
     -Wnarrowing \
     -Wnested-externs \
index cae2dda..b6cd5a2 100644 (file)
--- a/maint.mk
+++ b/maint.mk
@@ -76,7 +76,7 @@ _dot_escaped_srcdir = $(subst .,\.,$(srcdir))
 ifeq ($(srcdir),.)
   _prepend_srcdir_prefix =
 else
-  _prepend_srcdir_prefix = | sed 's|^|$(srcdir)/|'
+  _prepend_srcdir_prefix = | $(SED) 's|^|$(srcdir)/|'
 endif
 
 # In order to be able to consistently filter "."-relative names,
@@ -85,7 +85,7 @@ endif
 _sc_excl = \
   $(or $(exclude_file_name_regexp--$@),^$$)
 VC_LIST_EXCEPT = \
-  $(VC_LIST) | sed 's|^$(_dot_escaped_srcdir)/||' \
+  $(VC_LIST) | $(SED) 's|^$(_dot_escaped_srcdir)/||' \
        | if test -f $(srcdir)/.x-$@; then grep -vEf $(srcdir)/.x-$@; \
          else grep -Ev -e "$${VC_LIST_EXCEPT_DEFAULT-ChangeLog}"; fi \
        | grep -Ev -e '($(VC_LIST_ALWAYS_EXCLUDE_REGEX)|$(_sc_excl))' \
@@ -158,8 +158,8 @@ export LC_ALL = C
 _cfg_mk := $(wildcard $(srcdir)/cfg.mk)
 
 # Collect the names of rules starting with 'sc_'.
-syntax-check-rules := $(sort $(shell sed -n 's/^\(sc_[a-zA-Z0-9_-]*\):.*/\1/p' \
-                       $(srcdir)/$(ME) $(_cfg_mk)))
+syntax-check-rules := $(sort $(shell $(SED) -n \
+   's/^\(sc_[a-zA-Z0-9_-]*\):.*/\1/p' $(srcdir)/$(ME) $(_cfg_mk)))
 .PHONY: $(syntax-check-rules)
 
 ifeq ($(shell $(VC_LIST) >/dev/null 2>&1; echo $$?),0)
@@ -448,7 +448,7 @@ sc_require_config_h_first:
        @if $(VC_LIST_EXCEPT) | grep -l '\.c$$' > /dev/null; then       \
          fail=0;                                                       \
          for i in $$($(VC_LIST_EXCEPT) | grep '\.c$$'); do             \
-           grep '^# *include\>' $$i | sed 1q                           \
+           grep '^# *include\>' $$i | $(SED) 1q                        \
                | grep -E '^# *include $(config_h_header)' > /dev/null  \
              || { echo $$i; fail=1; };                                 \
          done;                                                         \
@@ -468,7 +468,7 @@ sc_prohibit_HAVE_MBRTOWC:
 # re: a regular expression that matches IFF something provided by $h is used.
 define _sc_header_without_use
   dummy=; : so we do not need a semicolon before each use;             \
-  h_esc=`echo '[<"]'"$$h"'[">]'|sed 's/\./\\\\./g'`;                   \
+  h_esc=`echo '[<"]'"$$h"'[">]'|$(SED) 's/\./\\\\./g'`;                        \
   if $(VC_LIST_EXCEPT) | grep -l '\.c$$' > /dev/null; then             \
     files=$$(grep -l '^# *include '"$$h_esc"                           \
             $$($(VC_LIST_EXCEPT) | grep '\.c$$')) &&                   \
@@ -591,7 +591,7 @@ sc_prohibit_root_dev_ino_without_use:
 
 sc_prohibit_openat_without_use:
        @h='openat.h' \
-       re='\<(openat_(permissive|needs_fchdir|(save|restore)_fail)|l?(stat|ch(own|mod))at|(euid)?accessat)\>' \
+       re='\<(openat_(permissive|needs_fchdir|(save|restore)_fail)|l?(stat|ch(own|mod))at|(euid)?accessat|(FCHMOD|FCHOWN|STAT)AT_INLINE)\>' \
          $(_sc_header_without_use)
 
 # Prohibit the inclusion of c-ctype.h without an actual use.
@@ -789,7 +789,7 @@ sc_useless_cpp_parens:
 # #if HAVE_HEADER_H that you remove, be sure that your project explicitly
 # requires the gnulib module that guarantees the usability of that header.
 gl_assured_headers_ = \
-  cd $(gnulib_dir)/lib && echo *.in.h|sed 's/\.in\.h//g'
+  cd $(gnulib_dir)/lib && echo *.in.h|$(SED) 's/\.in\.h//g'
 
 # Convert the list of names to upper case, and replace each space with "|".
 az_ = abcdefghijklmnopqrstuvwxyz
@@ -840,7 +840,7 @@ define def_sym_regex
              && perl -lne '$(gl_extract_significant_defines_)' $$f;    \
          done;                                                         \
        ) | sort -u                                                     \
-         | sed 's/^/^ *# *(define|undef)  */;s/$$/\\>/'
+         | $(SED) 's/^/^ *# *(define|undef)  */;s/$$/\\>/'
 endef
 
 # Don't define macros that we already get from gnulib header files.
@@ -1054,12 +1054,12 @@ sc_const_long_option:
          $(_sc_search_regexp)
 
 NEWS_hash =                                                            \
-  $$(sed -n '/^\*.* $(PREV_VERSION_REGEXP) ([0-9-]*)/,$$p'             \
+  $$($(SED) -n '/^\*.* $(PREV_VERSION_REGEXP) ([0-9-]*)/,$$p'          \
        $(srcdir)/NEWS                                                  \
      | perl -0777 -pe                                                  \
        's/^Copyright.+?Free\sSoftware\sFoundation,\sInc\.\n//ms'       \
      | md5sum -                                                                \
-     | sed 's/ .*//')
+     | $(SED) 's/ .*//')
 
 # Ensure that we don't accidentally insert an entry into an old NEWS block.
 sc_immutable_NEWS:
@@ -1097,7 +1097,7 @@ sc_makefile_at_at_check:
          && { echo '$(ME): use $$(...), not @...@' 1>&2; exit 1; } || :
 
 news-check: NEWS
-       $(AM_V_GEN)if sed -n $(news-check-lines-spec)p $<               \
+       $(AM_V_GEN)if $(SED) -n $(news-check-lines-spec)p $<            \
            | grep -E $(news-check-regexp) >/dev/null; then             \
          :;                                                            \
        else                                                            \
@@ -1146,7 +1146,7 @@ sc_po_check:
            files="$$files $$file";                                     \
          done;                                                         \
          grep -E -l '$(_gl_translatable_string_re)' $$files            \
-           | sed 's|^$(_dot_escaped_srcdir)/||' | sort -u > $@-2;      \
+           | $(SED) 's|^$(_dot_escaped_srcdir)/||' | sort -u > $@-2;   \
          diff -u -L $(po_file) -L $(po_file) $@-1 $@-2                 \
            || { printf '$(ME): '$(fix_po_file_diag) 1>&2; exit 1; };   \
          rm -f $@-1 $@-2;                                              \
@@ -1192,7 +1192,7 @@ sc_copyright_check:
        in_vc_files=$(sample-test)                                      \
        halt='out of date copyright in $(sample-test); update it'       \
          $(_sc_search_regexp)
-       @require='Copyright @copyright\{\} .*'$$(date +%Y)' Free'       \
+       @require='Copyright @copyright\{\} .*'$$(date +%Y)              \
        in_vc_files=$(texi)                                             \
        halt='out of date copyright in $(texi); update it'              \
          $(_sc_search_regexp)
@@ -1511,7 +1511,7 @@ refresh-gnulib-patches:
          test -n "$$t" && gl=$$t;                                      \
        fi;                                                             \
        for diff in $$(cd $$gl; git ls-files | grep '\.diff$$'); do     \
-         b=$$(printf %s "$$diff"|sed 's/\.diff$$//');                  \
+         b=$$(printf %s "$$diff"|$(SED) 's/\.diff$$//');               \
          VERSION_CONTROL=none                                          \
            patch "$(gnulib_dir)/$$b" "$$gl/$$diff" || exit 1;          \
          ( cd $(gnulib_dir) || exit 1;                                 \
@@ -1530,7 +1530,8 @@ refresh-po:
        wget --no-verbose --directory-prefix $(PODIR) --no-directories --recursive --level 1 --accept .po --accept .po.1 $(POURL) && \
        echo 'en@boldquot' > $(PODIR)/LINGUAS && \
        echo 'en@quot' >> $(PODIR)/LINGUAS && \
-       ls $(PODIR)/*.po | sed 's/\.po//;s,$(PODIR)/,,' | sort >> $(PODIR)/LINGUAS
+       ls $(PODIR)/*.po | $(SED) 's/\.po//;s,$(PODIR)/,,' | \
+         sort >> $(PODIR)/LINGUAS
 
  # Running indent once is not idempotent, but running it twice is.
 INDENT_SOURCES ?= $(C_SOURCES)
@@ -1640,18 +1641,18 @@ _gl_tight_scope: $(bin_PROGRAMS)
               test -f $$f && d= || d=$(srcdir)/; echo $$d$$f; done`;   \
        ( printf '^%s$$\n' '__.*' $(_gl_TS_unmarked_extern_functions);  \
          grep -h -A1 '^extern .*[^;]$$' $$src                          \
-           | grep -vE '^(extern |--)' | sed 's/ .*//';                 \
+           | grep -vE '^(extern |--)' | $(SED) 's/ .*//';              \
          perl -lne                                                     \
             '$(_gl_TS_function_match) and print "^$$1\$$"' $$hdr;      \
        ) | sort -u > $$t;                                              \
-       nm -e $(_gl_TS_obj_files) | sed -n 's/.* T //p'|grep -Ev -f $$t \
+       nm -e $(_gl_TS_obj_files)|$(SED) -n 's/.* T //p'|grep -Ev -f $$t \
          && { echo the above functions should have static scope >&2;   \
               exit 1; } || : ;                                         \
        ( printf '^%s$$\n' '__.*' $(_gl_TS_unmarked_extern_vars);       \
          perl -lne '$(_gl_TS_var_match) and print "^$$1\$$"'           \
                $$hdr $(_gl_TS_other_headers)                           \
        ) | sort -u > $$t;                                              \
-       nm -e $(_gl_TS_obj_files) | sed -n 's/.* [BCDGRS] //p'          \
+       nm -e $(_gl_TS_obj_files) | $(SED) -n 's/.* [BCDGRS] //p'       \
             | sort -u | grep -Ev -f $$t                                        \
          && { echo the above variables should have static scope >&2;   \
               exit 1; } || :
index c6385d2..c5c9979 100644 (file)
@@ -27,9 +27,5 @@ lib/version-etc.c
 lib/xalloc-die.c
 lib/xstrtol-error.c
 src/dfa.c
-src/egrep.c
-src/fgrep.c
 src/grep.c
-src/kwset.c
-src/main.c
 src/pcresearch.c
index 48cb277..4eef663 100644 (file)
Binary files a/po/af.gmo and b/po/af.gmo differ
index 3ec9a83..a6f14e8 100644 (file)
--- a/po/af.po
+++ b/po/af.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5g\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2004-03-03 13:33+0200\n"
 "Last-Translator: Petri Jooste <rkwjpj@puk.ac.za>\n"
 "Language-Team: Afrikaans <i18n@af.org.za>\n"
@@ -29,7 +29,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -96,8 +96,8 @@ msgstr "%s: opsie `-W %s' laat nie 'n parameter toe nie\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opsie `%s' benodig 'n parameter\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "geheue uitgeput"
@@ -193,7 +193,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -213,7 +213,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -347,7 +347,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -369,7 +369,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -388,128 +388,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Ongebalanseerde ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Onbeëindigde \\-ontsnapstring"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Ongebalanseerde ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Geen sintaks gespesifiseer"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Ongebalanseerde )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ongeldige konteks-lengte-parameter"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "toevoer is te veel om te tel"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binêre lêer %s pas\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "waarskuwing: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiewe lus van gidsinskrywings"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standaardtoevoer)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Gebruik so: %s [OPSIE]... PATROON [LÊER]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Probeer `%s --help' vir meer inligting.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -521,7 +500,7 @@ msgstr ""
 "\n"
 "Reëlmatige uitdrukking-seleksie en -interpretasie:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -537,7 +516,7 @@ msgstr ""
 "  -G, --basic-regexp        PATROON is 'n basic regular expression\n"
 "  -P, --perl-regexp         PATROON is 'n  Perl regular expression\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -555,16 +534,15 @@ msgstr ""
 "  -z, --null-data           elke datareël eindig met 'n 0-greep, nie 'n "
 "nuwereëlkarakter nie\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Verskeie:\n"
@@ -574,7 +552,7 @@ msgstr ""
 "      --help                wys hierdie hulpboodskap en stop\n"
 "      --mmap                gebruik geheue-gebonde toevoer indien moontlik\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -589,7 +567,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -599,7 +577,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -611,7 +589,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -622,7 +600,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -632,7 +610,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -642,7 +620,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -675,7 +653,14 @@ msgstr ""
 "Indien minder as twee LÊERs gegee is, aanvaar -h. Uittreestatus is\n"
 " 0 vir passing, 1 vir geen passing, en 2 vir probleemgevalle.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -685,88 +670,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "teenstrydige passers is gespesifiseer"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "ongeldige maks-telling"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "onbekende metode vir toestelle"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ongeldige maks-telling"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "onbekende binêre-lêertipe"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Die -P opsie word nie ondersteun nie"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 26909b1..fa9fa36 100644 (file)
Binary files a/po/be.gmo and b/po/be.gmo differ
index 12b0516..43fbd9d 100644 (file)
--- a/po/be.po
+++ b/po/be.po
@@ -5,7 +5,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5g\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2003-07-22 17:18+0300\n"
 "Last-Translator: Ales Nyakhaychyk <nab@mail.by>\n"
 "Language-Team: Belarusian <i18n@mova.org>\n"
@@ -29,7 +29,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -93,8 +93,8 @@ msgstr "%s: выбар \"-W %s\" не дазваляе довады\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: выбар \"%s\" патрабуе довад\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "памяць вычарпана"
@@ -178,7 +178,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -198,7 +198,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -332,7 +332,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -354,7 +354,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -373,128 +373,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Неўраўнаважаная ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Незавершаная \\ кіруючая пасьлядоўнасьць"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Неўраважаная ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Сынтаксіс нявызначаны"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Неўраўнаважаная )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "недапушчальны довад даўжыні кантэксту"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "увод занадта вялікі для падліку"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Супадзеньні двайковага файла %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "Увага! %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "тэчкі зацыклены"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандартны ўвод)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Выкарыстаньне: %s [ВЫБАР]... УЗОР [ФАЙЛ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Паспрабуйце \"%s --help\" для больш падрабязных зьвестак.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -506,7 +485,7 @@ msgstr ""
 "\n"
 "Выбар і тлумачэньне выразаў:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -521,7 +500,7 @@ msgstr ""
 "  -G, --basic-regexp        УЗОР - гэта асноўны сталы выраз.\n"
 "  -P, --perl-regexp         УЗОР - гэта сталы выраз на Perl.\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -540,16 +519,15 @@ msgstr ""
 "  -z, --null-data           Радок даньняў павінен мець канчатак ў выглядзе\n"
 "                            нулявога байта, замест знака новага радка.\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Разнастайныя:\n"
@@ -560,7 +538,7 @@ msgstr ""
 "      --mmap                Выкарыстоўваць memory-mapped, калі гэта "
 "магчыма.\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -575,7 +553,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -585,7 +563,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -597,7 +575,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -608,7 +586,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -618,7 +596,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -628,7 +606,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -661,7 +639,14 @@ msgstr ""
 "роўны 0, калі ё супадзеньні, 1, калі супадзеньняў няма й 2 у выпадку "
 "памылкі.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -671,88 +656,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "заданы супярэчлівыя супадальнікі"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "недапушчальны найбольшы лічыльнік"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "невядомы мэтад пралад"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "недапушчальны найбольшы лічыльнік"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "невядомы від дваічнага файла"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Выбар -P непадтрымліваецца"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 9e8f959..b8c4cb0 100644 (file)
Binary files a/po/bg.gmo and b/po/bg.gmo differ
index 9cbfad8..dbe0de6 100644 (file)
--- a/po/bg.po
+++ b/po/bg.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep 2.5g\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2002-03-09 02:00+0200\n"
 "Last-Translator: Pavel Mihaylov <avatarbg@bulgaria.com>\n"
 "Language-Team: Bulgarian <bg@bulgaria.com>\n"
@@ -29,7 +29,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -93,8 +93,8 @@ msgstr "%s: опция `-W %s' се използва без аргумент\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: опция `%s' изисква аргумент\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "паметта е изчерпана"
@@ -178,7 +178,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -198,7 +198,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -332,7 +332,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -354,7 +354,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -373,128 +373,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Небалансирана ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Незавършена \\ последователност"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Небалансирана ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Не е зададен синтаксис"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Небалансирана )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "невалиден размер на контекста"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "входните данни са прекалено големи за да бъдат преброени"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Двоичен файл %s съвпада\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "предупреждение: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "рекурсивна обработка на директориите"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандартен вход)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Употреба: %s [ОПЦИЯ]... ТЕКСТ [ФАЙЛ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Вижте `%s --help' за повече информация.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -506,7 +485,7 @@ msgstr ""
 "\n"
 "Избор на типа регулярен израз и интерпретация:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -520,7 +499,7 @@ msgstr ""
 "  -G, --basic-regexp        ТЕКСТ е прост регулярен израз\n"
 "  -P, --perl-regexp         ТЕКСТ е Perl регулярен израз\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -538,16 +517,15 @@ msgstr ""
 "  -z, --null-data           редовете във ФАЙЛ завършват с 0 (NULL),\n"
 "                            а не със символ за нов ред (LF)\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Разни:\n"
@@ -557,7 +535,7 @@ msgstr ""
 "      --help                показва помощна информация и излиза\n"
 "      --mmap                използва memory-mapped вход ако е възможно\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -572,7 +550,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -582,7 +560,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -594,7 +572,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -605,7 +583,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -615,7 +593,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -625,7 +603,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -656,7 +634,14 @@ msgstr ""
 "Ако са зададени по-малко от два ФАЙЛа се предполага -h.\n"
 "При изход grep връща 0 ако има съвпадение, 1 ако няма и 2 при грешка.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -666,88 +651,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "зададените изрази за съвпадение са в конфликт"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "невалиден максимален брой"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "неизвестен метод за обработка на специалните файлове"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "невалиден максимален брой"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "непознат тип двоичен файл"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Опция -P не се поддържа"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 1f6d3b1..4af8f49 100644 (file)
Binary files a/po/ca.gmo and b/po/ca.gmo differ
index 69e41fb..c112bae 100644 (file)
--- a/po/ca.po
+++ b/po/ca.po
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep-2.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-09-22 10:35+0200\n"
 "Last-Translator: Àngel Mompó <mecatxis@gmail.com>\n"
 "Language-Team: Catalan <ca@dodds.net>\n"
@@ -32,7 +32,7 @@ msgstr "l'argument %s és ambigu per %s"
 msgid "Valid arguments are:"
 msgstr "Els arguments vàlids són:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "error d'escriptura"
@@ -96,8 +96,8 @@ msgstr "%s: l'opció «-W %s» no permet un argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: l'opció «-W %s» necessita un argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memòria exhaurida"
@@ -181,7 +181,7 @@ msgstr "falten o sobren ( o \\("
 msgid "Unmatched \\{"
 msgstr "Falten o sobren \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "El context de \\{\\} no és vàlid"
 
@@ -201,7 +201,7 @@ msgstr "L'expressió regular precedent no és vàlida"
 msgid "Premature end of regular expression"
 msgstr "Final prematur de l'expressió regular"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "L'expressió regular és massa gran"
 
@@ -359,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -383,7 +383,7 @@ msgstr "Pàgina inicial de %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Pàgina inicial de %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Ajuda general d'utilització del programari de GNU: <http://www.gnu.org/"
@@ -404,126 +404,102 @@ msgstr "el sufix «%s» de %s%s no és vàlid"
 msgid "%s%s argument '%s' too large"
 msgstr "l'argument «%s» de %s%s és massa gran"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ desaparellat"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "La classe de caràcter no és vàlida"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "La sintaxi de la classe de caràcter és [[:espai]], no [:espai:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "Codi d'escapada \\ inacabat"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( desaparellat"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "no s'ha especificat cap sintaxi"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") desaparellat"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "El PATRÓ és una expressió regular ampliada (ERA).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "La crida com a «egrep» està desfasada; feu servir «grep -E».\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"El PATRÓ és un conjunt de cadenes fixes separades per salts de línia.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "La crida com a «fgrep» està desfasada; feu servir «grep -F».\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "El PATRÓ és, per defecte, una expressió regular bàsica (ERB).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"«egrep» ara és «grep -E». «fgrep» ara és «grep -F».\n"
-"La crida directa tant de «egrep» com de «fgrep» està desfasada.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "la resta, vegeu <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "la longitud de l'argument no és vàlida"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "l'lseek ha fallat"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "l'entrada és massa llarga per a comptar"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Hi ha coincidències en el fitxer binari %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "aví­s: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "bucle de directori recursiu"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "el fitxer d'entrada %s és també la sortida"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(entrada estàndard)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Forma d'ús: %s [OPCIÓ]... PATRÓ [FITXER] ...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Feu servir «%s --help» per a obtenir més informació.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Busca el PATRÓ a cada FITXER o a l'entrada estàndard.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "El PATRÓ és, per defecte, una expressió regular bàsica (ERB).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -534,7 +510,7 @@ msgstr ""
 "\n"
 "Selecció i interpretació de l'expressió regular:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -549,7 +525,7 @@ msgstr ""
 "  -G, --basic-regexp        PATRÓ és un expressió regular bàsica (ERB)\n"
 "  -P, --perl-regexp         PATRÓ és un expressió regular de Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -569,16 +545,15 @@ msgstr ""
 "  -z, --null-data           considera que una lí­nia de dades acaba amb byte "
 "0 i no amb un salt de línia\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Miscel·lània:\n"
@@ -588,7 +563,7 @@ msgstr ""
 "      --help                mostra aquesta ajuda i surt\n"
 "      --mmap                desfasat. Només mostra un avís\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -615,7 +590,7 @@ msgstr ""
 "      --label=ETIQUETA         fes servir ETIQUETA com a prefix del nom del "
 "fitxer per l'entrada estàndard\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -633,7 +608,7 @@ msgstr ""
 "match»\n"
 "  -a, --text                equivalent a --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -653,7 +628,7 @@ msgstr ""
 "  -R, --dereference-recursive  igual que l'anterior, però segueix tots els "
 "enllaços simbòlics\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -672,7 +647,7 @@ msgstr ""
 "      --exclude-dir=PATRÓ  salta els directoris que coincideixin amb el "
 "PATRÓ.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -690,7 +665,7 @@ msgstr ""
 "  -T, --initial-tab         alinea les tabulacions (si cal)\n"
 "  -Z, --null                mostra 0 byte després del nom de FITXER\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -708,7 +683,7 @@ msgstr ""
 "  -C, --context=NOMBRE        mostra un NOMBRE de línies del context de "
 "sortida\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -733,7 +708,16 @@ msgstr ""
 "                              (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"«egrep» ara és «grep -E». «fgrep» ara és «grep -F».\n"
+"La crida directa tant de «egrep» com de «fgrep» està desfasada.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -749,47 +733,37 @@ msgstr ""
 "L'estat de sortida és 0 si s'havia seleccionat alguna línia, si no 1.\n"
 "Si hi ha algun error i no s'ha indicat -q, l'estat de sortida és 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Pàgina principal del Grep de GNU: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s només pot fer servir la sintaxis de patró %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "s'han especificat expressions conflictives"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "l'expressió %s no és vàlida"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "el mètode de dispositius és desconegut"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "el comptador de màxims no és vàlid"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "el tipus de fitxer binari és desconegut"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "la opció --mmap no fa res des del 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -797,48 +771,67 @@ msgstr ""
 "el suport per l'opció -P no està  compilat a aquest binari --disable-perl-"
 "regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "l'opció -P només suporta un sol patró"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "error intern"
 
 # PCRE is 'Perl Compatible Regular Expression'
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "s'ha superat el límit de longitud de línia del PCRE"
 
 # PCRE is 'Perl Compatible Regular Expression'
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "s'ha superat el límit de l'estratègia «tornada enrere» del PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "error intern"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "El PATRÓ és una expressió regular ampliada (ERA).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "La crida com a «egrep» està desfasada; feu servir «grep -E».\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "El PATRÓ és un conjunt de cadenes fixes separades per salts de línia.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "La crida com a «fgrep» està desfasada; feu servir «grep -F».\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s només pot fer servir la sintaxis de patró %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "la opció --mmap no fa res des del 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "comptador de repeticions inacabat"
 
index 3305bf2..9dd59fc 100644 (file)
Binary files a/po/cs.gmo and b/po/cs.gmo differ
index f316f6f..192c0ff 100644 (file)
--- a/po/cs.po
+++ b/po/cs.po
@@ -3,14 +3,15 @@
 # This file is distributed under the same license as the grep package.
 # Vladimir Michl <Vladimir.Michl@seznam.cz>, 1998.
 # Petr Pisar <petr.pisar@atlas.cz>, 2008, 2009, 2010, 2011, 2012, 201, 2013.
+# Petr Pisar <petr.pisar@atlas.cz>, 2014.
 #
 # Thanks to: Stanislav Brabec <utx@k332.feld.cvut.cz>
 msgid ""
 msgstr ""
-"Project-Id-Version: grep 2.14.46\n"
+"Project-Id-Version: grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-10-21 19:58+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 16:52+0200\n"
 "Last-Translator: Petr Pisar <petr.pisar@atlas.cz>\n"
 "Language-Team: Czech <translation-team-cs@lists.sourceforge.net>\n"
 "Language: cs\n"
@@ -32,7 +33,7 @@ msgstr "nejednoznačný argument %s u %s"
 msgid "Valid arguments are:"
 msgstr "Platné argumenty jsou:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "chyba při zápisu"
@@ -96,8 +97,8 @@ msgstr "%s: přepínač „-W %s“ musí být zadán bez argumentu\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: přepínač „-W %s“ vyžaduje argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "paměť vyčerpána"
@@ -181,7 +182,7 @@ msgstr "Nepárový ( nebo \\("
 msgid "Unmatched \\{"
 msgstr "Nepárový \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Neplatný obsah \\{\\}"
 
@@ -201,7 +202,7 @@ msgstr "Neplatný předchozí regulární výraz"
 msgid "Premature end of regular expression"
 msgstr "Předčasný konec regulárního výrazu"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regulární výraz je příliš velký"
 
@@ -358,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -384,7 +385,7 @@ msgstr "Domovská stránka programu %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Domovská stránka programu %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Obecná pomoc s používáním GNU softwaru: <http://www.gnu.org/gethelp/>\n"
@@ -404,122 +405,93 @@ msgstr "neplatná přípona argumentu „%3$s“ u %1$s%2$s"
 msgid "%s%s argument '%s' too large"
 msgstr "argument „%3$s“ u %1$s%2$s je příliš dlouhý"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "nevyvážená ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "neplatný třída znaků"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "zápis třídy znaků je [[:space:]], ne [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "neukončená escape sekvence \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "nevyvážená ("
 
 # ? Není zadaná syntaxe
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "syntaxe není určena"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "nevyvážená )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "VZOREK představuje rozšířený regulární výraz (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Spouštění programu jako „egrep“ je zastaralé; použijte „grep -E“.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "VZOREK představuje množinu řetězců, každý na novém řádku.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Spouštění programu jako „fgrep“ je zastaralé; použijte „grep -F“.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"VZOREK představuje základní regulární výraz (BRE), pokud není řečeno jinak.\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep“ znamená „grep -E“. „fgrep“ znamená „grep -F“.\n"
-"Přímé spouštění příkazem „egrep“ nebo „fgrep“ je zastaralé.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "další, vizte <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "neplatný argument délky kontextu"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "posun v souboru (lseek) se nezdařil"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "počet vstupních řádků nelze spočítat (je jich hodně)"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binární soubor %s odpovídá\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "varování: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "smyčka pro rekurzivní průchod"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "vstupní soubor %s je rovněž výstupem"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standardní vstup)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Použití: %s [PŘEPÍNAČ]… VZOREK [SOUBOR]…\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Více informací získáte příkazem „%s --help“.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
@@ -527,7 +499,13 @@ msgstr ""
 "postupně\n"
 "ze všech zadaných SOUBORů nebo ze standardního vstupu.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"VZOREK představuje základní regulární výraz (BRE), pokud není řečeno jinak.\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -538,7 +516,7 @@ msgstr ""
 "\n"
 "Výběr a interpretace regulárního výrazu:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -553,7 +531,7 @@ msgstr ""
 "  -G, --basic-regexp        VZOREK je základní regulární výraz (BRE)\n"
 "  -P, --perl-regexp         VZOREK je regulární výraz z jazyka Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -571,26 +549,24 @@ msgstr ""
 "  -z, --null-data           řádek končí nulovým bajtem místo znaku nového "
 "řádku\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Různé:\n"
 "  -s, --no-messages         potlačí chybové zprávy\n"
-"  -v, --invert-match        vypíše řádky, které VZORKU nevyhovují\n"
+"  -v, --invert-match        vybere neodpovídající řádky\n"
 "  -V, --version             vypíše označení verze a skončí\n"
 "      --help                vypíše tuto nápovědu a skončí\n"
-"      --mmap                bez významu, zastaralé, vypíše upozornění\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -617,7 +593,7 @@ msgstr ""
 "      --label=NÁZEV         použije NÁZEV jako označení standardního\n"
 "                            vstupu na výstupu\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -634,7 +610,7 @@ msgstr ""
 "                            nebo „without-match“ (bez vyhovění vzorku)\n"
 "  -a, --text                jako --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -658,7 +634,7 @@ msgstr ""
 "                            obdobně, jen následuje všechny symbolické "
 "odkazy\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -678,7 +654,7 @@ msgstr ""
 "      --exclude-dir=VZOREK  adresáře, které vyhovují vzorku, budou "
 "přeskočeny\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -697,7 +673,7 @@ msgstr ""
 "třeba)\n"
 "  -Z, --null                vypíše nulový bajt za jménem SOUBORU\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -712,7 +688,7 @@ msgstr ""
 "  -A, --after-context=POČET  vypíše POČET řádků za shodou\n"
 "  -C, --context=POČET        vypíše POČET řádků kontextu (před i za shodou)\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -736,7 +712,16 @@ msgstr ""
 "  -u, --unix-byte-offsets    vypisuje pozici, jako by CR nebyly v souboru\n"
 "                             (MSDOS/Windows)\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep“ znamená „grep -E“. „fgrep“ znamená „grep -F“.\n"
+"Přímé spouštění příkazem „egrep“ nebo „fgrep“ je zastaralé.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -751,47 +736,37 @@ msgstr ""
 "Návratový kód je 0 při nalezení vyhovujícího řádku, 1 nevyhovoval-li žádný\n"
 "řádek. Vyskytne-li se chyba a není-li zadán argument -q, bude vrácen kód 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Domovská stránka GNU Grepu: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s umí pouze syntaxi vzorků %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "zadány kolidující vzorky"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "neplatný syntaxe vzorku %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "neznámá metoda obsluhy zařízení"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "neplatný maximální počet"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "neznámý typ binárního souboru"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "přepínač --map nic nedělá již od roku 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -799,45 +774,63 @@ msgstr ""
 "Volba -P není podporována. Tento program byl přeložen s --disable-perl-"
 "regexp."
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "přepínač -P lze být použít pouze s jedním vzorkem"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "vnitřní chyba (to by se nikdy nemělo stát)"
 
-#: src/pcresearch.c:130
-#, fuzzy, c-format
+#: src/pcresearch.c:120
+#, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
-msgstr "paměť pro zásobník JIT nelze alokovat"
+msgstr "alokace paměti pro JIT zásobník PCRE selhala"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "vnitřní chyba"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "překročeno omezení PCRE na délku řádku"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "překročeno omezení PCRE na hloubku zanoření"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
-msgstr ""
+msgstr "neplatná posloupnost UTF-8 bajtů ve vstupu"
 
-#: src/pcresearch.c:206
-#, fuzzy, c-format
+#: src/pcresearch.c:192
+#, c-format
 msgid "internal PCRE error: %d"
-msgstr "vnitřní chyba"
+msgstr "vnitřní chyba PCRE: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "VZOREK představuje rozšířený regulární výraz (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Spouštění programu jako „egrep“ je zastaralé; použijte „grep -E“.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "VZOREK představuje množinu řetězců, každý na novém řádku.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Spouštění programu jako „fgrep“ je zastaralé; použijte „grep -F“.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s umí pouze syntaxi vzorků %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "přepínač --map nic nedělá již od roku 2010"
 
 #~ msgid "unfinished repeat count"
 #~ msgstr "neukončený zápis počtu opakování"
index 76ad942..025a979 100644 (file)
Binary files a/po/da.gmo and b/po/da.gmo differ
index 588c878..c6c52f1 100644 (file)
--- a/po/da.po
+++ b/po/da.po
@@ -29,7 +29,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep-2.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-11-01 02:12+0100\n"
 "Last-Translator: Ask Hjorth Larsen <asklarsen@gmail.com>\n"
 "Language-Team: Danish <dansk@dansk-gruppen.dk>\n"
@@ -52,7 +52,7 @@ msgstr "flertydigt argument %s til %s"
 msgid "Valid arguments are:"
 msgstr "Gyldige argumenter er:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "skrivefejl"
@@ -116,8 +116,8 @@ msgstr "%s: flaget '-W %s' tillader ikke et argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: flaget '-W %s' kræver et argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "hukommelse opbrugt"
@@ -201,7 +201,7 @@ msgstr "Uparret ( eller \\("
 msgid "Unmatched \\{"
 msgstr "Uparret \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Ugyldigt indhold af \\{\\}"
 
@@ -221,7 +221,7 @@ msgstr "Ugyldigt foranstillet regulært udtryk"
 msgid "Premature end of regular expression"
 msgstr "Utidig afslutning af regulært udtryk"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regulært udtryk er for stort"
 
@@ -379,7 +379,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -403,7 +403,7 @@ msgstr "Hjemmeside for %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Hjemmeside for %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Generel hjælp til brug af GNU-software: <http://www.gnu.org/gethelp/>\n"
@@ -423,126 +423,103 @@ msgstr "ugyldigt suffiks i %s%s-argumentet '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s-argumentet '%s' er for stort"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "ubalanceret ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "ugyldig tegnklasse"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "syntaksen for tegnklasser er [[:space:]], ikke [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "ufærdig \\-undvigesekvens"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "ubalanceret ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "ingen syntaks angivet"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "ubalanceret )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MØNSTER er et udvidet regulært udtryk (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Kørsel som 'egrep' er forældet; brug 'grep -E' i stedet.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "MØNSTER er en mængde faste strenge adskilt af linjeskift.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Kørsel som 'fgrep' er forældet; brug 'grep -F' i stedet.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MØNSTER er som standard et almindeligt regulært udtryk (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"'egrep' betyder 'grep -E'.  'fgrep' betyder 'grep -F'.\n"
-"Direkte kørsel som enten 'egrep' eller 'fgrep' er forældet.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "andre, se <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ugyldigt kontekstlængdeargument"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek mislykkedes"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "inddata er for omfattende at optælle"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binær fil %s stemmer\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "advarsel: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiv katalogsløjfe"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "indfilen %s er også udfilen"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standard-inddata)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Brug: %s [FLAG]... MØNSTER [FIL]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Prøv '%s --help' for mere information.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Søg efter MØNSTER i hver FIL eller i standard-inddata.\n"
 
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MØNSTER er som standard et almindeligt regulært udtryk (BRE).\n"
+
 # Nederste linje er en overskrift for en samling af kommandolinjeflag.  Oversættelsen er ikke direkte, men opdelingen skulle være klar nok
-#: src/main.c:1550
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -553,7 +530,7 @@ msgstr ""
 "\n"
 "Regulære udtryk og fortolkning:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -568,7 +545,7 @@ msgstr ""
 "  -G, --basic-regexp        MØNSTER er et almindeligt regulært udtryk (BRE)\n"
 "  -P, --perl-regexp         MØNSTER er et Perl-regulært udtryk\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -586,16 +563,15 @@ msgstr ""
 "  -z, --null-data           en datalinje slutter med en 0-byte, ikke "
 "linjeskift\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diverse:\n"
@@ -605,7 +581,7 @@ msgstr ""
 "      --help                vis denne hjælpetekst og afslut\n"
 "      --mmap                forældet no-op; giver en advarsel\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -630,7 +606,7 @@ msgstr ""
 "  -h, --no-filename          undertryk indledende filnavn i udskrift\n"
 "      --label=NAVN           udskriv NAVN som filnavn for standard-inddata\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -646,7 +622,7 @@ msgstr ""
 "                            TYPE er 'binary', 'text', eller 'without-match'\n"
 "  -a, --text                svarer til --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -667,7 +643,7 @@ msgstr ""
 "  -R, --dereference-recursive  tilsvarende, men følg alle symlænker\n"
 
 # 'spring over' er måske pænere end 'ignorér', men fylder mere, og det er rart at være på <80 kolonner
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -684,7 +660,7 @@ msgstr ""
 "FIL\n"
 "      --exclude-dir=MØNSTER  ignorér kataloger, der matcher MØNSTER.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -701,7 +677,7 @@ msgstr ""
 "  -T, --initial-tab         arrangér tabulatortegn (om nødvendigt)\n"
 "  -Z, --null                udskriv 0-byte efter FILnavn\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -716,7 +692,7 @@ msgstr ""
 "  -A, --after-context=ANTAL  udskriv ANTAL linjer af efterfølgende tekst\n"
 "  -C, --context=ANTAL       udskriv ANTAL linjer af omgivende tekst\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -739,7 +715,16 @@ msgstr ""
 "                            der (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"'egrep' betyder 'grep -E'.  'fgrep' betyder 'grep -F'.\n"
+"Direkte kørsel som enten 'egrep' eller 'fgrep' er forældet.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -753,48 +738,38 @@ msgstr ""
 "Afslutningsstatus er 0 hvis mindst én linje blev valgt, ellers 1; hvis der\n"
 "opstår nogen fejl, og -q ikke blev givet, er afslutningsstatus 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Hjemmeside for GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s kan kun bruge %s-mønstersyntaksen"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "modstridende søgeudtryk angivet"
 
 # en 'matcher' er tydeligvis et substantiv her... mystisk
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ugyldig matcher %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "ukendt enhedsmetode"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ugyldig angivelse af maksimum"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "ukendt binær filtype"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "tilvalget --mmap har været no-op siden 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -802,42 +777,60 @@ msgstr ""
 "understøttelse for flaget -P er ikke kompileret ind i denne binærfil for --"
 "disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "flaget -P understøtter kun et enkelt mønster"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "intern fejl"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "overskred maksimal linjelængde for PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "overskred tilbagerækkevidde for PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "intern fejl"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MØNSTER er et udvidet regulært udtryk (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Kørsel som 'egrep' er forældet; brug 'grep -E' i stedet.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "MØNSTER er en mængde faste strenge adskilt af linjeskift.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Kørsel som 'fgrep' er forældet; brug 'grep -F' i stedet.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s kan kun bruge %s-mønstersyntaksen"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "tilvalget --mmap har været no-op siden 2010"
index 7493440..fe579ea 100644 (file)
Binary files a/po/de.gmo and b/po/de.gmo differ
index 25fe55e..10d8491 100644 (file)
--- a/po/de.po
+++ b/po/de.po
@@ -2,19 +2,21 @@
 # Copyright © 1997-99, 2000, 2001, 2002 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 # Martin von Löwis <martin@mira.isdn.cs.tu-berlin.de>, 1997-99, 2000, 2001, 2002
-# Philipp Thomas <pth@suse.de>, 2012. 2013
+# Philipp Thomas <pth@suse.de>, 2012, 2013.
+# Mario Blättermann <mario.blaettermann@gmail.com>, 2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.14.46\n"
+"Project-Id-Version: GNU grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-10-21 14:01+0200\n"
-"Last-Translator: Philipp Thomas <pth@suse.de>\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-16 11:33+0100\n"
+"Last-Translator: Mario Blättermann <mario.blaettermann@gmail.com>\n"
 "Language-Team: German <translation-team-de@lists.sourceforge.net>\n"
 "Language: de\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
+"X-Generator: Poedit 1.5.4\n"
 
 #: lib/argmatch.c:133
 #, c-format
@@ -30,7 +32,7 @@ msgstr "mehrdeutiges Argument %s für %s"
 msgid "Valid arguments are:"
 msgstr "Gültige Argumente sind:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "Schreibfehler"
@@ -94,8 +96,8 @@ msgstr "%s: Option „-W %s“ erlaubt kein Argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: Option „-W %s“ erfordert ein Argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "Speicher ausgeschöpft"
@@ -103,7 +105,7 @@ msgstr "Speicher ausgeschöpft"
 #: lib/openat-die.c:38
 #, c-format
 msgid "unable to record current working directory"
-msgstr "das aktuelles Verzeichnisses kann nicht aufgezeichnet werden"
+msgstr "das aktuelle Verzeichnis kann nicht aufgezeichnet werden"
 
 #: lib/openat-die.c:57
 #, c-format
@@ -179,7 +181,7 @@ msgstr "Kein Gegenstück für ( oder \\("
 msgid "Unmatched \\{"
 msgstr "Kein Gegenstück für \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Ungültiger Inhalt von \\{\\}"
 
@@ -199,7 +201,7 @@ msgstr "Ungültiger vorhergehender regulärer Ausdruck"
 msgid "Premature end of regular expression"
 msgstr "Vorzeitiges Ende des regulären Ausdrucks"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Der reguläre Ausdruck ist zu groß"
 
@@ -238,10 +240,10 @@ msgid ""
 "\n"
 msgstr ""
 "\n"
-"Lizenz GPLv3+: GNU GPL Version 3 oder höher <http://gnu.org/licenses/gpl."
+"Lizenz GPLv3+: GNU GPL Version 3 oder neer <http://gnu.org/licenses/gpl."
 "html>\n"
 "Dies ist freie Software: Sie können sie ändern und weitergeben.\n"
-"Es gibt keinerlei Garantien, soweit wie es das Gesetz erlaubt.\n"
+"Es gibt keinerlei Garantien, soweit gesetzlich zulässig.\n"
 "\n"
 
 #. TRANSLATORS: %s denotes an author name.
@@ -356,7 +358,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -382,7 +384,7 @@ msgstr "%s Homepage: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Homepage für %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Allgemeine Hilfe zur Benutzung von GNU-Software: <http://www.gnu.org/gethelp/"
@@ -391,143 +393,116 @@ msgstr ""
 #: lib/xstrtol-error.c:63
 #, c-format
 msgid "invalid %s%s argument '%s'"
-msgstr "ungültiges %s%s Argument „%s“"
+msgstr "ungültiges %s%s-Argument „%s“"
 
 #: lib/xstrtol-error.c:68
 #, c-format
 msgid "invalid suffix in %s%s argument '%s'"
-msgstr "ungültiger Suffix in %s%s Argument „%s“"
+msgstr "ungültiger Suffix in %s%s-Argument „%s“"
 
 #: lib/xstrtol-error.c:72
 #, c-format
 msgid "%s%s argument '%s' too large"
-msgstr "%s%s Argument „%s“ ist zu groß"
+msgstr "%s%s-Argument „%s“ ist zu groß"
 
 # Is this message used only for [ without matching ],
 # or for ] without [ as well?
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ ohne schließendes Gegenstück."
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "Ungültige Zeichenklasse %s"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "die Syntax für Zeichenklassen ist [[:space:]], nicht [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "unbeendete \\-Escape-Sequenz."
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( ohne schließendes Gegenstück."
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "es wurde keine Syntax angegeben"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "Schließende ) ohne öffnendes Gegenstück"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MUSTER ist ein erweiterter regulärer Ausdruck (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Der Aufruf als „egrep“ ist überholt, verwenden Sie statt dessen „grep -E“.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"MUSTER ist ein Satz von Zeichenketten fester Länge getrennt durch "
-"Zeilenumbruch.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Der Aufruf als „fgrep“ ist überholt, verwenden Sie statt dessen „grep -F“.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MUSTER ist normalerweise ein regulärer Standardausdruck (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep“ bedeutet „grep -E“ und „fgrep“ bedautet „grep -F“.\n"
-"Der direkte Aufruf als entweder „egrep“ oder „fgrep“ ist veraltet.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "für weitere siehe <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ungültiges Argument für die Kontextlänge"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek ist fehlgeschlagen"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
-msgstr "die Eingabe ist zu groß um gezählt zu werden"
+msgstr "die Eingabe ist zu groß, um gezählt zu werden"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Übereinstimmungen in Binärdatei %s.\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "Warnung: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursive Verzeichnisschleife"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "die Eingabedatei %s ist auch die Ausgabedatei"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(Standardeingabe)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Aufruf: %s [OPTION]... MUSTER [DATEI]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "„%s --help“ liefert weitere Informationen.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Suche nach MUSTER in jeder DATEI oder der Standardeingabe.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MUSTER ist normalerweise ein regulärer Standardausdruck (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -538,7 +513,7 @@ msgstr ""
 "\n"
 "Auswahl und Interpretation regulärer Ausdrücke:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -548,13 +523,13 @@ msgid ""
 "  -P, --perl-regexp         PATTERN is a Perl regular expression\n"
 msgstr ""
 "  -E, --extended-regexp     MUSTER ist ein erweiterter regulärer Ausdruck.\n"
-"  -F, --fixed-strings       MUSTER ist eine Menge durch Zeilenubruch\n"
+"  -F, --fixed-strings       MUSTER ist eine Menge durch Zeilenumbruch\n"
 "                            getrennter Zeichenketten.\n"
 "  -G, --basic-regexp        MUSTER ist ein regulärer Standardausdruck.\n"
 "  -P, --perl-regexp         MUSTER ist ein regulärer Ausdruck, \n"
 "                            wie Perl ihn akzeptiert.\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -568,31 +543,28 @@ msgstr ""
 "  -f, --file=FILE           MUSTER aus DATEI lesen.\n"
 "  -i, --ignore-case         Unterschied zwischen Groß- und Kleinschreibung\n"
 "                            ignorieren.\n"
-"  -w, --word-regexp         MUSTER paßt nur auf ganze Wörter.\n"
-"  -x, --line-regexp         MUSTER paßt nur auf ganze Zeilen.\n"
+"  -w, --word-regexp         MUSTER passt nur auf ganze Wörter.\n"
+"  -x, --line-regexp         MUSTER passt nur auf ganze Zeilen.\n"
 "  -z, --null-data           Eine Zeile endet mit Nullbyte, nicht Newline.\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Verschiedenes:\n"
 "  -s, --no-messages         Fehlermeldungen unterdrücken.\n"
-"  -v, --revert-match        Nicht-passende Zeilen anzeigen.\n"
+"  -v, --invert-match        Nicht-passende Zeilen anzeigen.\n"
 "  -V, --version             Versionsnummer ausgeben und beenden.\n"
 "      --help                Diese Hilfe ausgeben und beenden.\n"
-"      --mmap                Wenn möglich, Eingabe in den Speicher "
-"einblenden.\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -608,19 +580,19 @@ msgid ""
 msgstr ""
 "\n"
 "Kontrolle der Ausgabe:\n"
-"  -m, --max-count=ZAHL      stoppt nach ZAHL Übereinstimmungen\n"
+"  -m, --max-count=ANZAHL    stoppt nach ANZAHL Übereinstimmungen\n"
 "  -b, --byte-offset         gibt mit den Zeilen auch den Abstand in Bytes "
 "an\n"
 "  -n, --line-number         gibt mit den Zeilen auch die Zeilennummer an\n"
-"      --line-buffered       Puffer nach jeder Zeile leeren\n"
-"  -H, --with-filename       den Dateinamen für jede Übereinstimmung "
-"ausgeben\n"
-"  -h, --no-filename         Ausgabe des vorangehenden Dateinamens "
-"unterdrücken\n"
-"      --label=BEZEICHNUNG   Verwendet BEZEICHNUNG als Präfix für Dateianmen\n"
+"      --line-buffered       leert den Puffer nach jeder Zeile\n"
+"  -H, --with-filename       gibt den Dateinamen für jede Übereinstimmung "
+"aus\n"
+"  -h, --no-filename         unterdrückt die Ausgabe des vorangehenden "
+"Dateinamens\n"
+"      --label=BEZEICHNUNG   verwendet BEZEICHNUNG als Präfix für Dateinamen\n"
 "                            der Standardeingabe\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -631,13 +603,13 @@ msgid ""
 msgstr ""
 "  -o, --only-matching       zeigt nur den Teil einer Zeile, der zu MUSTER "
 "passt\n"
-"  -q, --quiet, --silent     unterdrüjckt alle normalen Ausgaben\n"
+"  -q, --quiet, --silent     unterdrückt alle normalen Ausgaben\n"
 "      --binary-files=TYP    alle binären Dateien sind vom Typ TYP;\n"
-"                            TYP können „binary“, „text“, oder „without-"
-"match“ sein\n"
+"                            TYP kann „binary“, „text“ oder „without-match“ "
+"sein\n"
 "  -a, --text                gleichbedeutend mit --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -650,15 +622,15 @@ msgid ""
 msgstr ""
 "  -I                        gleichbedeutend mit --binary-files=without-"
 "match\n"
-"  -d, --directories=AKTION  beschreibt wie Verzeichnisse zu behandeln sind;\n"
-"                            AKTION können „read“, „recurse“, oder „skip“ "
-"sein\n"
+"  -d, --directories=AKTION  beschreibt, wie Verzeichnisse zu behandeln "
+"sind;\n"
+"                            AKTION kann „read“, „recurse“ oder „skip“ sein\n"
 "  -D, --devices=AKTION      Behandlung von Geräten, FIFOs oder Sockets;\n"
-"                            AKTION können „read“ oder „skip“ sein\n"
-"  -r, --recursive           like --directories=recurse\n"
-"  -R, --dereference-recursive  likewise, but follow all symlinks\n"
+"                            AKTION kann „read“ oder „skip“ sein\n"
+"  -r, --recursive           wie --directories=recurse\n"
+"  -R, --dereference-recursive  ebenso, folgt aber allen symbolischen Links\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -668,16 +640,16 @@ msgid ""
 "      --exclude-dir=PATTERN  directories that match PATTERN will be "
 "skipped.\n"
 msgstr ""
-"      --include=DATEI_MUSTER  durchsucht nur Dateien, die DATEI_MUSTER "
+"      --include=DATEIMUSTER  durchsucht nur Dateien, die DATEIMUSTER "
 "entsprechen\n"
-"      --exclude=DATEI_MUSTER  überspringt Dateien und Verzeichnisse, die \n"
-"DATEI_MUSTER entsprechen\n"
+"      --exclude=DATEIMUSTER  überspringt Dateien und Verzeichnisse, die \n"
+"                              DATEIMUSTER entsprechen\n"
 "      --exclude-from=DATEI   überspringt Dateien, die einem Dateimuster\n"
-"                             in DATEI entsprechen\n"
-"      --exclude-dir=MUSTER   Verzeichnisse, die MUSTER entsprechen werden "
+"                              in DATEI entsprechen\n"
+"      --exclude-dir=MUSTER   Verzeichnisse, die MUSTER entsprechen, werden "
 "übersprungen\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -692,10 +664,10 @@ msgstr ""
 "                            ausgeben\n"
 "  -c, --count               nur die Anzahl der passenden Zeilen pro DATEI\n"
 "                            ausgeben\n"
-"  -T, --initial-tab         Tabulatoren (wenn nötig) ausrichen\n"
-"  -Z, --null                ein Nullbyte nach einem Dateinamen ausgeben\n"
+"  -T, --initial-tab         Tabulatoren (wenn nötig) ausrichten\n"
+"  -Z, --null                ein 0-Byte nach einem Dateinamen ausgeben\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -706,13 +678,13 @@ msgid ""
 msgstr ""
 "\n"
 "Kontextkontrolle:\n"
-"  -B, --before-context=ANZAHL  ANZAHL Zeilen vorausghenden Kontextes "
+"  -B, --before-context=ANZAHL  ANZAHL Zeilen vorausgehenden Kontextes "
 "ausgeben\n"
 "  -A, --after-context=ANZAHL   ANZAHL Zeilen nachfolgenden Kontextes "
 "ausgeben\n"
 "  -C, --context=ANZAHL         ANZAHL Zeilen Kontext ausgeben\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -734,7 +706,16 @@ msgstr ""
 "(MSDOS).\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep“ bedeutet „grep -E“ und „fgrep“ bedeutet „grep -F“.\n"
+"Der direkte Aufruf als entweder „egrep“ oder „fgrep“ ist veraltet.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -744,94 +725,110 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 "Wenn DATEI - ist, wird die Standardeingabe gelesen.  Ohne DATEI wird „.“\n"
-"gelesen, wenn -r auf der Kommandozeile angegeben wurde, ansonsten -\n"
-"Wenn weniger als zwei FIFOs angegeben wurdenm wird -h angenommen.\n"
-"Der Rückgabewert ist 0 wenn eine Zeile passte, ansonsten 1.\n"
-"Wenn ein Fehler auftrat und -q nicht angegeben wurde ist der Rückgabewert "
+"gelesen, wenn -r auf der Befehlszeile angegeben wurde, ansonsten -\n"
+"Wenn weniger als zwei FIFOs angegeben wurden, wird -h angenommen.\n"
+"Der Rückgabewert ist 0, wenn eine Zeile passte, ansonsten 1.\n"
+"Wenn ein Fehler auftrat und -q nicht angegeben wurde, ist der Rückgabewert "
 "2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep Homepage: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s kann nur die Mustersyntax von %s verwenden"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "die angegebenen Entsprechungen stehen in Konflikt zueinander"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ungültige Entsprechung %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "Unbekannte Methode für Gerätedateien"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ungültige Maximalanzahl"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "unbekannter Typ für Binärdateien"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "die Option --mmap wird seit 2010 ignoriert"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
-msgstr "Dieses Programm wurde ohne Unterstützung für die Option -P kompiliert"
+msgstr ""
+"Unterstützung für die Option -P wurde in dieses --disable-perl-regexp-Binary "
+"nicht einkompiliert"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Die Option -P unterstützt nur ein einzelnes Suchmuster"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "Interner Fehler (sollte nie vorkommen)"
 
-#: src/pcresearch.c:130
-#, fuzzy, c-format
+#: src/pcresearch.c:120
+#, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
-msgstr "es konnte kein Speicher für den JIT-Stack reserviert werden"
+msgstr "es konnte kein Speicher für den PCRE-JIT-Stack reserviert werden"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "interner Fehler"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "Überschreitung der zulässigen Zeilenlänge von PCREs"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "Überschreitung der Zurückverfolgungsbeschränkung des PCREs"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
-msgstr ""
+msgstr "unzulässige UTF-8-Bytesequenz in der Eingabe"
 
-#: src/pcresearch.c:206
-#, fuzzy, c-format
+#: src/pcresearch.c:192
+#, c-format
 msgid "internal PCRE error: %d"
-msgstr "interner Fehler"
+msgstr "interner PCRE-Fehler: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MUSTER ist ein erweiterter regulärer Ausdruck (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Der Aufruf als „egrep“ ist überholt, verwenden Sie statt dessen „grep -"
+#~ "E“.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "MUSTER ist ein Satz von Zeichenketten fester Länge getrennt durch "
+#~ "Zeilenumbruch.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Der Aufruf als „fgrep“ ist überholt, verwenden Sie statt dessen „grep -"
+#~ "F“.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s kann nur die Mustersyntax von %s verwenden"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "die Option --mmap wird seit 2010 ignoriert"
index 16d1567..7d1a6bc 100644 (file)
Binary files a/po/el.gmo and b/po/el.gmo differ
index cb45889..0945d81 100644 (file)
--- a/po/el.po
+++ b/po/el.po
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.11.11-pre1\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-05-05 23:23+0100\n"
 "Last-Translator: Savvas Radevic <vicedar@gmail.com>\n"
 "Language-Team: Greek <team@lists.gnome.gr>\n"
@@ -33,7 +33,7 @@ msgstr "διφορούμενη επιλογή %s για %s"
 msgid "Valid arguments are:"
 msgstr "Έγκυρες επιλογές είναι οι εξής:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "σφάλμα εγγραφής"
@@ -123,8 +123,8 @@ msgstr "%s: η επιλογή «%s» απαιτεί όρισμα\n"
 # src/kwset.c:190
 # src/grep.c:164 src/grep.c:181 src/grep.c:283 src/grep.c:338 src/kwset.c:184
 # src/kwset.c:190
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "η μνήμη εξαντλήθηκε"
@@ -208,7 +208,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -230,7 +230,7 @@ msgstr "Άκυρη προηγούμενης κανονικής έκφρασης"
 msgid "Premature end of regular expression"
 msgstr "Πρόωρο τέλος της κανονικής έκφρασης"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Υπερβολικά μεγάλη η κανονική έκφραση"
 
@@ -388,7 +388,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -412,7 +412,7 @@ msgstr "%s κεντρική σελίδα: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s κεντρική σελίδα: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Γενική βοήθεια χρήσης λογισμικού GNU: <http://www.gnu.org/gethelp/>\n"
 
@@ -435,84 +435,55 @@ msgstr "η %s%s επιλογή «%s» είναι υπερβολικά μεγάλ
 # src/dfa.c:690 src/dfa.c:703 src/dfa.c:704
 # src/dfa.c:660 src/dfa.c:663 src/dfa.c:690 src/dfa.c:694 src/dfa.c:695
 # src/dfa.c:698 src/dfa.c:711 src/dfa.c:712
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Μη ισορροπημένο ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "άκυρη κατηγορία χαρακτήρων"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "η σύνταξη κατηγορίας χαρακτήρων είναι [[:space:]], όχι [:space:]"
 
 # src/dfa.c:444
 # src/dfa.c:452
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Μη τερματισμένος χαρακτήρας διαφυγής \\"
 
 # src/dfa.c:841
 # src/dfa.c:849
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Μη ισορροπημένο ("
 
 # src/dfa.c:962
 # src/dfa.c:970
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Δεν ορίστηκε συντακτικό"
 
 # src/dfa.c:970
 # src/dfa.c:978
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Μη ισορροπημένο )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "Το ΠΡΟΤΥΠΟ είναι μια εκτεταμένη κανονική έκφραση (ΕΚΕ).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Η επίκληση ως «egrep» έχει καταργηθεί· χρησιμοποιήστε το «grep -E».\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Η επίκληση ως «fgrep» έχει καταργηθεί· χρησιμοποιήστε το «grep -F».\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"To «egrep» είναι ισοδύναμο του «grep -E». Το «fgrep» είναι ισοδύναμο του\n"
-"«grep -F».\n"
-"Η άμεση επίκληση ως «egrep» ή «fgrep» έχει καταργηθεί.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 "άλλοι, κοιτάξτε τον σύνδεσμο <http://git.sv.gnu.org/cgit/grep.git/tree/"
@@ -520,68 +491,73 @@ msgstr ""
 
 # src/grep.c:785 src/grep.c:792
 # src/grep.c:1060 src/grep.c:1067 src/grep.c:1076
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "μη έγκυρο όρισμα μήκους περιεχομένου"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "αποτυχία του lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "η είσοδος είναι πολύ μεγάλη για να μετρηθεί"
 
 # src/grep.c:715
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Το δυαδικό αρχείο %s ταιριάζει\n"
 
 # src/grep.c:293
 # src/grep.c:366
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "προειδοποίηση: %s: %s\n"
 
 # src/grep.c:844
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "αναδρομική αλληλοδιαδοχή καταλόγων"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "το αρχείο εισαγωγής %s είναι επίσης το αρχείο εξόδου"
 
 # src/grep.c:964 src/grep.c:1015
 # src/grep.c:730
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(κανονική είσοδος)"
 
 # src/grep.c:597
 # src/grep.c:862
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Χρήση: %s [ΕΠΙΛΟΓΗ]... ΥΠΟΔΕΙΓΜΑ [ΑΡΧΕΙΟ]...\n"
 
 # src/grep.c:598
 # src/grep.c:863
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Δοκιμάστε «%s --help» για περισσότερες πληροφορίες.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -593,7 +569,7 @@ msgstr ""
 "\n"
 "Επιλογή κανονικής έκφρασης και ερμηνεία:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -610,7 +586,7 @@ msgstr ""
 
 # src/grep.c:603
 # src/grep.c:868
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -632,16 +608,15 @@ msgstr ""
 
 # src/grep.c:615
 # src/grep.c:880
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Λοιπά:\n"
@@ -652,7 +627,7 @@ msgstr ""
 "      --mmap                χρήση εισόδου απεικονισμένη-στη-μνήμη αν\n"
 "                              υπάρχει τέτοια δυνατότητα\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -667,7 +642,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -677,7 +652,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -689,7 +664,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -700,7 +675,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -710,7 +685,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -730,7 +705,7 @@ msgstr ""
 
 # src/grep.c:633
 # src/grep.c:902
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -753,7 +728,17 @@ msgstr ""
 "                              χαρακτήρες CR (MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"To «egrep» είναι ισοδύναμο του «grep -E». Το «fgrep» είναι ισοδύναμο του\n"
+"«grep -F».\n"
+"Η άμεση επίκληση ως «egrep» ή «fgrep» έχει καταργηθεί.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -767,54 +752,44 @@ msgstr ""
 "δοθεί η επιλογή -h.  Η κατάσταση εξόδου του προγράμματος είναι 0 αν βρέθηκε\n"
 "το ΥΠΟΔΕΙΓΜΑ, 1 αν δεν βρέθηκε και 2 αν προέκυψε κάποιο πρόβλημα.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
 # src/grep.c:829
 # src/grep.c:1112
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "ορίστηκαν αντικρουόμενα στοιχεία αναζήτησης"
 
 # src/dfa.c:556 src/dfa.c:562 src/dfa.c:573 src/dfa.c:584
 # src/dfa.c:564 src/dfa.c:570 src/dfa.c:581 src/dfa.c:592
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "μη έγκυρος μέγιστος μετρητής"
 
 # src/grep.c:1133
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "άγνωστη μέθοδος συσκευών"
 
 # src/dfa.c:556 src/dfa.c:562 src/dfa.c:573 src/dfa.c:584
 # src/dfa.c:564 src/dfa.c:570 src/dfa.c:581 src/dfa.c:592
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "μη έγκυρος μέγιστος μετρητής"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "άγνωστο είδος δυαδικών αρχείων"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "η επιλογή --mmap δεν λειτουργεί από το 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -822,42 +797,56 @@ msgstr ""
 "η υποστήριξη για την επιλογή -P δεν είναι μεταγλωττισμένη σε αυτό το --"
 "disable-perl-regexp δυαδικό [αρχείο]"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Η επιλογή -P υποστηρίζει μόνο ένα υπόδειγμα"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "εσωτερικό σφάλμα"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "εσωτερικό σφάλμα"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "Το ΠΡΟΤΥΠΟ είναι μια εκτεταμένη κανονική έκφραση (ΕΚΕ).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Η επίκληση ως «egrep» έχει καταργηθεί· χρησιμοποιήστε το «grep -E».\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Η επίκληση ως «fgrep» έχει καταργηθεί· χρησιμοποιήστε το «grep -F».\n"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "η επιλογή --mmap δεν λειτουργεί από το 2010"
index 8ff36e8..48007c8 100644 (file)
Binary files a/po/eo.gmo and b/po/eo.gmo differ
index e85df7f..3bbef5b 100644 (file)
--- a/po/eo.po
+++ b/po/eo.po
@@ -1,18 +1,18 @@
 # Esperanto translations for GNU grep.
-# Copyright (C) 2013 Free Software Foundation, Inc.
+# Copyright (C) 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 #
 # "Wat is hier aan te doen?  Niets."
 #
 # D. Dale Gulledge <dsplat@rochester.rr.com>, 1999.
 # Edmund GRIMLEY EVANS <edmundo@rano.org>, 2000-2009.
-# Benno Schulenberg <benno@vertaalt.nl>, 2013.
+# Benno Schulenberg <benno@vertaalt.nl>, 2013, 2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.15.15\n"
+"Project-Id-Version: GNU grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 11:08+0100\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 21:18+0100\n"
 "Last-Translator: Benno Schulenberg <benno@vertaalt.nl>\n"
 "Language-Team: Esperanto <translation-team-eo@lists.sourceforge.net>\n"
 "Language: eo\n"
@@ -36,7 +36,7 @@ msgstr "plursenca argumento %s por %s"
 msgid "Valid arguments are:"
 msgstr "Validaj argumentoj estas:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "skrib-eraro"
@@ -100,8 +100,8 @@ msgstr "%s: opcio «-W %s» ne toleras argumenton\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opcio «-W %s» bezonas argumenton\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "mankas sufiĉa memoro"
@@ -185,7 +185,7 @@ msgstr "Senpara ( aŭ \\("
 msgid "Unmatched \\{"
 msgstr "Senpara \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Nevalida enhavo de \\{\\}"
 
@@ -205,7 +205,7 @@ msgstr "Nevalida antaŭa regulesprimo"
 msgid "Premature end of regular expression"
 msgstr "Neatendita fino de regulesprimo"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regulesprimo tro grandas"
 
@@ -362,7 +362,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -387,7 +387,7 @@ msgstr "Hejmpaĝo de «%s»: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Hejmpaĝo de «%s»: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Ĝenerala helpo por uzi GNU-programojn: <http://www.gnu.org/gethelp/>\n"
 
@@ -406,125 +406,102 @@ msgstr "nevalida sufikso en argumento de %s%s: «%s»"
 msgid "%s%s argument '%s' too large"
 msgstr "argumento de %s%s tro grandas: «%s»"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "senpara ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "nevalida signoklaso"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "sintakso de signoklaso estas ekzemple [[:spaco:]], ne [:spaco:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "nefinita \\-eskapo"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "senpara ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "neniu sintakso indikatas"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "senpara )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ŜABLONO estas etendita regulesprimo (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Alvoko kiel 'egrep' malrekomendatas; uzu 'grep -E' anstataŭe.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "ŜABLONO estas aro da fiksitaj signoĉenoj en apartaj linioj.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Alvoko kiel 'fgrep' malrekomendatas; uzu 'grep -F' anstataŭe.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "ŜABLONO defaŭlte estas baza regulesprimo (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Rekta alvoko kiel aŭ 'egrep' aŭ 'fgrep' malrekomendatas;\n"
-"'egrep' signifas 'grep -E; 'fgrep' signifas 'grep -F'.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Majk HERTEL (Mike Haertel)"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "aliuloj, vidu <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "nevalida kuntekstlongeca argumento"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "malsukcesis 'lseek'"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "enigo tro longas por nombri"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Duuma dosiero %s kongruas\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "averto: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rikura ciklo de dosierujoj"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "eniga dosiero %s estas ankaŭ la eliga dosiero; ĝi ignoriĝas"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(ĉefenigujo)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Uzmaniero:  %s [OPCIO...] ŜABLONO [DOSIERO...]\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Tajpu '%s --help' por pli da informoj.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Serĉas ŜABLONOn en ĉiu DOSIERO aŭ en ĉefenigujo.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "ŜABLONO defaŭlte estas baza regulesprimo (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -535,7 +512,7 @@ msgstr ""
 "\n"
 "Elekto kaj interpreto de regulesprimoj:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -550,7 +527,7 @@ msgstr ""
 "  -G, --basic-regexp        ŜABLONO estas baza regulesprimo (BRE)\n"
 "  -P, --perl-regexp         ŜABLONO estas regulesprimo de Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -568,16 +545,15 @@ msgstr ""
 "  -z, --null-data           datenlinio finiĝas per bitoko 0, ne per "
 "linifino\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diversaj:\n"
@@ -585,9 +561,8 @@ msgstr ""
 "  -v, --invert-match        elekti la nekongruajn liniojn\n"
 "  -V, --version             montri programversion kaj eliri\n"
 "      --help                montri ĉi tiun helpon kaj eliri\n"
-"      --mmap                (jam faras nenion; venigas nur averton)\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -611,7 +586,7 @@ msgstr ""
 "  -h, --no-filename         subpremi la prefiksan dosiernomon ĉe eligo\n"
 "      --label=ETIKEDO       uzi ETIKEDOn kiel dosiernomon de ĉefenigujo\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -629,7 +604,7 @@ msgstr ""
 "                              aŭ 'without-match' (sen-trafa)\n"
 "  -a, --text                egalas al «--binary-files=text»\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -648,7 +623,7 @@ msgstr ""
 "                              AGO estus 'read' (legi), aŭ 'skip' (ignori)\n"
 "  -R, -r, --recursive       egalas al «--directories=recurse»\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -665,7 +640,7 @@ msgstr ""
 "DSRO\n"
 "      --exclude-dir=ŜABLONO ignori dosierujojn kiuj kongruas kun ŜABLONO\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -681,7 +656,7 @@ msgstr ""
 "  -T, --initial-tab         rektigi la TAB-signojn (se necesas)\n"
 "  -Z, --null                montri la bitokon «0» post dosiernomo\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -696,7 +671,7 @@ msgstr ""
 "  -A, --after-context=NOM   montri NOM liniojn da posta kunteksto\n"
 "  -C, --context=NOMBRO      egalas al «-A NOMBRO -B NOMBRO»\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -719,7 +694,16 @@ msgstr ""
 "(MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Rekta alvoko kiel aŭ 'egrep' aŭ 'fgrep' malrekomendatas;\n"
+"'egrep' signifas 'grep -E; 'fgrep' signifas 'grep -F'.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -734,47 +718,37 @@ msgstr ""
 "Elirstato estas 0 se iu linio elektiĝis, alie 1;\n"
 "elirstato estas 2 se iu eraro okazis kaj «-q» ne indikatis.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Hejmpaĝo de GNU «grep»: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s nur povas uzi sintakson de %s-ŝablono"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "pluraj esprimtipoj indikatas"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "nevalida esprimtipo %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "nekonata ago por aparatoj"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "nevalida maksimuma nombro"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "nekonata ago por duumaj dosieroj"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "la opcio «--mmap» faras nenion, jam ekde 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -782,46 +756,64 @@ msgstr ""
 "opcio «-P» ne funkcias en ĉi tiu programo ĉar ĝi kompiliĝis kun «--disable-"
 "perl-regexp»"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "opcio «-P» akceptas nur unuopan ŝablonon"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "**interna eraro** (devus neniam okazi)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "mankas sufiĉa memoro por la PCRE-JIT-stako"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "**interna eraro**"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "transpasiĝis linilongecan limon de PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "transpasiĝis retroreferencan limon de PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "nevalida UTF-8-a bajtsekvenco en enigo"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "**interna eraro** en PCRE: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ŜABLONO estas etendita regulesprimo (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Alvoko kiel 'egrep' malrekomendatas; uzu 'grep -E' anstataŭe.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "ŜABLONO estas aro da fiksitaj signoĉenoj en apartaj linioj.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Alvoko kiel 'fgrep' malrekomendatas; uzu 'grep -F' anstataŭe.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s nur povas uzi sintakson de %s-ŝablono"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "la opcio «--mmap» faras nenion, jam ekde 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "nefinita ripetonombro"
 
index eddf4e7..8c68497 100644 (file)
Binary files a/po/es.gmo and b/po/es.gmo differ
index 3066c3d..f45c45f 100644 (file)
--- a/po/es.po
+++ b/po/es.po
@@ -1,15 +1,15 @@
 # Mensajes en español para GNU grep.
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2010, 2011, 2013 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2010, 2011, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 # Enrique Melero Gómez <melero@eurolands.com>, 1996.
-# Santiago Vila Doncel <sanvila@unex.es>, 1997, 1998, 1999, 2000, 2001, 2002, 2010, 2011, 2013.
+# Santiago Vila Doncel <sanvila@unex.es>, 1997-2002, 2010, 2011, 2013, 2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.14\n"
+"Project-Id-Version: GNU grep 2.16.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-03-03 12:45+0100\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-02-24 00:06+0100\n"
 "Last-Translator: Santiago Vila Doncel <sanvila@unex.es>\n"
 "Language-Team: Spanish <es@li.org>\n"
 "Language: es\n"
@@ -31,7 +31,7 @@ msgstr "argumento %s ambiguo para %s"
 msgid "Valid arguments are:"
 msgstr "Los argumentos válidos son:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "error de escritura"
@@ -95,8 +95,8 @@ msgstr "%s: la opción '-W %s' no admite ningún argumento\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: la opción '-W %s' requiere un argumento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memoria agotada"
@@ -180,7 +180,7 @@ msgstr "( o \\( desemparejado"
 msgid "Unmatched \\{"
 msgstr "\\{ desemparejado"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Contenido inválido de \\{\\}"
 
@@ -200,7 +200,7 @@ msgstr "La expresión regular precedente es inválida"
 msgid "Premature end of regular expression"
 msgstr "Final prematuro de la expresión regular"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "La expresión regular es demasiado grande"
 
@@ -356,7 +356,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -380,7 +380,7 @@ msgstr "Página inicial de %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "página inicial de %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Ayuda general sobre el uso de software de GNU: <http://www.gnu.org/gethelp/"
@@ -401,127 +401,102 @@ msgstr "sufijo inválido en el argumento %s%s '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s argumento '%s' demasiado grande"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ desemparejado"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "clase de caracteres inválida"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "la sintaxis de la clase de caracteres es [[:space:]], no [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "secuencia de escape \\ sin terminar"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( desemparejado"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "no se ha especificado ninguna sintaxis"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") desemparejado"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATRÓN es una expresión regular extendida (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"La invocación como 'egrep' está obsoleta; utilice 'grep -E' en su lugar.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATRÓN es un conjunto de cadenas fijas separadas por nueva línea\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"La invocación como 'fgrep' está obsoleta; utilice 'grep -F' en su lugar.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATRÓN es, por omisión, una expresión regular básica (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"'egrep' significa 'grep -E'.  'fgrep' significa 'grep -F'.\n"
-"La invocación directa como 'egrep' o 'fgrep' está obsoleta.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "otros, véase <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "longitud de contexto inválida"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "falló la llamada al sistema `lskeek'"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "la entrada es demasiado grande para contar"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Coincidencia en el fichero binario %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "atención: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "bucle de directorio recursivo"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "el fichero de entrada %s también es el de salida"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(entrada estándar)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Modo de empleo: %s [OPCIÓN]... PATRÓN [FICHERO]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Pruebe '%s --help' para más información.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Busca PATRÓN en cada FICHERO o en la entrada estándar.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATRÓN es, por omisión, una expresión regular básica (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -532,7 +507,7 @@ msgstr ""
 "\n"
 "Selección e interpretación de Expreg:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -547,7 +522,7 @@ msgstr ""
 "  -G, --basic-regexp        PATRÓN es una expresión regular básica (BRE)\n"
 "  -P, --perl-regexp         PATRÓN es una expresión regular en Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -567,16 +542,16 @@ msgstr ""
 "  -z, --null-data           una línea de datos termina en un byte 0, no\n"
 "                            en un carácter de nueva línea\n"
 
-#: src/main.c:1568
-#, c-format
+# FIXME: La "n" del final tiene que ser un error.
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Variadas:\n"
@@ -584,9 +559,9 @@ msgstr ""
 "  -v, --invert-match        selecciona las líneas que no coinciden\n"
 "  -V, --version             muestra la versión y finaliza\n"
 "      --help                muestra esta ayuda y finaliza\n"
-"      --mmap                no hace nada y está obsoleta; da un aviso\n"
+"n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -616,7 +591,7 @@ msgstr ""
 "      --label=ETIQUETA      utiliza ETIQUETA como nombre de fichero prefijo\n"
 "                            para la entrada estándar\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -632,7 +607,7 @@ msgstr ""
 "                            TIPO es 'binary', 'text', o 'without-match'\n"
 "  -a, --text                equivalente a --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -652,7 +627,7 @@ msgstr ""
 "  -R, --dereference-recursive  similar, pero sigue todos los enlaces "
 "simbólicos\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -669,7 +644,7 @@ msgstr ""
 "                             de FICHERO\n"
 "      --exclude-dir=PATRÓN  se salta los directorios que encajan con PATRÓN\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -688,7 +663,7 @@ msgstr ""
 "  -Z, --null                imprime un byte 0 después del nombre del "
 "FICHERO\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -703,7 +678,7 @@ msgstr ""
 "  -A, --after-context=NÚM   muestra NÚM líneas de contexto posterior\n"
 "  -C, --context=NÚM         muestra NÚM líneas de contexto\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -725,7 +700,16 @@ msgstr ""
 "  -u, --unix-byte-offsets   cuenta los desplazamientos como si no hubiera\n"
 "                            retornos de carro (MSDOS/Windows)\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"'egrep' significa 'grep -E'.  'fgrep' significa 'grep -F'.\n"
+"La invocación directa como 'egrep' o 'fgrep' está obsoleta.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -740,16 +724,11 @@ msgstr ""
 "estado de salida es 0 si hay coincidencias, 1 si no las hay; si ocurre\n"
 "algún error y no se especificó -q, el estado de salida es 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Página inicial de GNU grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s solamente puede usar la sintaxis de patrón %s"
-
 #  viendo los fuentes , hay varias opciones
 #  que hay sin documentar. O quizá es que getopt() lo he entendido mal
 #  Son las opciones X ( requiere argumento ) , switchs  -c, -b, -L e -y
@@ -761,37 +740,32 @@ msgstr "%s solamente puede usar la sintaxis de patrón %s"
 #
 # No me gusta nada lo de opción "a buscar".
 # Se admiten sugerencias. sv
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "se han especificado expresiones conflictivas"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "expresión inválida %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "método de dispositivos desconocido"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "contador máximo inválido"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipo binary-files desconocido"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "la opcion --mmap no hace nada desde 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -799,45 +773,65 @@ msgstr ""
 "el soporte para la opción -P no está compilado en este ejecutable --disable-"
 "perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "la opción -P solamente admite un patrón"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
-msgstr ""
+msgstr "error interno (no debería ocurrir nunca)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
-msgstr ""
+msgstr "fallo al asignar memoria para la pila JIT de PCRE"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "error interno"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "se ha excedido el límite de longitud de línea de las PCREs"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "se ha excedido el límite de vuelta atrás de las PCREs"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
-msgstr ""
+msgstr "secuencia de bytes UTF-8 inválida en la entrada"
 
-#: src/pcresearch.c:206
-#, fuzzy, c-format
+#: src/pcresearch.c:192
+#, c-format
 msgid "internal PCRE error: %d"
-msgstr "error interno"
+msgstr "error interno de PCRE: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATRÓN es una expresión regular extendida (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "La invocación como 'egrep' está obsoleta; utilice 'grep -E' en su lugar.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATRÓN es un conjunto de cadenas fijas separadas por nueva línea\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "La invocación como 'fgrep' está obsoleta; utilice 'grep -F' en su lugar.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s solamente puede usar la sintaxis de patrón %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "la opcion --mmap no hace nada desde 2010"
 
 #~ msgid "unfinished repeat count"
 #~ msgstr "contador de repetición sin terminar"
index b5828dd..b0c285e 100644 (file)
Binary files a/po/et.gmo and b/po/et.gmo differ
index 9e431f4..a698d13 100644 (file)
--- a/po/et.po
+++ b/po/et.po
@@ -1,14 +1,14 @@
 # This file is distributed under the same license as the grep package.
 # Estonian translations for grep
 # Copyright (C) 2000 Free Software Foundation, Inc.
-# Toomas Soome <tsoome@me.com>, 2013.
+# Toomas Soome <tsoome@me.com>, 2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: grep 2.15.15\n"
+"Project-Id-Version: grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 11:37+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 15:57+0300\n"
 "Last-Translator: Toomas Soome <tsoome@me.com>\n"
 "Language-Team: Estonian <linux-ee@lists.eenet.ee>\n"
 "Language: et\n"
@@ -30,7 +30,7 @@ msgstr "segane argument %s võtmele %s"
 msgid "Valid arguments are:"
 msgstr "Lubatud argumendid on:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "viga kirjutamisel"
@@ -94,8 +94,8 @@ msgstr "%s: võti '-W %s' ei luba argumenti\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: võti '-W %s' nõuab argumenti\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "mälu on otsas"
@@ -179,7 +179,7 @@ msgstr "Puudub ( või \\("
 msgid "Unmatched \\{"
 msgstr "Puudub \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Vigane \\{\\} sisu"
 
@@ -199,7 +199,7 @@ msgstr "Vigane eelnev regulaaravaldis"
 msgid "Premature end of regular expression"
 msgstr "Ootamatu reagulaaravaldise lõpp"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regulaaravaldis on liiga suur"
 
@@ -355,7 +355,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -379,7 +379,7 @@ msgstr "%s koduleht: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s koduleht: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Üldine abiinfo GNU tarkvara kohta: <http://www.gnu.org/gethelp/>\n"
 
@@ -398,125 +398,102 @@ msgstr "vigane sufiks %s%s argumendis '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s argument '%s' on liiga suur"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "balanseerimata ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "vigane sümboliklass"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "sümbolklassi süntaks on [[:space:]], mitte [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "lõpetamata \\ paojada"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "balanseerimata ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "süntaksit pole määratud"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "balanseerimata )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MUSTER on laiendatud regulaaravaldis (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Käsu 'egrep' kasutamine pole soovitatav; kasutage 'grep -E'.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "MUSTER on reavahetusega eraldatud sõnede hulk.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Käsu 'fgrep' kasutamine pole soovitatav; kasutage 'grep -F'.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MUSTER on vaikimisi lihtne regulaaravaldis (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"'egrep' tähendab 'grep -E'.  'fgrep' tähendab 'grep -F'.\n"
-"Otsene 'egrep' või 'fgrep' kasutamine pole soovitatav.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "teised, vaata <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "vigane konteksti pikkuse argument"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek ebaõnnestus"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "sisend on loendamiseks liiga suur"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Kahendfail %s sobib\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "hoiatus: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiivne kataloogipuu tsükkel"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "sisendfail %s on samuti väljund"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standardsisend)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Kasuta: %s [VÕTI]... MUSTER [FAIL] ...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Lisainfo saamiseks proovige võtit '%s --help'.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Otsib MUSTRIT igast FAIList või standardsisendist.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MUSTER on vaikimisi lihtne regulaaravaldis (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -527,7 +504,7 @@ msgstr ""
 "\n"
 "Regulaaravaldise valik ja interpreteerimine:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -541,7 +518,7 @@ msgstr ""
 "  -G, --basic-regexp        MUSTER on lihtne regulaaravaldis (BRE)\n"
 "  -P, --perl-regexp         MUSTER on Perl regulaaravaldis\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -558,16 +535,15 @@ msgstr ""
 "  -x, --line-regexp         kasuta MUSTRIT ridade leidmiseks\n"
 "  -z, --null-data           andmerida lõppeb baidil 0, mitte reavahetusel\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Muud:\n"
@@ -575,9 +551,9 @@ msgstr ""
 "  -v, --invert-match        vali mitte-sobivad read\n"
 "  -V, --version             esita versiooniinfo ja lõpeta töö\n"
 "      --help                esita see abiinfo ja lõpeta töö\n"
-"      --mmap                ignoreeritakse, annab hoiatuse\n"
+"\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -601,7 +577,7 @@ msgstr ""
 "  -h, --no-filename         blokeeri väljundis failinimi\n"
 "      --label=MÄRGEND       kasuta väljundis failinime asemel märgendit\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -616,7 +592,7 @@ msgstr ""
 "                            TÜÜP on 'binary', 'text', või 'without-match'\n"
 "  -a, --text                sama, kui --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -636,7 +612,7 @@ msgstr ""
 "  -r, --recursive           sama, kui --directories=recurse\n"
 "  -R                        sama, aga järgib kõiki nimeviiteid\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -653,7 +629,7 @@ msgstr ""
 "mustrile\n"
 "      --exclude-dir=MUSTER   välista mustrile vastavad kataloogid.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -669,7 +645,7 @@ msgstr ""
 "tabulaatorit\n"
 "  -Z, --null                väljasta faili nime järel bait 0\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -684,7 +660,7 @@ msgstr ""
 "  -A, --after-context=NUM   väljasta NUM rida järgnevat konteksti\n"
 "  -C, --context=NUM         väljasta NUM rida väljundi konteksti\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -707,7 +683,16 @@ msgstr ""
 "                            (MSDOS/WINDOWS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"'egrep' tähendab 'grep -E'.  'fgrep' tähendab 'grep -F'.\n"
+"Otsene 'egrep' või 'fgrep' kasutamine pole soovitatav.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -722,89 +707,79 @@ msgstr ""
 "Lõpetamise kood on 0, kui rida leiti, muidu 1;\n"
 "kui tekkis viga ja -q ei kasutatud, on lõpetamise kood 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep koduleht: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s saab kasutada ainult %s mustri süntaksit"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "määrati konfliktsed otsijad"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "vigane sobitaja %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "tundmatu seadmete meetod"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "vigane maksimum"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tundmatu kahendfailide tüüp"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "alates aastast 2010 ei tee võti --mmap midagi"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "võtme -P tuge ei ole kompileeritud sellesse --disable-perl-regexp koodi"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "võti -P toetab ainult ühte mustrit"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "sisemine viga (ei peaks kunagi juhtuma)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "PCRE JIT magasini jaoks ei jätku mälu"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "sisemine viga"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "PCRE rea pikkuse piirang on ületatud"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "PCRE tagasivaate piirang on ületatud"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "sisendis on vigane UTF-8 baidi järjend"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "sisemine PCRE viga: %d"
index e199782..36a3ac7 100644 (file)
Binary files a/po/eu.gmo and b/po/eu.gmo differ
index 3b5464a..b712385 100644 (file)
--- a/po/eu.po
+++ b/po/eu.po
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5.1a\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2005-03-03 21:40+0100\n"
 "Last-Translator: Mikel Olasagasti <hey_neken@mundurat.net>\n"
 "Language-Team: Basque <translation-team-eu@lists.sourceforge.net>\n"
@@ -32,7 +32,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -96,8 +96,8 @@ msgstr "%s: `-W %s' aukerak ez du argumenturik onartzen\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: `%s' aukerak argumentu bat behar du\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memoria agortuta"
@@ -181,7 +181,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -201,7 +201,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -335,7 +335,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -359,7 +359,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -378,128 +378,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Parekatu gabeko ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Amaitu gabeko \\ eskapea"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Parekatu gabeko ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Ez da sintaxirik zehaztu"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Parekatu gabeko )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "balio gabeko testuinguru luzeera argumentua"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "sarrera luzeegia da kontatzeko"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "%s fitxategi binarioa bat dator\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "abisua: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "direktorio bukle errekurtsiboa"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(sarrera estandarra)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Erabilera: %s [AUKERA]... EREDUA [FITXATEGIA]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Saiatu `%s --help' informazio gehiagorako.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -511,7 +490,7 @@ msgstr ""
 "\n"
 "Regexp aukera eta interpretazioa:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -526,7 +505,7 @@ msgstr ""
 "  -G, --basic-regexp        EREDUA oinarrizko espresio erregular bat da\n"
 "  -P, --perl-regexp         EREDUA Perl espresio erregular bat da\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -546,16 +525,15 @@ msgstr ""
 "  -z, --null-data           datu lerroa 0 byte-arekin amaitzen da, eta ez "
 "lerro berriarekin\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Hainbat:\n"
@@ -566,7 +544,7 @@ msgstr ""
 "      --mmap                erabili asignatutako memoria sarrera posible "
 "bada\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -581,7 +559,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -591,7 +569,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -603,7 +581,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -614,7 +592,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -624,7 +602,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -634,7 +612,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -669,7 +647,14 @@ msgstr ""
 "badator, 1 ez badator,\n"
 "eta 2 arazorik badago.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -679,88 +664,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "espresio konfliktiboak espezifikatu dira"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "baliogabeko gehienezko zenbaketa"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "gailu metodo ezezaguna"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "baliogabeko gehienezko zenbaketa"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "fitxategi-binario moeta ezezaguna"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P aukerak ez du euskarririk"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 7e29436..3773038 100644 (file)
Binary files a/po/fi.gmo and b/po/fi.gmo differ
index cb6ad45..15e6a58 100644 (file)
--- a/po/fi.po
+++ b/po/fi.po
@@ -1,15 +1,15 @@
 # Finnish translation for GNU grep.
-# Copyright © 2002, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+# Copyright © 2002, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 # Sami J. Laine <sami.laine@iki.fi>, 2002.
-# Jorma Karvonen <karvonen.jorma@gmail.com>, 2007-2013.
+# Jorma Karvonen <karvonen.jorma@gmail.com>, 2007-2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: grep 2.15.15\n"
+"Project-Id-Version: grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-26 11:57+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-12 00:25+0200\n"
 "Last-Translator: Jorma Karvonen <karvonen.jorma@gmail.com>\n"
 "Language-Team: Finnish <translation-team-fi@lists.sourceforge.net>\n"
 "Language: fi\n"
@@ -33,7 +33,7 @@ msgstr "monimerkityksellinen argumentti %s kohteelle %s"
 msgid "Valid arguments are:"
 msgstr "Kelvollisia argumentteja ovat:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "kirjoitusvirhe"
@@ -97,8 +97,8 @@ msgstr "%s: valitsin ’-W %s’ ei salli argumenttia\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: valitsin ’-W %s’ tarvitsee argumentin\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "muisti loppui"
@@ -182,7 +182,7 @@ msgstr "Pariton ( tai \\("
 msgid "Unmatched \\{"
 msgstr "Pariton \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Virheellinen kohteen \\{\\} sisältö"
 
@@ -202,7 +202,7 @@ msgstr "Virheellinen edeltävä säännöllinen lauseke"
 msgid "Premature end of regular expression"
 msgstr "Ennenaikainen säännöllisen lausekkeen loppu"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Säännöllinen lauseke on liian suuri"
 
@@ -358,7 +358,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -387,7 +387,7 @@ msgstr "%s kotisivu: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s kotisivu: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Yleinen opaste GNU-ohjelmiston käyttöön: <http://www.gnu.org/gethelp/>\n"
@@ -410,129 +410,102 @@ msgstr "virheellinen loppuliite valitsimen %s%s argumentissa ’%s’"
 msgid "%s%s argument '%s' too large"
 msgstr "valitsimen %s%s argumentti ’%s’ on liian iso"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "pariton ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "virheellinen merkkiluokkanimi"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "merkkiluokkasyntaksi on [[:välilyönti:]], ei [:välilyönti:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "päättymätön \\-ohjausmerkki"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "pariton ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "syntaksia ei ole määritelty"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "pariton )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "HAKULAUSEKE on laajennettu säännöllinen lauseke (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Kutsuminen ’egrep’ käskyllä ei ole enää suositeltavaa, käytä sen sijaan "
-"käskyä ’grep -E’.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "HAKULAUSEKE on rivinvaihdolla eroteltu kiinteä merkkijonojoukko.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Kutsuminen ’fgrep’ käskyllä ei ole enää suositeltavaa, käytä sen sijaan "
-"käskyä ’grep -F’.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "HAKULAUSEKE on oletuksena perussäännöllinen lauseke (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Käsky ’egrep’ tarkoittaa ’grep -E’.  Käsky ’fgrep’ tarkoittaa ’grep -F’.\n"
-"Suora kutsuminen ’egrep’- ja ’fgrep’-käskyillä ei ole enää suositeltavaa.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "muut, katso <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "virheellinen kontekstin pituusargumentti"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek epäonnistui"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "syöte on liian suuri laskettavaksi"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binääritiedosto %s täsmää hakuun\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "varoitus: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiivinen hakemistosilmukka"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "syötetiedosto %s on myös tuloste"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(vakiosyöte)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Käyttö: %s [VALITSIN]... HAKULAUSEKE [TIEDOSTO]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Katso lisäohjeet valitsimella ’%s --help’.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Haetaan HAKULAUSEKEtta jokaisessa TIEDOSTOssa tai vakiosyötteessä.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "HAKULAUSEKE on oletuksena perussäännöllinen lauseke (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -543,7 +516,7 @@ msgstr ""
 "\n"
 "Säännöllisten lausekkeiden valinta ja tulkinta:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -560,7 +533,7 @@ msgstr ""
 "  -P, --perl-regexp         HAKULAUSEKE on Perl-tyyppinen säännöllinen "
 "lauseke\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -579,16 +552,15 @@ msgstr ""
 "riveihin\n"
 "  -z, --null-data           datarivi päättyy nollatavuun, ei rivinvaihtoon\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Sekalaista:\n"
@@ -596,10 +568,8 @@ msgstr ""
 "  -v, --invert-match        valitse hakuun täsmäämättömät rivit\n"
 "  -V, --version             tulosta versiotiedot ja poistu\n"
 "      --help                tulosta tämä ohje ja poistu\n"
-"      --mmap                vanhentunut ei-toiminnallisuus; kutsuu esiin "
-"varoituksen\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -624,7 +594,7 @@ msgstr ""
 "tulosteessa\n"
 "      --label=NIMIÖ         tulosta NIMIÖ tiedostonimenä vakiosyötteelle\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -639,7 +609,7 @@ msgstr ""
 "                            TYYPPI on ’binary’, ’text’, tai ’without-match’\n"
 "  -a, --text                sama kuin --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -660,7 +630,7 @@ msgstr ""
 "  -R, --dereference-recursive  samoin, mutta seuraa kaikkia symbolisia "
 "linkkejä\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -679,7 +649,7 @@ msgstr ""
 "      --exclude-dir=HAKULAUSEKE      ohitetaan HAKULAUSEKE-täsmäävät "
 "hakemistot.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -697,7 +667,7 @@ msgstr ""
 "  -T, --initial-tab         tee sarkaimet rivi ylöspäin (jos tarvitaan)\n"
 "  -Z, --null                tulosta nollatavu TIEDOSTOnimen jälkeen\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -712,7 +682,7 @@ msgstr ""
 "  -A, --after-context=N     tulosta N riviä konteksin jälkeen\n"
 "  -C, --context=N           tulosta N riviä tulostekonteksia\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -737,7 +707,16 @@ msgstr ""
 "                            -merkkiä CR ei olisi lainkaan (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Käsky ’egrep’ tarkoittaa ’grep -E’.  Käsky ’fgrep’ tarkoittaa ’grep -F’.\n"
+"Suora kutsuminen ’egrep’- ja ’fgrep’-käskyillä ei ole enää suositeltavaa.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -753,47 +732,37 @@ msgstr ""
 "jos tapahtuu virheitä ja ”-q”-valitsinta ei ollut annettu, niin paluuarvo\n"
 "on kaksi.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep-kotisivu: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s voi käyttää vain %s hakulausekesyntaksia"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "määritelty ristiriitaiset haut"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "virheellinen täsmääjä %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "tuntematon laitemetodi"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "virheellinen maksimimäärä"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tuntematon binääritiedostojen tyyppi"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "valitsin --mmap ei ole toiminut vuoden 2010 jälkeen"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -801,46 +770,68 @@ msgstr ""
 "tuki valitsimelle ”-P” ei ole käännetty tähän ”--disable-perl-regexp”-"
 "binääriin"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "valitsin ”-P” tukee vain yhtä HAKULAUSEKEtta"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "sisäinen virhe (ei pitäisi koskaan tapahtua)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "muistin varaaminen PCRE JIT-pinolle epäonnistui"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "sisäinen virhe"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "ylitettiin PCRE-rivipituusraja"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "ylitettiin PCRE-paluujäljitysraja"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "virheellinen UTF-8-tavusekvenssi syötteessä"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "sisäinen PCRE-virhe: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "HAKULAUSEKE on laajennettu säännöllinen lauseke (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Kutsuminen ’egrep’ käskyllä ei ole enää suositeltavaa, käytä sen sijaan "
+#~ "käskyä ’grep -E’.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "HAKULAUSEKE on rivinvaihdolla eroteltu kiinteä merkkijonojoukko.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Kutsuminen ’fgrep’ käskyllä ei ole enää suositeltavaa, käytä sen sijaan "
+#~ "käskyä ’grep -F’.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s voi käyttää vain %s hakulausekesyntaksia"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "valitsin --mmap ei ole toiminut vuoden 2010 jälkeen"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "päättymätön toistomäärä"
 
@@ -973,3 +964,20 @@ msgstr "sisäinen PCRE-virhe: %d"
 #~ msgid "Direct invocation as either `egrep' or `fgrep' is deprecated.\n"
 #~ msgstr ""
 #~ "Suora kutsuminen joko komennolla ”egrep” tai ”fgrep” on vanhentunut.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Miscellaneous:\n"
+#~ "  -s, --no-messages         suppress error messages\n"
+#~ "  -v, --invert-match        select non-matching lines\n"
+#~ "  -V, --version             print version information and exit\n"
+#~ "      --help                display this help and exit\n"
+#~ "\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Sekalaista:\n"
+#~ "  -s, --no-messages         vaienna virheilmoitukset\n"
+#~ "  -v, --invert-match        valitse hakuun täsmäämättömät rivit\n"
+#~ "  -V, --version             tulosta versiotiedot ja poistu\n"
+#~ "      --help                tulosta tämä ohje ja poistu\n"
+#~ "\n"
index 56d7e03..694d635 100644 (file)
Binary files a/po/fr.gmo and b/po/fr.gmo differ
index b0ccb38..a072dec 100644 (file)
--- a/po/fr.po
+++ b/po/fr.po
@@ -1,17 +1,17 @@
 # Messages français pour GNU concernant grep.
-# Copyright © 2002, 2005, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+# Copyright © 2002, 2005, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 #
 # Michel Robitaille <robitail@IRO.UMontreal.CA>, 2002, 2005.
 # Nicolas Provost <nprovost@quadriv.com>, 2009, 2010.
 # Jean-Christophe Helary <jean.christophe.helary@gmail.com>, 2011.
-# David Prévot <david@tilapin.org>, 2012, 2013.
+# David Prévot <david@tilapin.org>, 2012-2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.15.15\n"
+"Project-Id-Version: GNU grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 09:29-0400\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 09:22-0400\n"
 "Last-Translator: David Prévot <david@tilapin.org>\n"
 "Language-Team: French <traduc@traduc.org>\n"
 "Language: fr\n"
@@ -19,7 +19,7 @@ msgstr ""
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=2; plural=(n > 1);\n"
-"X-Generator: Lokalize 1.4\n"
+"X-Generator: Lokalize 1.5\n"
 
 #: lib/argmatch.c:133
 #, c-format
@@ -35,7 +35,7 @@ msgstr "argument %s ambigu pour %s"
 msgid "Valid arguments are:"
 msgstr "Les arguments valables sont :"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "erreur d'écriture"
@@ -99,8 +99,8 @@ msgstr "%s : l'option « -W %s » n'accepte pas d'argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s : l'option « -W %s » nécessite un argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "mémoire épuisée"
@@ -184,7 +184,7 @@ msgstr "( ou \\( sans correspondance"
 msgid "Unmatched \\{"
 msgstr "\\{ sans correspondance"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Contenu de \\{\\} incorrect"
 
@@ -204,7 +204,7 @@ msgstr "Expression rationnelle précédente incorrecte"
 msgid "Premature end of regular expression"
 msgstr "Fin prématurée d'expression rationnelle"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Expression rationnelle trop grande"
 
@@ -361,7 +361,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -385,7 +385,7 @@ msgstr "Page d'accueil de %s : <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Page d'accueil de %s : <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Aide globale sur les logiciels GNU : <http://www.gnu.org/help/gethelp>\n"
@@ -405,133 +405,104 @@ msgstr "suffixe incorrect dans l'argument %s%s « %s »"
 msgid "%s%s argument '%s' too large"
 msgstr "argument %s%s « %s » trop grand"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ non apparié"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "classe de caractères incorrecte"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "la syntaxe d'une classe de caractères est [[:space:]], pas [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "séquence d'échappement \\ non terminée"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( non appariée"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "aucune syntaxe indiquée"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") non appariée"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MOTIF est une expression rationnelle étendue (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"L'utilisation de « egrep » doit être abandonnée ; utilisez « grep -E » à la "
-"place.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"MOTIF est un ensemble de chaînes fixes séparées par des changements de "
-"ligne.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"L'utilisation de « fgrep » doit être abandonnée ; utilisez « grep -F » à la "
-"place.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MOTIF est, par défaut, une expression rationnelle simple.\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"« egrep » équivaut à « grep -E ». « fgrep » équivaut à « grep -F ».\n"
-"L'invocation directe de « egrep » ou « fgrep » doit être abandonnée.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "autres, consultez <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "argument de longueur de contexte incorrect"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "échec de lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "taille des données en entrée trop importante pour compter"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Fichier binaire %s correspondant\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "Avertissement : %s : %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "boucle de répertoire récursive"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "le fichier d'entrée %s est aussi en sortie"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(entrée standard)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Utilisation : %s [OPTION]... MOTIF [FICHIER]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr ""
 "Exécutez « %s --help » pour obtenir des renseignements complémentaires.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 "Chercher un MOTIF dans chaque FICHIER ou à partir de l'entrée standard.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MOTIF est, par défaut, une expression rationnelle simple.\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -542,7 +513,7 @@ msgstr ""
 "\n"
 "Sélection et interprétation de l'expression rationnelle :\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -557,7 +528,7 @@ msgstr ""
 "  -G, --basic-regexp        MOTIF est une expression rationnelle de base\n"
 "  -P, --perl-regexp         MOTIF est une expression rationnelle en Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -576,16 +547,15 @@ msgstr ""
 "entières\n"
 "  -z, --null-data           finir les lignes de données par un octet nul\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Divers :\n"
@@ -593,9 +563,8 @@ msgstr ""
 "  -v, --invert-match        sélectionner les lignes sans correspondance\n"
 "  -V, --version             afficher le nom et la version du logiciel\n"
 "      --help                afficher l'aide et quitter\n"
-"      --mmap                ignoré, à abandonner, émets un avertissement\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -622,7 +591,7 @@ msgstr ""
 "      --label=ÉTIQUETTE     utiliser ÉTIQUETTE pour le préfixe d'entrée "
 "standard\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -640,7 +609,7 @@ msgstr ""
 "match »\n"
 "  -a, --text                identique à --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -662,7 +631,7 @@ msgstr ""
 "  -R, --dereference-recursive  similaire, mais avec suivi des liens "
 "symboliques\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -680,7 +649,7 @@ msgstr ""
 "FIC\n"
 "      --exclude-dir=MOTIF   ignorer les répertoires correspondants au MOTIF\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -697,7 +666,7 @@ msgstr ""
 "  -T, --initial-tab         insérer des tabulations (si nécessaire)\n"
 "  -Z, --null                afficher l'octet nul après le nom de fichier\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -712,7 +681,7 @@ msgstr ""
 "  -A, --after-context=NBRE  afficher NBRE lignes de contexte après\n"
 "  -C, --context=NBRE        afficher NBRE lignes de contexte en sortie\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -738,7 +707,16 @@ msgstr ""
 "                            chariot (MS-DOS ou Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"« egrep » équivaut à « grep -E ». « fgrep » équivaut à « grep -F ».\n"
+"L'invocation directe de « egrep » ou « fgrep » doit être abandonnée.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -754,47 +732,37 @@ msgstr ""
 "en cas d'erreur et si l'option -q n'est pas présente, le code de sortie est "
 "2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Page d'accueil de GNU Grep : <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s ne peut utiliser que la syntaxe de motif %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "opérateurs de correspondance indiqués en conflit"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "motif de correspondance incorrect %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "méthode d'examen des périphériques inconnue"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "décompte maximal incorrect"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "type de fichier binaire inconnu"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "l'option --mmap est ignorée depuis 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -802,46 +770,70 @@ msgstr ""
 "l'option -P n'est pas prise en charge par ce programme compilé avec l'option "
 "--disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "l'option -P ne permet d'utiliser qu'un seul motif"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "erreur interne (ça ne devrait jamais arriver)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "échec d’allocation mémoire pour la pile JIT PCRE"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "erreur interne"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "limite de longueur de ligne des PCRE dépassée"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "limite de retour arrière des PCRE dépassée"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "suite incorrecte d’octets UTF-8 en entrée"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "erreur PCRE interne : %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MOTIF est une expression rationnelle étendue (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "L'utilisation de « egrep » doit être abandonnée ; utilisez « grep -E » à "
+#~ "la place.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "MOTIF est un ensemble de chaînes fixes séparées par des changements de "
+#~ "ligne.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "L'utilisation de « fgrep » doit être abandonnée ; utilisez « grep -F » à "
+#~ "la place.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s ne peut utiliser que la syntaxe de motif %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "l'option --mmap est ignorée depuis 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "décompte de répétition non terminé."
 
index df6aaa3..3a09cfe 100644 (file)
Binary files a/po/ga.gmo and b/po/ga.gmo differ
index c16454b..23be509 100644 (file)
--- a/po/ga.po
+++ b/po/ga.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.8\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2011-05-18 15:48-0500\n"
 "Last-Translator: Kevin Scannell <kscanne@gmail.com>\n"
 "Language-Team: Irish <gaeilge-gnulinux@lists.sourceforge.net>\n"
@@ -29,7 +29,7 @@ msgstr "argóint dhébhríoch %s le haghaidh %s"
 msgid "Valid arguments are:"
 msgstr "Na hargóintí bailí:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "earráid sa scríobh"
@@ -93,8 +93,8 @@ msgstr "%s: ní cheadaítear argóint i ndiaidh rogha '-W %s'\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: tá argóint de dhíth i ndiaidh rogha '-W %s'\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "cuimhne ídithe"
@@ -178,7 +178,7 @@ msgstr "( nó \\( corr"
 msgid "Unmatched \\{"
 msgstr "\\{ corr"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Ábhar neamhbhailí idir \\{\\}"
 
@@ -198,7 +198,7 @@ msgstr "Is neamhbhailí an slonn ionadaíochta roimhe seo"
 msgid "Premature end of regular expression"
 msgstr "Deireadh an tsloinn gan choinne"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Slonn ionadaíochta rómhór"
 
@@ -354,7 +354,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -378,7 +378,7 @@ msgstr "Leathanach baile %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Leathanach baile %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Cabhair ghinearálta maidir le bogearraí GNU: <http://www.gnu.org/gethelp/>\n"
@@ -398,132 +398,106 @@ msgstr "iarmhír neamhbhailí tar éis argóint %s%s `%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "argóint %s%s rómhór: `%s'"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ corr"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "Aicme charachtar neamhbhailí"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 "Is é [[:space:]] an chomhréir cheart in aicme carachtar, in ionad [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "Seicheamh éalúcháin \\ gan chríochnú"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( corr"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "Níor sonraíodh aon chomhréir"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") corr"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "Is slonn ionadaíochta feabhsaithe (ERE) é PATRÚN.\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Tá an t-ordú `egrep' imithe i léig; úsáid `grep -E' ina ionad.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "Is tacar teaghrán é PATRÚN, scartha le línte nua.\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Tá an t-ordú `fgrep' imithe i léig; úsáid `grep -F' ina ionad.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"Is slonn ionadaíochta bunúsach (BRE) é PATRÚN, de réir réamhshocraithe.\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' = `grep -E', agus `fgrep' = `grep -F'.\n"
-"Tá na horduithe `egrep' agus `fgrep' imithe i léig.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 "agus daoine eile, féach ar <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "Tá an argóint a shonraíonn an méid chomhthéacs neamhbhailí"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "theip ar lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "Tá an t-ionchur rómhór le háireamh"
 
 # using lit. "matching string" throughout for "match" - KPS
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Teaghrán comhoiriúnach sa chomhad dhénártha %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "rabhadh: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "lúb athchúrsach i gcomhadlann"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(gnáth-ionchur)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Úsáid: %s [ROGHA]... PATRÚN [COMHAD]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Bain triail as `%s --help' chun tuilleadh eolais a fháil.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Déan cuardach ar PATRÚN i ngach COMHAD nó sa ghnáth-ionchur.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"Is slonn ionadaíochta bunúsach (BRE) é PATRÚN, de réir réamhshocraithe.\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -534,7 +508,7 @@ msgstr ""
 "\n"
 "Roghnú agus léirmhíniú sloinn ionadaíochta:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -550,7 +524,7 @@ msgstr ""
 "  -G, --basic-regexp        is slonn ionadaíochta bunúsach (BRE) é PATRÚN\n"
 "  -P, --perl-regexp         is slonn ionadaíochta Perl é PATRÚN\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -567,16 +541,15 @@ msgstr ""
 "  -x, --line-regexp         meaitseálann PATRÚN línte iomlána amháin\n"
 "  -z, --null-data           léiríonn bearta '0' na foircinn línte (vs. \\n)\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Roghanna éagsúla:\n"
@@ -586,7 +559,7 @@ msgstr ""
 "      --help                taispeáin an chabhair seo agus scoir\n"
 "      --mmap                ná bac leis; comhoiriúnacht shiarghabhálach\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -610,7 +583,7 @@ msgstr ""
 "  -h, --no-filename         ná taispeáin ainmneacha comhad\n"
 "      --label=LIPÉAD        úsáid LIPÉAD mar ainm ar an ngnáth-ionchur\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, fuzzy, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -625,7 +598,7 @@ msgstr ""
 "                            CINEÁL = 'binary', 'text', nó 'without-match'\n"
 "  -a, --text                ar comhbhrí le '--binary-files=text'\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, fuzzy, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -643,7 +616,7 @@ msgstr ""
 "                              agus soicéid; MODH = 'read' nó 'skip'\n"
 "  -R, -r, --recursive       ar comhbhrí le '--directories=recurse'\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -660,7 +633,7 @@ msgstr ""
 "                              haon phatrún i gCOMHAD\n"
 "      --exclude-dir=PATRÚN  ná déan cuardach i gcomhadlanna comhoiriúnacha.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -679,7 +652,7 @@ msgstr ""
 "  -T, --initial-tab         Ailínigh na táib (más gá)\n"
 "  -Z, --null                priontáil beart '0' i ndiaidh ainm an chomhaid\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -694,7 +667,7 @@ msgstr ""
 "  -A, --after-context=UIMH  taispeáin UIMH líne de chomhthéacs deiridh\n"
 "  -C, --context=UIMHIR      taispeáin UIMHIR líne de chomhthéacs\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -716,7 +689,16 @@ msgstr ""
 "(MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' = `grep -E', agus `fgrep' = `grep -F'.\n"
+"Tá na horduithe `egrep' agus `fgrep' imithe i léig.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -730,47 +712,37 @@ msgstr ""
 "Stádas scortha: 0 (roghnaíodh aon líne ar a laghad), 1 (níor roghnaíodh),\n"
 "nó 2 (trioblóid de shaghas éigin agus níor tugadh -q).\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Leathanach baile GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "Ní féidir le %s ach comhréir phatrúin %s a úsáid"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "sonraíodh patrúin chontrártha"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "meaitseálaí neamhbhailí %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "modh anaithnid gléasanna"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "uasmhéid neamhbhailí"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "cineál anaithnid de chomhad dénártha"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -778,46 +750,63 @@ msgstr ""
 "Tiomsaíodh an clár dénártha seo le --disable-perl-regexp agus gan tacaíocht "
 "do rogha -P"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Ní thacaíonn rogha -P ach le patrún amháin"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, fuzzy, c-format
 msgid "internal error"
 msgstr "earráid sa scríobh"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "earráid sa scríobh"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "Is slonn ionadaíochta feabhsaithe (ERE) é PATRÚN.\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Tá an t-ordú `egrep' imithe i léig; úsáid `grep -E' ina ionad.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "Is tacar teaghrán é PATRÚN, scartha le línte nua.\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Tá an t-ordú `fgrep' imithe i léig; úsáid `grep -F' ina ionad.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "Ní féidir le %s ach comhréir phatrúin %s a úsáid"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "Tá líon na hathráite neamhiomlán"
 
index 0513d8e..602e4d4 100644 (file)
Binary files a/po/gl.gmo and b/po/gl.gmo differ
index 9b7ca40..96f997f 100644 (file)
--- a/po/gl.po
+++ b/po/gl.po
@@ -13,7 +13,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.10\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-02-23 18:30+0100\n"
 "Last-Translator: Leandro Regueiro <leandro.regueiro@gmail.com>\n"
 "Language-Team: Galician <proxecto@trasno.net>\n"
@@ -37,7 +37,7 @@ msgstr "argumento %s ambiguo para %s"
 msgid "Valid arguments are:"
 msgstr "Os argumentos válidos son:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "erro de escritura"
@@ -101,8 +101,8 @@ msgstr "%s: a opción '-W %s' non admite ningún argumento\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: a opción '-W %s' require un argumento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memoria esgotada"
@@ -186,7 +186,7 @@ msgstr "( ou \\( desemparellado"
 msgid "Unmatched \\{"
 msgstr "\\{ desemparellado"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Contido non válido de \\{\\}"
 
@@ -206,7 +206,7 @@ msgstr "A expresión regular precedente non é válida"
 msgid "Premature end of regular expression"
 msgstr "Final prematuro da expresión regular"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "A expresión regular é demasiado grande"
 
@@ -362,7 +362,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -386,7 +386,7 @@ msgstr "Páxina web de %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "páxina web de %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Axuda xeral sobre o uso de software de GNU: <http://www.gnu.org/gethelp/>\n"
@@ -406,130 +406,102 @@ msgstr "sufixo non válido no argumento %s%s `%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s argumento `%s' demasiado grande"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ desemparellado"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "clase de caracteres non válida"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "a sintaxe da clase de caracteres é [[:space:]], non [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "secuencia de escape \\ sen rematar"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( desemparellado"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "no se especificou ningunha sintaxe"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") desemparellado"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATRÓN é una expresión regular estendida (ERE).\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"A invocación como `egrep' está obsoleta; utilice `grep -E' no seu lugar.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATRÓN é un conxunto de cadenas fixas separadas por nova liña\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"A invocación como `fgrep' está obsoleta; utilice `grep -F' no seu lugar.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATRÓN é, por omisión, unha expresión regular básica (BRE).\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' significa `grep -E'.  `fgrep' significa `grep -F'.\n"
-"A invocación directa como `egrep' ou `fgrep' está obsoleta.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "outros, véase <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "argumento de lonxitude do contexto non vlido"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "fallou a chamada ao sistema `lskeek'"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "a entrada  longa de mis para contala"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Arquivo binario %s aparicins\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "atención: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "ciclo de directorios recursivo"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "o fichero de entrada %s tamén é o de salida"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(entrada estándar)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Emprego: %s [OPCIN]... PATRN [FICHEIRO]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Escriba `%s --help' para mis informacin.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Busca PATRÓN en cada FICHERO ou na entrada estándar.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATRÓN é, por omisión, unha expresión regular básica (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -540,7 +512,7 @@ msgstr ""
 "\n"
 "Selección e interpretación de Expreg:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -555,7 +527,7 @@ msgstr ""
 "  -G, --basic-regexp        PATRÓN é unha expresión regular básica (BRE)\n"
 "  -P, --perl-regexp         PATRÓN é unha expresión regular en Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -575,16 +547,15 @@ msgstr ""
 "  -z, --null-data           unha liña de datos termina nun byte 0, non\n"
 "                            nun carácter de nova liña\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Variadas:\n"
@@ -594,7 +565,7 @@ msgstr ""
 "      --help                mostra esta axuda e finaliza\n"
 "      --mmap                descártase para compatibilidade cara atrás\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -623,7 +594,7 @@ msgstr ""
 "      --label=ETIQUETA      utiliza ETIQUETA como nome de ficheiro prefixo\n"
 "                            para a entrada estándar\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, fuzzy, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -639,7 +610,7 @@ msgstr ""
 "                            TIPO é `binary', `text', ou `without-match'\n"
 "  -a, --text                equivalente a --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, fuzzy, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -657,7 +628,7 @@ msgstr ""
 "                            `sockets', pode ser 'read' ou 'skip'\n"
 "  -R, -r, --recursive       equivalente a --directories=recurse\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -676,7 +647,7 @@ msgstr ""
 "      --exclude-dir=PATRÓN    omítense os directorios que coinciden con "
 "PATRÓN\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -693,7 +664,7 @@ msgstr ""
 "                            por cada FICHEIRO\n"
 "  -Z, --null                imprime un byte 0 despois do nome do FICHEIRO\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -708,7 +679,7 @@ msgstr ""
 "  -A, --after-context=NÚM   mostra NÚM liñas de contexto posterior\n"
 "  -C, --context=NÚM         mostra NÚM liñas de contexto\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -730,7 +701,16 @@ msgstr ""
 "  -u, --unix-byte-offsets   conta os desprazamentos como se non houbera\n"
 "                            retornos de carro (MSDOS)\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' significa `grep -E'.  `fgrep' significa `grep -F'.\n"
+"A invocación directa como `egrep' ou `fgrep' está obsoleta.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -744,47 +724,37 @@ msgstr ""
 "é 0 se hai coincidencias, 1 se non as hai; se se produce algún error e non \n"
 "se especificou -q, o estado de saída é 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Páxina web de GNU grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s só puede usar a sintaxe de patrón %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "especificronse patrns conflictivos"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "expresión non válida %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "método de dispositivos descoñecido"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "contador máximo non válido"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipo binary-files descoñecido"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -792,46 +762,65 @@ msgstr ""
 "a compatibilidade para a opción -P non está compilada neste executábel --"
 "disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "a opción -P só admite un patrón"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "erro interno"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, fuzzy, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "excedeuse o límite de volta atrás das PCREs"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "excedeuse o límite de volta atrás das PCREs"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "erro interno"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATRÓN é una expresión regular estendida (ERE).\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "A invocación como `egrep' está obsoleta; utilice `grep -E' no seu lugar.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATRÓN é un conxunto de cadenas fixas separadas por nova liña\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "A invocación como `fgrep' está obsoleta; utilice `grep -F' no seu lugar.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s só puede usar a sintaxe de patrón %s"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "contador de repetición sen rematar"
 
index d01b2e7..c658f70 100644 (file)
@@ -6,9 +6,9 @@
 #, fuzzy
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.16\n"
+"Project-Id-Version: GNU grep 2.19\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -31,7 +31,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -95,8 +95,8 @@ msgstr ""
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr ""
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr ""
@@ -180,7 +180,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -200,7 +200,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -334,7 +334,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -356,7 +356,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -375,123 +375,102 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr ""
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr ""
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr ""
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr ""
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ""
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr ""
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr ""
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr ""
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr ""
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr ""
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr ""
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr ""
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr ""
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -499,7 +478,7 @@ msgid ""
 "Regexp selection and interpretation:\n"
 msgstr ""
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -509,7 +488,7 @@ msgid ""
 "  -P, --perl-regexp         PATTERN is a Perl regular expression\n"
 msgstr ""
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -520,19 +499,18 @@ msgid ""
 "  -z, --null-data           a data line ends in 0 byte, not newline\n"
 msgstr ""
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -547,7 +525,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -557,7 +535,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -569,7 +547,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -580,7 +558,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -590,7 +568,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -600,7 +578,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -614,7 +592,14 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -624,88 +609,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr ""
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr ""
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr ""
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr ""
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr ""
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr ""
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 6df3823..b978c94 100644 (file)
Binary files a/po/he.gmo and b/po/he.gmo differ
index 60dddc8..08edf86 100644 (file)
--- a/po/he.po
+++ b/po/he.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5.1a\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2005-03-04 14:55+0200\n"
 "Last-Translator: Eli Zaretskii <eliz@gnu.org>\n"
 "Language-Team: Hebrew <eliz@gnu.org>\n"
@@ -29,7 +29,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -93,8 +93,8 @@ msgstr "%s 
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s úéðëú øåáò èðîåâøà áééçî `%s' ïééôàî\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "ïåøëæä øîâð"
@@ -178,7 +178,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -198,7 +198,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -332,7 +332,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -356,7 +356,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -375,128 +375,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "âåæ-ïá åì ïéàù ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "äøåîâ-éúìá \\ äø÷á úøãñ"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "âåæ-ïá åì ïéàù ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "øéáçú úøãâä ïéà"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "âåæ-ïá åì ïéàù )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "øù÷ää èñ÷è êøåà ìù äéåâù äøãâä"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "øåôñì éãëî ìåãâ èì÷"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "äîéàúî úæåøçî ìéëî %s éøàðéá õáå÷\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "%s %s :äøäæà\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "äé÷éúá äéñøå÷ø úàìåì"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(éð÷ú èì÷ õåøò)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "%s [íéðééôàî]... PATTERN [õáå÷]  :ùåîéùä ïôåà\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr ".øúåé áø òãéî úâöäì `%s --help' äñð\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -508,7 +487,7 @@ msgstr ""
 "\n"
 "                                        :íééøìåâøä íééèéáä âååéñå äøéçá\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -522,7 +501,7 @@ msgstr ""
 "                  éñéñá éøìåâø éåèéá àåä PATTERN   -E, --extended-regexp\n"
 "            Perl ïåðâñá éøìåâø éåèéá àåä PATTERN   -P, --perl-regexp\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -539,16 +518,15 @@ msgstr ""
 "           úåîìù úåøåùì ÷øå êà íéàúäì PATTERN ìò   -x, --line-regexp\n"
 "           newline-á àì ,0-úéáá úîééúñî èì÷ úøåù   -z, --null-data\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "                                                           :íéôñåð íéðééôàî\n"
@@ -558,7 +536,7 @@ msgstr ""
 "                     úéðëúäî àöå äæ äøæò êñî âöä       --help\n"
 "    ïåøëæì úåøéùé èì÷ éöá÷ éåôéîá ùîúùä ,øùôà íà       --mmap\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -573,7 +551,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -583,7 +561,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -595,7 +573,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -606,7 +584,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -616,7 +594,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -626,7 +604,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -656,7 +634,14 @@ msgstr ""
 "                                     .-h òîúùî ,íéöá÷ éðùî úåçô íéðåúð íà\n"
 "       .úåì÷ú ìù äø÷îá 2 ,åàöîð àì íà 1 ,úåîàúä åàöîð íà 0 åðéä äàéöé ãå÷\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -666,88 +651,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "äîàúää éâåñ ìù íéøúåñ íéðåéö"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "éåâù éáøéî øôñî"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "íéð÷úäá ìåôéèì úøëåî-éúìá úèéù"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "éåâù éáøéî øôñî"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "íééøàðéá íéöá÷á ìåôéèì úøëåî-éúìá úèéù"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P ïééôàîá äëéîú ïéà"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 10b1e23..9b048b9 100644 (file)
Binary files a/po/hr.gmo and b/po/hr.gmo differ
index 23fce37..649c6db 100644 (file)
--- a/po/hr.po
+++ b/po/hr.po
@@ -9,7 +9,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-09-27 23:22+0200\n"
 "Last-Translator: Tomislav Krznar <tomislav.krznar@gmail.com>\n"
 "Language-Team: Croatian <lokalizacija@linux.hr>\n"
@@ -35,7 +35,7 @@ msgstr "višeznačan argument %s za %s"
 msgid "Valid arguments are:"
 msgstr "Ispravni argumenti su:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "greška pisanja"
@@ -99,8 +99,8 @@ msgstr "%s: opcija „-W %s” ne dozvoljava argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opcija „-W %s” zahtijeva argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memorija iscrpljena"
@@ -184,7 +184,7 @@ msgstr "Nesparena ( ili \\("
 msgid "Unmatched \\{"
 msgstr "Nesparena \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Neispravan sadržaj \\{\\}"
 
@@ -204,7 +204,7 @@ msgstr "Neispravan prethodni regularni izraz"
 msgid "Premature end of regular expression"
 msgstr "Preuranjen kraj regularnog izraza"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regularni izraz je prevelik"
 
@@ -361,7 +361,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -386,7 +386,7 @@ msgstr "%s početna stranica: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s početna stranica: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Općenita pomoć za korištenje GNU softvera: <http://www.gnu.org/gethelp/>\n"
@@ -406,126 +406,102 @@ msgstr "neispravan sufiks u %s%s argumentu „%s”"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s argument „%s” je prevelik"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "nesparena ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "neispravan razred znakova"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "sintaksa razreda znakova je [[:space]], ne [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "nedovršeni \\ izlaz"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "nesparena ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "nije zadana sintaksa"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "nesparena )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "UZORAK je prošireni regularni izraz (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Pozivanje naredbom „egrep” je zastarjelo; koristite „grep -E”.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"UZORAK je skup fiksnih znakovnih nizova odvojenih znakom novog retka.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Pozivanje naredbom „fgrep” je zastarjelo; koristite „grep -F”.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "UZORAK je uobičajeno osnovni regularni izraz (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep” znači „grep -E”.  „fgrep” znači „grep -F”.\n"
-"Izravno pozivanje „egrep” i „fgrep” je zastarjelo.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "ostali, pogledajte <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "neispravan argument duljine konteksta"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek nije uspio"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "ulaz je prevelik za brojanje"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binarna datoteka %s se podudara\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "upozorenje: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekurzivna petlja direktorija"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "ulazna datoteka %s je također i izlaz"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standardni ulaz)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Uporaba: %s [OPCIJA]... UZORAK [DATOTEKA]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Pokušajte „%s --help” za više informacija.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Traži UZORAK u svakoj DATOTECI ili standardnom ulazu.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "UZORAK je uobičajeno osnovni regularni izraz (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -536,7 +512,7 @@ msgstr ""
 "\n"
 "Izbor i interpretacija regularnih izraza:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -551,7 +527,7 @@ msgstr ""
 "  -G, --basic-regexp        UZORAK je osnovni regularni izraz (BRE)\n"
 "  -P, --perl-regexp         UZORAK je Perl regularni izraz\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -569,16 +545,15 @@ msgstr ""
 "  -z, --null-data           podatkovni redak završava bajtom 0, ne znakom\n"
 "                              novog retka\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Razno:\n"
@@ -589,7 +564,7 @@ msgstr ""
 "      --mmap                zastarjela prazna operacija (no-op); javlja\n"
 "                              upozorenje\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -614,7 +589,7 @@ msgstr ""
 "      --label=OZNAKA        koristi OZNAKU kao prefiks imena datoteke "
 "standardnog ulaza\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -629,7 +604,7 @@ msgstr ""
 "                            VRSTA je „binary”, „text” ili „without-match”\n"
 "  -a, --text                ekvivalentno opciji --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -649,7 +624,7 @@ msgstr ""
 "  -r, --recursive           isto kao --directories=recurse\n"
 "  -R, --dereference-recursive  jednako, ali slijedi simboličke veze\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -668,7 +643,7 @@ msgstr ""
 "      --exclude-dir=UZORAK  direktoriji koji odgovaraju UZORKU će se "
 "preskočiti.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -684,7 +659,7 @@ msgstr ""
 "  -T, --initial-tab         poravnaj tabulatore (ako je potrebno)\n"
 "  -Z, --null                ispiši bajt 0 nakon imena DATOTEKE\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -699,7 +674,7 @@ msgstr ""
 "  -A, --after-context=BROJ  ispiši BROJ redaka sadržaja koji slijedi\n"
 "  -C, --context=BROJ        ispiši BROJ redaka izlaznog sadržaja\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -725,7 +700,16 @@ msgstr ""
 "Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep” znači „grep -E”.  „fgrep” znači „grep -F”.\n"
+"Izravno pozivanje „egrep” i „fgrep” je zastarjelo.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -740,47 +724,37 @@ msgstr ""
 "Izlazno stanje je 0 ako je odabran bilo koji redak, inače 1;\n"
 "ako su se pojavile greške i opcija -q nije zadana, izlazno stanje je 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep početna stranica: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s može koristiti samo %s sintaksu uzoraka"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "navedeni su suprotstavljeni izrazi"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "neispravan uspoređivač %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "nepoznata metoda uređaja"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "neispravan maksimalni broj ponavljanja"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "nepoznata vrsta binarnih datoteka"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "opcija --map je prazna operacija (no-op) od 2010."
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -788,46 +762,65 @@ msgstr ""
 "podrška za opciju -P nije kompajlirana u ovu --disable-perl-regexp binarnu "
 "datoteku"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "opcija -P podržava samo jedan uzorak"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "interna greška"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "prekoračeno ograničenje PCRE duljine retka"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "prekoračeno ograničenje PCRE praćenja"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "interna greška"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "UZORAK je prošireni regularni izraz (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Pozivanje naredbom „egrep” je zastarjelo; koristite „grep -E”.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "UZORAK je skup fiksnih znakovnih nizova odvojenih znakom novog retka.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Pozivanje naredbom „fgrep” je zastarjelo; koristite „grep -F”.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s može koristiti samo %s sintaksu uzoraka"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "opcija --map je prazna operacija (no-op) od 2010."
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "nedovren broj ponavljanja"
 
index 20a26c0..d914d7c 100644 (file)
Binary files a/po/hu.gmo and b/po/hu.gmo differ
index 6d05803..0de788b 100644 (file)
--- a/po/hu.po
+++ b/po/hu.po
@@ -1,17 +1,17 @@
 # Hungarian translation of grep.
 # This file is distributed under the same license as the grep package.
-# Copyright (C) 2002, 2009, 2010 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2009, 2010, 2014 Free Software Foundation, Inc.
 #
 # Emese Kovács <emese@gnome.hu>, 2002.
-# Gabor Kelemen <kelemeng@gnome.hu>, 2009, 2010.
+# Gabor Kelemen <kelemeng@gnome.hu>, 2009, 2010, 2014.
 # Emese Kovács <emese@instantweb.hu>, 2010.
 msgid ""
 msgstr ""
-"Project-Id-Version: grep 2.7\n"
+"Project-Id-Version: grep 2.16.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2010-10-19 01:23+0200\n"
-"Last-Translator: Emese Kovacs <emese@instantweb.hu>\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-03-16 15:59+0100\n"
+"Last-Translator: Gabor Kelemen <kelemeng@gnome.hu>\n"
 "Language-Team: Hungarian <translation-team-hu@lists.sourceforge.net>\n"
 "Language: hu\n"
 "MIME-Version: 1.0\n"
@@ -34,7 +34,7 @@ msgstr "a(z) „%s” argumentum nem egyértelmű a következőhöz: „%s”"
 msgid "Valid arguments are:"
 msgstr "Az érvényes argumentumok a következők:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "íráshiba"
@@ -44,9 +44,9 @@ msgid "Unknown system error"
 msgstr "Ismeretlen rendszerhiba"
 
 #: lib/getopt.c:547 lib/getopt.c:576
-#, fuzzy, c-format
+#, c-format
 msgid "%s: option '%s' is ambiguous; possibilities:"
-msgstr "%s: a(z) „%s” kapcsoló nem egyértelmű\n"
+msgstr "%s: a(z) „%s” kapcsoló nem egyértelmű, lehetőségek:"
 
 #: lib/getopt.c:624 lib/getopt.c:628
 #, c-format
@@ -98,8 +98,8 @@ msgstr "%s: a „-W %s” kapcsoló nem enged meg argumentumot\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: a(z) „-W%s” kapcsolóhoz argumentum szükséges\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "elfogyott a memória"
@@ -107,12 +107,12 @@ msgstr "elfogyott a memória"
 #: lib/openat-die.c:38
 #, c-format
 msgid "unable to record current working directory"
-msgstr ""
+msgstr "az aktuális munkakönyvtár feljegyzése meghiúsult"
 
 #: lib/openat-die.c:57
 #, c-format
 msgid "failed to return to initial working directory"
-msgstr ""
+msgstr "a visszatérés meghiúsult a kiinduló munkakönyvtárba"
 
 #. TRANSLATORS:
 #. Get translations for open and closing quotation marks.
@@ -183,7 +183,7 @@ msgstr "Pár nélküli ( vagy \\("
 msgid "Unmatched \\{"
 msgstr "Pár nélküli \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "A \\{\\} tartalma érvénytelen"
 
@@ -203,7 +203,7 @@ msgstr "Érvénytelen megelőző szabályos kifejezés"
 msgid "Premature end of regular expression"
 msgstr "A szabályos kifejezés túl korán véget ért"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "A szabályos kifejezés túl nagy"
 
@@ -360,7 +360,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -384,151 +384,123 @@ msgstr "A(z) %s honlapja: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "A %s honlapja: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Általános segítség a GNU szoftverek használatához: <http://www.gnu.org/"
 "gethelp/>\n"
 
 #: lib/xstrtol-error.c:63
-#, fuzzy, c-format
+#, c-format
 msgid "invalid %s%s argument '%s'"
 msgstr "érvénytelen %s%s argumentum: „%s”"
 
 #: lib/xstrtol-error.c:68
-#, fuzzy, c-format
+#, c-format
 msgid "invalid suffix in %s%s argument '%s'"
 msgstr "érvénytelen utótag a(z) %s%s argumentumban: „%s”"
 
 #: lib/xstrtol-error.c:72
-#, fuzzy, c-format
+#, c-format
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s: a(z) „%s” argumentum túl nagy"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "kiegyensúlyozatlan ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "érvénytelen karakterosztály"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "a karakterosztály szintaxisa [[:space:]], nem [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "befejezetlen \\ escape"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "kiegyensúlyozatlan ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "nincs szintaxis megadva"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "kiegyensúlyozatlan )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "A MINTA egy bővített reguláris kifejezés (ERE).\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"A hívás „egrep” formában elavult, használja helyette a „grep -E” alakot.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "A MINTA egy újsorokkal elválasztott rögzített karakterlánc.\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"A hívás „fgrep” formában elavult, használja helyette a „grep -F” alakot.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "A MINTA egy alapszintű reguláris kifejezés (BRE).\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Az „egrep” jelentése „grep -E”. Az „fgrep” jelentése „grep -F”.\n"
-"A közvetlen hívás „egrep” vagy „fgrep” formában elavult.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "másol, lásd: <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "érvénytelen szövegkörnyezethossz argumentum"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "az lseek meghiúsult"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "a bemenet túl nagy a megszámláláshoz"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "%s bináris fájl illeszkedik\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "figyelmeztetés: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekurzív könyvtárhurok"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
-msgstr ""
+msgstr "%s bemeneti fájl a kimenet is"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(szabványos bemenet)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Használat: %s [KAPCSOLÓ]… MINTA [FÁJL]…\n"
 
-#: src/main.c:1541
-#, fuzzy, c-format
+#: src/grep.c:1529
+#, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "További információkért adja ki a(z) „%s --help” parancsot.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "A MINTA keresése minden FÁJLBAN vagy a szabványos bemeneten.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "A MINTA egy alapszintű reguláris kifejezés (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -539,7 +511,7 @@ msgstr ""
 "\n"
 "Reguláris kifejezés kiválasztása és értelmezése:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -554,7 +526,7 @@ msgstr ""
 "  -G, --basic-regexp        a MINTA alapvető reguláris kifejezés (BRE)\n"
 "  -P, --perl-regexp         a MINTA Perl reguláris kifejezés\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -571,16 +543,15 @@ msgstr ""
 "  -x, --line-regexp         a MINTA csak egész sorra illeszkedik\n"
 "  -z, --null-data           az adat sorai 0 bájtra végződnek, nem újsorra\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Egyéb:\n"
@@ -588,11 +559,11 @@ msgstr ""
 "  -v, --invert-match        a nem illeszkedő sorok kiválogatása\n"
 "  -V, --version             verzióinformációk kiírása és kilépés\n"
 "      --help                ezen súgó kiírása és kilépés\n"
-"      --mmap                a visszamenőleges kompatibilitás érdekében "
-"mellőzve\n"
+"\n"
+" "
 
-#: src/main.c:1576
-#, fuzzy, c-format
+#: src/grep.c:1561
+#, c-format
 msgid ""
 "\n"
 "Output control:\n"
@@ -618,8 +589,8 @@ msgstr ""
 "bemenet\n"
 "                              használatakor\n"
 
-#: src/main.c:1587
-#, fuzzy, c-format
+#: src/grep.c:1572
+#, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
 "  -q, --quiet, --silent     suppress all normal output\n"
@@ -636,8 +607,8 @@ msgstr ""
 "egyike\n"
 "  -a, --text                ugyanaz, mint a --binary-files=text\n"
 
-#: src/main.c:1594
-#, fuzzy, c-format
+#: src/grep.c:1579
+#, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
 "  -d, --directories=ACTION  how to handle directories;\n"
@@ -653,9 +624,10 @@ msgstr ""
 "  -D, --devices=MŰVELET     mi történjen az eszközökkel, FIFO-kkal és\n"
 "                              foglalatokkal, a MŰVELET a „read” vagy „skip”\n"
 "                              egyike\n"
-"  -R, -r, --recursive       ugyanaz, mint a --directories=recurse\n"
+"  -r, --recursive           ugyanaz, mint a --directories=recurse\n"
+"  -R, --dereference-recursive hasonló, de követi az összes szimlinket\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -672,7 +644,7 @@ msgstr ""
 "                              fájlok kihagyása.\n"
 "      --exclude-dir=MINTA   a MINTÁRA illeszkedő könyvtárak kihagyása\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -689,7 +661,7 @@ msgstr ""
 "  -T, --initial-tab         sorok feltöltése tabokkal (ha szükséges)\n"
 "  -Z, --null                0 bájt írása a FÁJLNÉV után\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -706,8 +678,8 @@ msgstr ""
 "környezetből\n"
 "  -C, -- context=SZÁM       SZÁM darab sor kiírása a környezetből\n"
 
-#: src/main.c:1622
-#, fuzzy, c-format
+#: src/grep.c:1607
+#, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
 "      --color[=WHEN],\n"
@@ -723,13 +695,23 @@ msgstr ""
 "      --color[=EKKOR],\n"
 "      --colour[=EKKOR]      az illeszkedő karakterláncot beszínezi\n"
 "                              az EKKOR lehet „always”, „never” vagy „auto”\n"
-"  -U, --binary              nem vágja le a CR karaktereket sor végén "
-"(MSDOS)\n"
-"  -u, --unix-byte-offsets   eltolások kiírása, mintha nem lenne CR (MSDOS)\n"
+"  -U, --binary              nem vágja le a CR karaktereket sor végén\n"
+"                              (MSDOS/Windows)\n"
+"  -u, --unix-byte-offsets   eltolások kiírása, mintha nem lenne ott a CR\n"
+"                              (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
-#, fuzzy, c-format
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Az „egrep” jelentése „grep -E”. Az „fgrep” jelentése „grep -F”.\n"
+"A közvetlen hívás „egrep” vagy „fgrep” formában elavult.\n"
+
+#: src/grep.c:1619
+#, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
 "line\n"
@@ -737,54 +719,43 @@ msgid ""
 "Exit status is 0 if any line is selected, 1 otherwise;\n"
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
-"Ha nincs megadva FÁJL, vagy a FÁJL a -, akkor a szabványos bemenetről "
-"olvas.\n"
-"Ha kevesebb mint két FÁJL van megadva, a -h kapcsolót feltételezi. A "
-"kilépési\n"
+"Ha a FÁJL a -, akkor a szabványos bemenetről olvas. Ha nincs megadva FÁJL,\n"
+"és a parancssori -r meg van adva, a . egyébként a - olvasása. Ha kevesebb\n"
+"mint két FÁJL van megadva, a -h kapcsolót feltételezi. A kilépési\n"
 "érték: 0, ha van találat, egyébként 1, ha hiba történt és a -q nincs "
 "megadva: 2\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "A GNU Grep honlapja: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "a(z) %s csak a(z) %s mintaszintaxist tudja használni"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "ütköző illesztők lettek megadva"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "érvénytelen illesztő: %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "ismeretlen eszközmódszer"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "érvénytelen maximális szám"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "ismeretlen bináris fájl típus"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -792,75 +763,59 @@ msgstr ""
 "a -P kapcsoló támogatása nincs belefordítva ebbe a --disable-perl-regexp "
 "binárisba"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "a -P kapcsoló csak egy mintát támogat"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
-msgstr ""
+msgstr "belső hiba (soha nem szabadna előfordulnia)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
-msgstr ""
+msgstr "nem sikerült memóriát foglalni a PCRE JIT veremnek"
 
-#: src/pcresearch.c:144
-#, fuzzy, c-format
+#: src/pcresearch.c:134
+#, c-format
 msgid "internal error"
-msgstr "íráshiba"
+msgstr "belső hiba"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
-msgstr ""
+msgstr "a PCRE sorhossza túllépve"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
-msgstr ""
+msgstr "a PCRE visszakövetési korlátja túllépve"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
-msgstr ""
+msgstr "érvénytelen UTF-8 bájtsorozat a bemenetben"
 
-#: src/pcresearch.c:206
-#, fuzzy, c-format
+#: src/pcresearch.c:192
+#, c-format
 msgid "internal PCRE error: %d"
-msgstr "íráshiba"
-
-#~ msgid "unfinished repeat count"
-#~ msgstr "befejezetlen ismétlési szám"
+msgstr "belső PCRE hiba: %d"
 
-#~ msgid "malformed repeat count"
-#~ msgstr "rosszul megadott ismétlési szám"
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "A MINTA egy bővített reguláris kifejezés (ERE).\n"
 
-#~ msgid "writing output"
-#~ msgstr "eredmény kiírása"
-
-#~ msgid ""
-#~ "in GREP_COLORS=\"%s\", the \"%s\" capacity needs a value (\"=...\"); "
-#~ "skipped"
-#~ msgstr ""
-#~ "a GREP_COLORS=„%s”, a(z) „%s” képességnek értéket kell adni („=...”); "
-#~ "kihagyva."
-
-#~ msgid ""
-#~ "in GREP_COLORS=\"%s\", the \"%s\" capacity is boolean and cannot take a "
-#~ "value (\"=%s\"); skipped"
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
 #~ msgstr ""
-#~ "a GREP_COLORS=„%s”, a(z) „%s” képesség logikai és nem kaphat értéket („="
-#~ "%s”); kihagyva."
+#~ "A hívás „egrep” formában elavult, használja helyette a „grep -E” alakot.\n"
 
-#~ msgid "in GREP_COLORS=\"%s\", the \"%s\" capacity %s"
-#~ msgstr "a GREP_COLORS=„%s”, a(z) „%s” képesség %s."
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "A MINTA egy újsorokkal elválasztott rögzített karakterlánc.\n"
 
-#~ msgid ""
-#~ "stopped processing of ill-formed GREP_COLORS=\"%s\" at remaining "
-#~ "substring \"%s\""
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
 #~ msgstr ""
-#~ "a hibásan formázott GREP_COLORS=„%s” feldolgozása leállt a hátralévő „%s” "
-#~ "részkarakterláncnál."
+#~ "A hívás „fgrep” formában elavult, használja helyette a „grep -F” alakot.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "a(z) %s csak a(z) %s mintaszintaxist tudja használni"
index 0a4bc20..fc0df99 100644 (file)
Binary files a/po/id.gmo and b/po/id.gmo differ
index df8cb67..41a070b 100644 (file)
--- a/po/id.po
+++ b/po/id.po
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.11.11-pre1\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-05-27 07:00+0700\n"
 "Last-Translator: Arif E. Nugroho <arif_endro@yahoo.com>\n"
 "Language-Team: Indonesian <translation-team-id@lists.sourceforge.net>\n"
@@ -31,7 +31,7 @@ msgstr "ambiguous (tidak sesuai) argumen %s untuk %s"
 msgid "Valid arguments are:"
 msgstr "Valid (sesuai) argumen adalah:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "penulisan error"
@@ -95,8 +95,8 @@ msgstr "%s: opsi `-W %s' tidak mengijinkan sebuah argumen\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opsi `-W %s' membutuhkan sebuah argumen\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "kehabisan memori"
@@ -180,7 +180,7 @@ msgstr "Tidak cocok ( atau \\("
 msgid "Unmatched \\{"
 msgstr "Tidak cocok \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Isi dari \\{\\} tidak valid"
 
@@ -200,7 +200,7 @@ msgstr "Ekspresi umum yang mengawali tidak valid"
 msgid "Premature end of regular expression"
 msgstr "Akhir dari ekspresi umum tidak sempurna"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Ekspresi umum terlalu besar"
 
@@ -359,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -383,7 +383,7 @@ msgstr "Halaman rumah %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Halaman rumah %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Bantuan umum menggunakan aplikasi GNU: <http://www.gnu.org/gethelp/>\n"
 
@@ -402,130 +402,103 @@ msgstr "invalid (tidak sesuai) akhiran dalam %s%s argumen '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s argumen '%s' terlalu besar"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ tidak seimbang"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "Nama kelas karakter tidak valid"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 "character (karakter) tingkat sintaks adalah [[:space:]], tidak [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "escape \\\\ tidak selesai"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( tidak seimbang"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "Tidak ada sintaks yang dispesifikasikan"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") tidak seimbang"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "POLA adalah sebuah ekstensi ekspresi regular (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Pemanggilan sebagai `egrep' sudah ditinggalkan; lebih baik gunakan `grep -"
-"E'.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "POLA adalah sebuah seet dari baris-baru dipisahkan string tetap.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"pemanggilan sebagai `fgrep' sudah ditinggalkan; lebih baik gunakan `grep -"
-"F'.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "POLA adalah, secara baku, sebuah ekspresi regular dasar (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' berarti `grep -E'. `fgrep' berarti `grep -F'.\n"
-"Pemanggilan langsung baik sebagai `egrep' atau `fgrep' sudah ditinggalkan.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "lain, lihat <http://git.sv.gnu.org/sgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "konteks panjang argumen tidak valid"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "gagal lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "masukan terlalu besar untuk dihitung"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Berkas binari %s cocok\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "peringatan: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "perulangan direktori rekursif"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "input (masuk) berkas %s juga keluar"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standar masukan)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Penggunaan: %s [OPSI]... POLA [BERKAS]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Coba `%s --help' untuk informasi lebih lanjut.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Cari untuk POLA dalam setiap berkas atau standar masukan.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "POLA adalah, secara baku, sebuah ekspresi regular dasar (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -536,7 +509,7 @@ msgstr ""
 "\n"
 "Seleksi dan interpretasi regexp:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -551,7 +524,7 @@ msgstr ""
 "  -G, --basic-regexp        POLA adalah ekspresi reguler dasar\n"
 "  -P, --perl-regexp         POLA adalah sebuah ekspresi reguler Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -572,16 +545,15 @@ msgstr ""
 "baru\n"
 "\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Lain-lain:\n"
@@ -591,7 +563,7 @@ msgstr ""
 "      --help                tampilkan bantuan ini dan keluar\n"
 "      --mmap                gunakan masukan memory-mapped bila memungkinkan\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -606,7 +578,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -616,7 +588,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -628,7 +600,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -639,7 +611,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -649,7 +621,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -659,7 +631,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -690,7 +662,16 @@ msgstr ""
 "(MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' berarti `grep -E'. `fgrep' berarti `grep -F'.\n"
+"Pemanggilan langsung baik sebagai `egrep' atau `fgrep' sudah ditinggalkan.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -706,47 +687,37 @@ msgstr ""
 "jika ada error apapun yang terjadi dan opsi -q tidak diberikan, status "
 "keluar adalah 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Halaman rumah GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "konflik pencocokan dispesifikasikan"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "jumlah maksimal tidak valid"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "metode device tidak dikenal"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "jumlah maksimal tidak valid"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipe berkas binari tidak dikenal"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 #, fuzzy
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
@@ -755,46 +726,62 @@ msgstr ""
 "Dukungan untuk opsi -P tidak dikompile kedalam ini --disable-perl-regexp "
 "binari"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Opsi -P hanya mendukung sebuah pola tunggal"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, fuzzy, c-format
 msgid "internal error"
 msgstr "penulisan error"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "penulisan error"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "POLA adalah sebuah ekstensi ekspresi regular (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Pemanggilan sebagai `egrep' sudah ditinggalkan; lebih baik gunakan `grep -"
+#~ "E'.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "POLA adalah sebuah seet dari baris-baru dipisahkan string tetap.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "pemanggilan sebagai `fgrep' sudah ditinggalkan; lebih baik gunakan `grep -"
+#~ "F'.\n"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "jumlah perulangan tidak selesai"
 
index a3f9481..1c2efa5 100644 (file)
Binary files a/po/it.gmo and b/po/it.gmo differ
index c0afc18..7bd2e6c 100644 (file)
--- a/po/it.po
+++ b/po/it.po
@@ -1,24 +1,25 @@
 # Italian translation of grep
-# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 #
 # Marco d'Itri <md@linux.it>, 1999, 2001.
-# Milo Casagrande <milo@milo.name>, 2008, 2009, 2010, 2011, 2012, 2013.
+# Milo Casagrande <milo@milo.name>, 2008, 2009, 2010, 2011, 2012, 2013, 2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.15.15\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-23 14:23+0100\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 13:54+0100\n"
 "Last-Translator: Milo Casagrande <milo@milo.name>\n"
 "Language-Team: Italian <tp@lists.linux.it>\n"
 "Language: it\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8-bit\n"
+"Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=2; plural=(n!=1);\n"
-"X-Generator: Gtranslator 2.91.6\n"
+"X-Generator: Poedit 1.6.4\n"
+"X-Poedit-SourceCharset: UTF-8\n"
 
 #: lib/argmatch.c:133
 #, c-format
@@ -34,7 +35,7 @@ msgstr "argomento %s ambiguo per %s"
 msgid "Valid arguments are:"
 msgstr "Gli argomenti validi sono:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "errore di scrittura"
@@ -98,8 +99,8 @@ msgstr "%s: l'opzione \"-W %s\" non accetta un argomento\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: l'opzione \"-W %s\" richiede un argomento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memoria esaurita"
@@ -184,7 +185,7 @@ msgstr "( o \\( senza corrispondenza"
 msgid "Unmatched \\{"
 msgstr "\\{ senza corrispondenza"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Contenuto di \\{\\} non valido"
 
@@ -204,7 +205,7 @@ msgstr "Espressione regolare precedente non valida"
 msgid "Premature end of regular expression"
 msgstr "Fine prematura dell'espressione regolare"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Espressione regolare troppo grande"
 
@@ -362,7 +363,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -386,7 +387,7 @@ msgstr "Sito web di %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Sito web di %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Pagina di aiuto per l'utilizzo di software GNU: <http://www.gnu.org/gethelp/"
@@ -407,126 +408,103 @@ msgstr "il suffisso nell'argomento \"%3$s\" di %1$s%2$s non è valido"
 msgid "%s%s argument '%s' too large"
 msgstr "l'argomento \"%3$s\" di %1$s%2$s è troppo grande"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ non bilanciata"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "Classe del carattere non valido"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "La sintassi per la classe di caratteri è [[:space:]], non [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "Escape \\ incompleto"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( non bilanciata"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "Nessuna sintassi specificata"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") non bilanciata"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MODELLO è un'espressione regolare estesa (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "L'invocazione come \"egrep\" è deprecata, usare \"grep -E\".\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "MODELLO è un insieme di stringhe letterali separate da newline.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "L'invocazione come \"fgrep\" è deprecata, usare \"grep -F\".\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"MODELLO è, in modo predefinito, un'espressione regolare di base (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"\"egrep\" significa \"grep -E\", \"fgrep\" significa \"grep -F\".\n"
-"L'invocazione diretta come \"egrep\" o \"fgrep\" è deprecata.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "altri, consultare <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "argomento della lunghezza del contesto non valido"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek non riuscita"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "l'input è troppo grande per essere contato"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Il file binario %s corrisponde\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "attenzione: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "ciclo ricorsivo di directory"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
-msgstr "il file di input %s  anche l'output"
+msgstr "il file di input %s è anche l'output"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standard input)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Uso: %s [OPZIONE]... MODELLO [FILE]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Usare \"%s --help\" per ulteriori informazioni.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Cerca il MODELLO in ogni FILE o nello standard input.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"MODELLO è, in modo predefinito, un'espressione regolare di base (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -537,7 +515,7 @@ msgstr ""
 "\n"
 "Selezione e interpretazione delle regexp:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -552,7 +530,7 @@ msgstr ""
 "  -G, --basic-regexp        MODELLO è un'espressione regolare semplice\n"
 "  -P, --perl-regexp         MODELLO è un'espressione regolare Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -573,16 +551,15 @@ msgstr ""
 "che\n"
 "                            newline\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Varie:\n"
@@ -590,9 +567,8 @@ msgstr ""
 "  -v, --invert-match        Seleziona le righe che non corrispondono\n"
 "  -V, --version             Stampa la versione ed esce\n"
 "      --help                Visualizza questo aiuto ed esce\n"
-"      --mmap                Deprecata, stampa un avviso\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -618,7 +594,7 @@ msgstr ""
 "      --label=ETICH         Usa ETICH come nome del file per lo standard "
 "input\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -636,7 +612,7 @@ msgstr ""
 "                            \\\"text\\\" oppure \\\"without-match\\\"\n"
 "  -a, --text                Equivale a --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -658,7 +634,7 @@ msgstr ""
 "                            Simile al precedente, ma segue i collegamenti\n"
 "                            simbolici\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -673,7 +649,7 @@ msgstr ""
 "      --exclude-from=FILE   Salta i file corrispondenti ai modelli nel FILE\n"
 "      --exclude-dir=MODELLO Salta le directory corrispondenti al MODELLO\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -692,7 +668,7 @@ msgstr ""
 "  -T, --initial-tab         Allinea le tabulazioni (se necessario)\n"
 "  -Z, --null                Stampa il byte 0 dopo ogni nome di FILE\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -707,7 +683,7 @@ msgstr ""
 "  -A, --after-context=NUM   Stampa NUM righe di contesto seguente\n"
 "  -C, --context=NUM         Stampa NUM righe di contesto dell'output\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -732,7 +708,16 @@ msgstr ""
 "                            (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"\"egrep\" significa \"grep -E\", \"fgrep\" significa \"grep -F\".\n"
+"L'invocazione diretta come \"egrep\" o \"fgrep\" è deprecata.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -750,47 +735,37 @@ msgstr ""
 "stato\n"
 "è 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Sito web di GNU grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s può usare solamente la sintassi di corrispondenza %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "specificate corrispondenze in conflitto"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "corrispondenza %s non valida"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "metodo per i device sconosciuto"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "numero massimo non valido"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipo di file binario sconosciuto"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "l'opzione --mmap è una no-op dal 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -798,42 +773,60 @@ msgstr ""
 "il supporto all'opzione -P non è compilato in questo binario --disable-perl-"
 "regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "l'opzione -P supporta un solo modello"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "errore interno (non si dovrebbe mai verificare)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "impossibile allocare memoria per lo stack PCRE JIT"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "errore interno"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "limite di lunghezza riga PCRE raggiunto"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "limite di backtrack PCRE raggiunto"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "sequenza byte UTF-8 in ingresso non valida"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "errore interno PCRE: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MODELLO è un'espressione regolare estesa (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "L'invocazione come \"egrep\" è deprecata, usare \"grep -E\".\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "MODELLO è un insieme di stringhe letterali separate da newline.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "L'invocazione come \"fgrep\" è deprecata, usare \"grep -F\".\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s può usare solamente la sintassi di corrispondenza %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "l'opzione --mmap è una no-op dal 2010"
index 954e07e..34b7119 100644 (file)
Binary files a/po/ja.gmo and b/po/ja.gmo differ
index 96c0033..98706a1 100644 (file)
--- a/po/ja.po
+++ b/po/ja.po
@@ -16,7 +16,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep 2.10\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2011-11-19 10:09+0900\n"
 "Last-Translator: Yasuaki Taniguchi <yasuakit@gmail.com>\n"
 "Language-Team: Japanese <translation-team-ja@lists.sourceforge.net>\n"
@@ -40,7 +40,7 @@ msgstr "%2$s に対する引数 %1$s が曖昧です"
 msgid "Valid arguments are:"
 msgstr "有効な引数:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "書き込みエラー"
@@ -104,8 +104,8 @@ msgstr "%s: オプション '-W %s' は引数を取ることができません\n
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: オプション '-W %s' には引数が必要です\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "メモリを使い果たしました"
@@ -189,7 +189,7 @@ msgstr "( または \\( が不一致です"
 msgid "Unmatched \\{"
 msgstr "\\{ が不一致です"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "\\{\\} の中身が無効です"
 
@@ -209,7 +209,7 @@ msgstr "無効な前方正規表現です"
 msgid "Premature end of regular expression"
 msgstr "正規表現が途中で終了しました"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "正規表現が大きすぎます"
 
@@ -366,7 +366,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -395,7 +395,7 @@ msgstr "%s のホームページ: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s のホームページ: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "GNU ソフトウェアを使用する際の一般的なヘルプ: <http://www.gnu.org/gethelp/>\n"
@@ -415,134 +415,104 @@ msgstr "引数 `%3$s' に対して無効な接尾辞 %1$s%2$s です"
 msgid "%s%s argument '%s' too large"
 msgstr "引数 `%3$s' に対する %1$s%2$s が大きすぎます"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "対応がとれていない [ です"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "無効な文字クラス名です"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "文字クラスの構文は [[:space:]] です。 [:space:] ではありません"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "\\ エスケープが終了していません"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "対応がとれていない ( です"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "構文が指定されていません"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "対応がとれていない ) です"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATTERN は拡張正規表現 (ERE) です。\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"`egrep' という名前での起動は廃止予定です。代わりに `grep -E' を使用してくださ"
-"い。\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATTERN は改行で区切られた固定文字列の組です。\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"`fgrep' という名前での起動は廃止予定です。代わりに `grep -F' を使用してくださ"
-"い。\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATTERN はデフォルトでは基本正規表現 (BRE) です。\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' は `grep -E' を意味します。 `fgrep' は `grep -F' を意味します。\n"
-"`egrep' または `fgrep' による直接起動は廃止予定です。\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 "その他の方々は <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS> を参照して"
 "ください"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "一致した前後の行の表示に関する引数が無効です"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek に失敗しました"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "入力が大きすぎて数えられません"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "バイナリファイル %s に一致しました\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "警告: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "ディレクトリーが再帰的ループをしています"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "入力ファイル %s が出力にもなっています"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(標準入力)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "使用法: %s [OPTION]... PATTERN [FILE]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "詳しくは`%s --help'を実行してください。\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "各 FILE または標準入力内の PATTERN を検索します。\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATTERN はデフォルトでは基本正規表現 (BRE) です。\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -553,7 +523,7 @@ msgstr ""
 "\n"
 "正規表現の選択および解釈:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -567,7 +537,7 @@ msgstr ""
 "  -G, --basic-regexp        PATTERN を基本正規表現 (BRE) とする\n"
 "  -P, --perl-regexp         PATTERN を Perl 正規表現とする\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -584,16 +554,15 @@ msgstr ""
 "  -x, --line-regexp         強制的に行全体で PATTERN の一致処理を行う\n"
 "  -z, --null-data           データの行末を改行ではなく NULL とする\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "その他:\n"
@@ -603,7 +572,7 @@ msgstr ""
 "      --help                このヘルプを表示して終了する\n"
 "      --mmap                無視する (後方互換性を保つために存在する)\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -628,7 +597,7 @@ msgstr ""
 "      --label=LABEL         標準入力のファイル名の接頭辞として LABEL を使用す"
 "る\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, fuzzy, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -643,7 +612,7 @@ msgstr ""
 "                            TYPE は `binary'、`text' または `without-match'\n"
 "  -a, --text                --binary-files=text と等価\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, fuzzy, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -661,7 +630,7 @@ msgstr ""
 "                            ACTION は `read' または `skip'\n"
 "  -R, -r, --recursive       --directories=recurse と等価\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -678,7 +647,7 @@ msgstr ""
 "ファイルをスキップする\n"
 "      --exclude-dir=PATTERN  PATTERN に一致したディレクトリをスキップする\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -694,7 +663,7 @@ msgstr ""
 "  -Z, --null                FILE の名前を表示した後に値が 0 のバイトを出力す"
 "る\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -709,7 +678,7 @@ msgstr ""
 "  -A, --after-context=NUM   一致した後の NUM 行を表示する\n"
 "  -C, --context=NUM         一致した前後 NUM 行を表示する\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -731,7 +700,16 @@ msgstr ""
 "  -u, --unix-byte-offsets   CR が無いものとしてオフセットを表示する (MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' は `grep -E' を意味します。 `fgrep' は `grep -F' を意味します。\n"
+"`egrep' または `fgrep' による直接起動は廃止予定です。\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -747,47 +725,37 @@ msgstr ""
 "それ以外は 1 です。エラーが発生して -q を指定していない場合の終了コードは 2\n"
 "になります。\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep のホームページ: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s は %s パターン構文の時のみ使用できます"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "指定した一致処理系が競合しています"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "%s は無効な一致処理系です"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "デバイスに対する不明な操作です"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "無効な一致回数です"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "不明なバイナリファイルの形式です"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -795,46 +763,67 @@ msgstr ""
 "このバイナリは --disable-perl-regexp 付きでコンパイルされているため -P オプ"
 "ションはサポートしません"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P オプションは単一のパターンしかサポートしません"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "内部エラー"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, fuzzy, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "PCRE のバックスラッシュ制限を超過しました"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "PCRE のバックスラッシュ制限を超過しました"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "内部エラー"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATTERN は拡張正規表現 (ERE) です。\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "`egrep' という名前での起動は廃止予定です。代わりに `grep -E' を使用してく"
+#~ "ださい。\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATTERN は改行で区切られた固定文字列の組です。\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "`fgrep' という名前での起動は廃止予定です。代わりに `grep -F' を使用してく"
+#~ "ださい。\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s は %s パターン構文の時のみ使用できます"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "繰返し回数が終了していません"
 
index 6080cf5..ee611e7 100644 (file)
Binary files a/po/ko.gmo and b/po/ko.gmo differ
index eb78883..1c14d6d 100644 (file)
--- a/po/ko.po
+++ b/po/ko.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep 2.0f\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 1997-09-03 11:19+0900\n"
 "Last-Translator: Bang Jun-Young <bangjy@geocities.com>\n"
 "Language-Team: Korean <ko@li.org>\n"
@@ -29,7 +29,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -93,8 +93,8 @@ msgstr "%s: `-W %s' 
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: `%s' ¿É¼ÇÀº Àμö°¡ ÇÊ¿äÇÕ´Ï´Ù\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "¸Þ¸ð¸®°¡ ¹Ù´Ú³²"
@@ -178,7 +178,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -198,7 +198,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -332,7 +332,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -354,7 +354,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -373,130 +373,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "¦ÀÌ ¸ÂÁö ¾Ê´Â ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "¿Ï°áµÇÁö ¾ÊÀº \\ À̽ºÄÉÀÌÇÁ"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "¦ÀÌ ¸ÂÁö ¾Ê´Â ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "¹®¹ýÀÌ ÁöÁ¤µÇÁö ¾Ê¾ÒÀ½"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "¦ÀÌ ¸ÂÁö ¾Ê´Â )"
 
-#: src/egrep.c:16
-#, fuzzy
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "  -E, --extended-regexp     ÆÐÅÏÀº È®Àå Á¤±Ô½ÄÀÌ µË´Ï´Ù\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-#, fuzzy
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "  -G, --basic-regexp        ÆÐÅÏÀº ±âº» Á¤±Ô½ÄÀÌ µË´Ï´Ù\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr ""
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr ""
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr ""
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "%s: °æ°í: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr ""
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(Ç¥ÁØ ÀÔ·Â)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "»ç¿ë¹ý: %s [¿É¼Ç]... ÆÐÅÏ [ÆÄÀÏ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "´õ ¸¹Àº Á¤º¸¸¦ º¸·Á¸é `%s --help' ÇϽʽÿÀ.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, fuzzy, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "  -G, --basic-regexp        ÆÐÅÏÀº ±âº» Á¤±Ô½ÄÀÌ µË´Ï´Ù\n"
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -504,7 +481,7 @@ msgid ""
 "Regexp selection and interpretation:\n"
 msgstr "Á¤±Ô½Ä ¼±Åðú Çؼ®:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -514,7 +491,7 @@ msgid ""
 "  -P, --perl-regexp         PATTERN is a Perl regular expression\n"
 msgstr ""
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -525,19 +502,18 @@ msgid ""
 "  -z, --null-data           a data line ends in 0 byte, not newline\n"
 msgstr ""
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -552,7 +528,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -562,7 +538,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -574,7 +550,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -585,7 +561,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -595,7 +571,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -605,7 +581,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -619,7 +595,14 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -629,92 +612,86 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, fuzzy, c-format
 msgid "conflicting matchers specified"
 msgstr "¦ÀÌ À̹̠ÁöÁ¤µÇ¾úÀ½"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr ""
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr ""
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, fuzzy, c-format
 msgid "invalid max count"
 msgstr "¿Ï°áµÇÁö ¾ÊÀº ¹Ýº¹ È¸¼ö"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr ""
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr ""
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
 
+#, fuzzy
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "  -E, --extended-regexp     ÆÐÅÏÀº È®Àå Á¤±Ô½ÄÀÌ µË´Ï´Ù\n"
+
 #~ msgid "malformed repeat count"
 #~ msgstr "À߸ø ÁÖ¾îÁø ¹Ýº¹ È¸¼ö"
 
index 870912e..5d67142 100644 (file)
Binary files a/po/ky.gmo and b/po/ky.gmo differ
index accdb5e..23d6ccd 100644 (file)
--- a/po/ky.po
+++ b/po/ky.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5.3\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2007-09-01 17:27+0100\n"
 "Last-Translator: Azilet Beishenaliev <aziletb@gmail.com>\n"
 "Language-Team: Kirghiz <i18n-team-ky-kyrgyz@lists.sourceforge.net>\n"
@@ -33,7 +33,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -98,8 +98,8 @@ msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: `%s' опциясы менен аргумент болуш керек\n"
 
 # Памятты эмне дейбиз яя? ;)
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "память жетпей калды"
@@ -183,7 +183,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -204,7 +204,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -338,7 +338,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -364,7 +364,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -383,139 +383,111 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "[ - мунун уйкашы жок"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
 # escape - кыргызча???
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Бүтпөй калган эскейп \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "( - мунун уйкашы жок"
 
 # кайсы синтаксис? грептин шаблонубу?
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Синтаксис аталган жок"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr ") - мунун уйкашы жок"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ШАБЛОН кеңейтилген түрдөгү регулярдуу выражение (ERE).\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"`egrep' деген колдонулбай калды; анын ордуна `grep -E' деп колдонунуз.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "ШАБЛОН ар сапта бир сөз болгон жыйын.\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"`fgrep' деген колдонулбай калды; анын ордуна `grep -F' деп колдонунуз.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"ШАБЛОН, алдынала тандалгандай, негизги түрдөгү регулярдуу выражение (BRE)\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' деген `grep -E'.  `fgrep' деген `grep -F'.\n"
-"`egrep' же `fgrep'  деп туз иштетуу колдонулбай калды.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "контекст узундугу жарабайт"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "берилген данныйлардын саны саналбай турганча көп"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Экилик форматтагы %s файлы уйкашат\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "эскертүү: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "бирибирине кирген папка айлампасы бар"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандарт кирүү)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Колдонулушу: %s [ОПЦИЯ]... ШАБЛОН [ФАЙЛ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Толук маалымат үчүн `%s --help' деп жазгыла.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Ар ФАЙЛда же стандарт кирүүдө ШАБЛОНду изде.\n"
 
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"ШАБЛОН, алдынала тандалгандай, негизги түрдөгү регулярдуу выражение (BRE)\n"
+
 # выражение дегендин кыргызчасын жазыш керек
-#: src/main.c:1550
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -527,7 +499,7 @@ msgstr ""
 "Регулярдуу выражение тандоо жана мааниси:\n"
 
 # выражение - кыргызчасын жаз!!!!
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -542,7 +514,7 @@ msgstr ""
 "  -P, --perl-regexp         ШАБЛОН Perl түрүндөгү регулярдуу выражение\n"
 
 # выражение!!!!
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -560,16 +532,15 @@ msgstr ""
 "  -z, --null-data           дата(данный) саптары 0 байты(EOL эмес) менен "
 "бүтөт\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Түрдүү:\n"
@@ -579,7 +550,7 @@ msgstr ""
 "      --help                бул жардам маалыматын көрсөтүп бүтүрөт\n"
 "      --mmap                мүмкүнчүлүк болсо mmap кирүүсү колдонулат\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -594,7 +565,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -604,7 +575,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -616,7 +587,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -627,7 +598,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -637,7 +608,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -647,7 +618,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -676,7 +647,16 @@ msgstr ""
 "(MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' деген `grep -E'.  `fgrep' деген `grep -F'.\n"
+"`egrep' же `fgrep'  деп туз иштетуу колдонулбай калды.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -690,47 +670,37 @@ msgstr ""
 "статусу 0 болот, башка учурда 1; эгерде ката чыкса жана -q опциясы "
 "берилбеген болсо бүтүрүү статусу 2 болот.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "уйкаштыруучуларда конфликттер табылды"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "максимум сан жарабайт"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "аспап методу белгисиз"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "максимум сан жарабайт"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "белгисиз файл түрү"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 #, fuzzy
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
@@ -738,46 +708,62 @@ msgid ""
 msgstr ""
 "Бул --disable-perl-regexp опциясы менен жасалган, -P опциясы кошулуу эмес"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P опциясы бир гана шаблон ала алат"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ШАБЛОН кеңейтилген түрдөгү регулярдуу выражение (ERE).\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "`egrep' деген колдонулбай калды; анын ордуна `grep -E' деп колдонунуз.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "ШАБЛОН ар сапта бир сөз болгон жыйын.\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "`fgrep' деген колдонулбай калды; анын ордуна `grep -F' деп колдонунуз.\n"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "кайталоо саны толук эмес жазылды"
 
index 71ea502..aabb4ce 100644 (file)
Binary files a/po/lt.gmo and b/po/lt.gmo differ
index fa22fbb..b22a8cf 100644 (file)
--- a/po/lt.po
+++ b/po/lt.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep-2.5.4-pre3\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2008-07-09 13:28+0300\n"
 "Last-Translator: Gintautas Miliauskas <gintas@akl.lt>\n"
 "Language-Team: Lithuanian <komp_lt@konferencijos.lt>\n"
@@ -33,7 +33,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -97,8 +97,8 @@ msgstr "%s: parametras „-W %s“ nepriima argumento\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: parametrui „%s“ reikia argumento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "baigėsi atmintis"
@@ -182,7 +182,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -202,7 +202,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -341,7 +341,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -367,7 +367,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -386,134 +386,108 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Nesubalansuotas ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Nebaigta \\ kaitos seka"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Nesubalansuotas ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Nenurodyta sintaksė"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Nesubalansuotas )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ŠABLONAS yra išplėstinė reguliarioji išraiška (ERE).\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Kvietimas pavadinimu „egrep“ nebenaudotinas, naudokite „grep -E“.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "ŠABLONAS yra aibė simbolių sekų atskirose eilutėse.\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Kvietimas pavadinimu „fgrep“ nebenaudotinas, naudokite „grep -F“.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"ŠABLONAS numatytuoju atveju yra paprasta reguliarioji išraiška (BRE).\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep“ reiškia „grep -E“. „fgrep“ reiškia „grep -F“.\n"
-"Tiesioginiai kvietimai vardais „egrep“ arba „fgrep“ nebenaudotini.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "netaisyklingas konteksto ilgio argumentas"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "įvedimas per didelis skaičiavimui"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Dvejetainis failas %s atitinka\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "įspėjimas: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursyvus aplankų ciklas"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standartinis įvedimas)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Naudojimas: %s [ARGUMENTAS]... ŠABLONAS [FAILAS]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Pabandykite „%s --help“, jei norite gauti daugiau informacijos.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Ieškoti ŠABLONO kiekviename faile arba standartiniame įėjime.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"ŠABLONAS numatytuoju atveju yra paprasta reguliarioji išraiška (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -524,7 +498,7 @@ msgstr ""
 "\n"
 "Reguliariųjų išraiškų parinkimas ir interpretacija:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -540,7 +514,7 @@ msgstr ""
 "(BRE)\n"
 "  -P, --perl-regexp         ŠABLONAS yra Perl reguliarioji išraiška\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -558,16 +532,15 @@ msgstr ""
 "  -z, --null-data           duomenų eilutė baigiasi 0 baitu, o ne nauja "
 "eil.\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Kita:\n"
@@ -577,7 +550,7 @@ msgstr ""
 "      --help                parodyti šią informaciją ir išeiti\n"
 "      --mmap                naudoti mmap įvedimą, jei tai įmanoma\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -592,7 +565,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -602,7 +575,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -614,7 +587,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -625,7 +598,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -635,7 +608,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -645,7 +618,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -672,7 +645,16 @@ msgstr ""
 "(MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep“ reiškia „grep -E“. „fgrep“ reiškia „grep -F“.\n"
+"Tiesioginiai kvietimai vardais „egrep“ arba „fgrep“ nebenaudotini.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -686,47 +668,37 @@ msgstr ""
 "0, jei rasta bent viena eilutė, 1 kitais atvejais;\n"
 "jei įvyksta klaida ir nenurodytas -q, klaidos kodas yra 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "nurodyti nesuderinami atitikimo mechanizmai"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "netaisyklingas maksimalus skaičius"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "nežinomas įrenginių metodas"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "netaisyklingas maksimalus skaičius"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "nežinomas dvejetainių failų tipas"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 #, fuzzy
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
@@ -734,46 +706,60 @@ msgid ""
 msgstr ""
 "Parametro -P palaikymas neįkompiliuotas į šią --disable-perl-regexp programą"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Parametras -P leidžia tik vieną šabloną"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ŠABLONAS yra išplėstinė reguliarioji išraiška (ERE).\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Kvietimas pavadinimu „egrep“ nebenaudotinas, naudokite „grep -E“.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "ŠABLONAS yra aibė simbolių sekų atskirose eilutėse.\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Kvietimas pavadinimu „fgrep“ nebenaudotinas, naudokite „grep -F“.\n"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "nebaigtas pakartojimų skaičius"
 
index 5876253..4988dad 100644 (file)
Binary files a/po/nb.gmo and b/po/nb.gmo differ
index 76c9dfb..ef1a7da 100644 (file)
--- a/po/nb.po
+++ b/po/nb.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep 2.5g\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2004-02-13 23:59+0100\n"
 "Last-Translator: Eivind Tagseth <eivindt@multinet.no>\n"
 "Language-Team: Norwegian Bokmaal <i18n-nb@lister.ping.uio.no>\n"
@@ -30,7 +30,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -94,8 +94,8 @@ msgstr "%s: flagget 
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: flagget «%s» trenger et argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "minnet oppbrukt"
@@ -179,7 +179,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -199,7 +199,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -333,7 +333,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -355,7 +355,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -374,128 +374,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Ubalansert ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Uferdig \\-beskyttelse"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Ubalansert ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Ingen syntaks spesifisert"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Ubalansert )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ugyldig kontekstlengde"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "for mye inndata til å telle"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binær fil %s samsvarer\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "advarsel: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiv katalog-løkke"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standard inn)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Bruk: %s [FLAGG]... MØNSTER [FIL]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Prøv «%s --help» for mer informasjon.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -507,7 +486,7 @@ msgstr ""
 "\n"
 "Regulært utvalg og fortolkning:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -522,7 +501,7 @@ msgstr ""
 "  -G, --basic-regexp        MØNSTER er et grunnleggende regulært uttrykk\n"
 "  -P, --perl-regexp         MØNSTER er et regulært uttrykk på Perl-format\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -541,16 +520,15 @@ msgstr ""
 "  -z, --null-data           en datalinje slutter med en 0-byte, ikke "
 "linjeskift\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diverse:\n"
@@ -560,7 +538,7 @@ msgstr ""
 "      --help                vis denne helpeteksten og avslutt\n"
 "      --mmap                bruk minne-mappet inndata hvis mulig\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -575,7 +553,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -585,7 +563,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -597,7 +575,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -608,7 +586,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -618,7 +596,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -628,7 +606,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -655,7 +633,14 @@ msgstr ""
 "  -u, --unix-byte-offsets   rapporter posisjoner som om CRene ikke var der\n"
 "                            (MSDOS)\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -665,88 +650,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "motsigende søkeuttrykk spesifisert"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "ugyldig maksantall"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "ukjent enhetmetode"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ugyldig maksantall"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "ukjent binærfiltype"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P-flagget er ikke støttet"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 5e7dfa2..b9aad9d 100644 (file)
Binary files a/po/nl.gmo and b/po/nl.gmo differ
index b906e9c..05f5729 100644 (file)
--- a/po/nl.po
+++ b/po/nl.po
@@ -1,20 +1,20 @@
 # Dutch translations for GNU grep.
-# Copyright (C) 2013 Free Software Foundation, Inc.
+# Copyright (C) 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 #
-# "To je najmanje fer igra od svih koje postoje na svijetu."
+# "To je zaista najmanje fer igra od svih koje postoje na svijetu."
 #
-# Benno Schulenberg <benno@vertaalt.nl>, 2005, 2007, 2008, 2010, 2011, 2012, 2013.
+# Benno Schulenberg <benno@vertaalt.nl>, 2005, 2007, 2008, 2010, 2011, 2012, 2013, 2014.
 # Erwin Poeze <erwin.poeze@gmail.com>, 2009.
 # Taco Witte <tcwitte@cs.uu.nl>, 2004.
 # Ivo Timmermans <itimmermans@bigfoot.com>, 2000.
 # Erick Branderhorst <branderh@debian.org>, 1996.
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.15.15\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 10:53+0100\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 21:14+0100\n"
 "Last-Translator: Benno Schulenberg <benno@vertaalt.nl>\n"
 "Language-Team: Dutch <vertaling@vrijschrift.org>\n"
 "Language: nl\n"
@@ -38,7 +38,7 @@ msgstr "argument %s van %s is niet eenduidig"
 msgid "Valid arguments are:"
 msgstr "Geldige argumenten zijn:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "schrijffout"
@@ -102,8 +102,8 @@ msgstr "%s: optie '-W %s' staat geen argument toe\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: optie '-W %s' vereist een argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "onvoldoende geheugen beschikbaar"
@@ -188,7 +188,7 @@ msgstr "Ongepaarde ( of \\("
 msgid "Unmatched \\{"
 msgstr "Ongepaarde \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Ongeldige inhoud van \\{\\}"
 
@@ -208,7 +208,7 @@ msgstr "Ongeldige voorafgaande reguliere expressie"
 msgid "Premature end of regular expression"
 msgstr "Voortijdig einde van reguliere expressie"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Reguliere expressie is te groot"
 
@@ -366,7 +366,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -393,7 +393,7 @@ msgstr "Webpagina van %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Webpagina van %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Algemene hulp bij gebruik van GNU-software: <http://www.gnu.org/gethelp/>\n"
@@ -413,128 +413,102 @@ msgstr "ongeldig achtervoegsel in argument '%3$s' van %1$s%2$s"
 msgid "%s%s argument '%s' too large"
 msgstr "argument '%3$s' van %1$s%2$s is te groot"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "ongepaarde ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "ongeldige tekenklasse"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "syntax van tekenklasse is [[:space:]], niet [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "onafgemaakte \\-stuurcode"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "ongepaarde ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "geen syntax opgegeven"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "ongepaarde )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATROON is een uitgebreide reguliere expressie (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Gebruik van 'egrep' wordt ontraden; het is beter 'grep -E' te gebruiken.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATROON is een serie tekenreeksen, elk op een aparte regel.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Gebruik van 'fgrep' wordt ontraden; het is beter 'grep -F' te gebruiken.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATROON is standaard een gewone reguliere expressie (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Het gebruik van 'egrep' en 'fgrep' wordt ontraden;\n"
-"'egrep' betekent 'grep -E'; 'fgrep' betekent 'grep -F'.\n"
-"\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "anderen, zie <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ongeldig argument voor contextlengte"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "'lseek' is mislukt"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "invoer is te groot om te kunnen tellen"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binair bestand %s bevat de gezochte tekst.\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "waarschuwing: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "oneindige lus in de mappen"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "invoerbestand %s is gelijk aan het uitvoerbestand"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standaardinvoer)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Gebruik:  %s [OPTIE]... PATROON [BESTAND]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Typ '%s --help' voor meer informatie.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
-msgstr "Naar PATROON zoeken in ieder gegeven BESTAND, of in standaardinvoer.\n"
+msgstr "Zoekt naar PATROON in ieder gegeven BESTAND, of in standaardinvoer.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATROON is standaard een gewone reguliere expressie (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -545,7 +519,7 @@ msgstr ""
 "\n"
 "Selectie en interpretatie van reguliere expressies:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -560,7 +534,7 @@ msgstr ""
 "  -G, --basic-regexp        PATROON is een gewone reguliere expressie\n"
 "  -P, --perl-regexp         PATROON is een reguliere Perl-expressie\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -580,16 +554,15 @@ msgstr ""
 "regel\n"
 "  -z, --null-data           regels eindigen op 0-byte, niet op LF-teken\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diversen:\n"
@@ -597,9 +570,8 @@ msgstr ""
 "  -v, --invert-match        de niet-overeenkomende regels selecteren\n"
 "  -V, --version             programmaversie tonen en stoppen\n"
 "      --help                deze hulptekst tonen en stoppen\n"
-"      --mmap                (doet niets, behalve hiervoor waarschuwen)\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -624,7 +596,7 @@ msgstr ""
 "      --label=LABEL         dit LABEL als naam voor standaardinvoer "
 "gebruiken\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -643,7 +615,7 @@ msgstr ""
 "overeenkomsten)\n"
 "  -a, --text                hetzelfde als '--binary-files=text'\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -667,7 +639,7 @@ msgstr ""
 "  -R, --dereference-recursive   idem, maar alle symbolische koppelingen "
 "volgen\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -686,7 +658,7 @@ msgstr ""
 "                                   BESTAND voldoen\n"
 "      --exclude-dir=PATROON      mappen overslaan die aan PATROON voldoen\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -703,7 +675,7 @@ msgstr ""
 "invoegen)\n"
 "  -Z, --null                een 0-byte invoegen na iedere bestandsnaam\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -719,7 +691,7 @@ msgstr ""
 "  -A, --after-context=AANTAL    dit AANTAL regels nakomende context tonen\n"
 "  -C, --context=AANTAL          dit AANTAL regels context tonen\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -744,7 +716,17 @@ msgstr ""
 "Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Het gebruik van 'egrep' en 'fgrep' wordt ontraden;\n"
+"'egrep' betekent 'grep -E'; 'fgrep' betekent 'grep -F'.\n"
+"\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -760,93 +742,103 @@ msgstr ""
 "De afsluitwaarde is 0 in geval van overeenkomsten, anders 1; als er\n"
 "een fout optreedt en '-q' is niet gegeven, dan is de afsluitwaarde 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Webpagina van GNU grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s kan alleen de patroonsyntax %s gebruiken"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "conflicterende expressiesoorten"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ongeldige expressiesoort '%s'"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "onbekende apparaten-actie"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ongeldig maximum aantal"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "onbekend binair bestandstype"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "de optie '--mmap' doet niets meer sinds 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "ondersteuning voor de optie '-P' is in deze programmaversie niet opgenomen"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "optie '-P' accepteert slechts één patroon"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "**interne programmafout** (zou nooit mogen gebeuren)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "onvoldoende geheugen beschikbaar voor de PCRE-JIT-stack"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "**interne programmafout**"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "regellengtegrens van PCRE is overschreden"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "terugverwijzingsgrens van PCRE is overschreden"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "ongeldige UTF-8-bytereeks in invoer"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "**interne programmafout** in PCRE: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATROON is een uitgebreide reguliere expressie (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Gebruik van 'egrep' wordt ontraden; het is beter 'grep -E' te gebruiken.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATROON is een serie tekenreeksen, elk op een aparte regel.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Gebruik van 'fgrep' wordt ontraden; het is beter 'grep -F' te gebruiken.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s kan alleen de patroonsyntax %s gebruiken"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "de optie '--mmap' doet niets meer sinds 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "onafgemaakt herhalingsaantal"
 
index 7e4664b..706de4e 100644 (file)
Binary files a/po/pa.gmo and b/po/pa.gmo differ
index 37f9d0a..42daf53 100644 (file)
--- a/po/pa.po
+++ b/po/pa.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.11.11-pre1\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-05-19 17:52+0530\n"
 "Last-Translator: A S Alam <aalam@users.sf.net>\n"
 "Language-Team: Punjabi <punjabi-l10n@lists.sourceforge.net>\n"
@@ -32,7 +32,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr "ਠੀਕ ਆਰਗੂਮੈਂਟ ਹਨ:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "ਲਿਖਣ ਗਲਤੀ"
@@ -96,8 +96,8 @@ msgstr "%s: ਚੋਣ '-W %s' ਲਈ ਕੋਈ ਆਰਗੂਮੈਂਟ ਨਹ
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr ""
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "ਮੈਮੋਰੀ ਖਤਮ ਹੋਈ"
@@ -181,7 +181,7 @@ msgstr "ਨਾ ਮਿਲਦੇ ( ਜਾਂ \\("
 msgid "Unmatched \\{"
 msgstr "ਨਾ-ਮਿਲਦੇ \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -201,7 +201,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "ਨਿਯਮਤ ਸਮੀਕਰਨ ਬਹੁਤ ਵੱਡੀ ਹੈ"
 
@@ -352,7 +352,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -376,7 +376,7 @@ msgstr "%s ਮੁੱਖ ਪੇਜ਼: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s ਮੁੱਖ ਪੇਜ਼: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "ਗਨੂ ਸਾਫਟਵੇਅਰ ਦੀ ਵਰਤੋਂ ਲਈ ਆਮ ਮੱਦਦ ਵਾਸਤੇ: <http://www.gnu.org/gethelp/>\n"
 
@@ -395,123 +395,102 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s ਆਰਗੂਮੈਂਟ '%s' ਬਹੁਤ ਵੱਡਾ ਹੈ"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "ਅਧੂਰੀ ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "ਗਲਤ ਕਰੈਕਟਰ ਕਲਾਸ"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr ""
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "ਅਧੂਰੀ ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "ਕੋਈ ਸੰਟੈਕਸ ਨਹੀਂ ਦਿੱਤਾ"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "ਅਧੂਰੀ )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ਪੈਟਰਨ ਇੱਕ ਵਾਧੂ ਨਿਯਮਤ ਸਮੀਕਰਨ ਹੈ (ERE) ਹੈ।\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "ਪੈਟਰਨ (PATTERN) ਮੂਲ ਰੂਪ ਵਿੱਚ ਇੱਕ ਨਿਯਮਤ ਸਕਰੀਨ (BRE) ਹੁੰਦਾ ਹੈ।\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "ਮਾਈਕ ਹਾਇਰਟੇਲ"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "ਹੋਰਾਂ ਲਈ <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS> ਵੇਖੋ"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr ""
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek ਫੇਲ੍ਹ ਹੈ"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "ਇੰਪੁੱਟ ਗਿਣਤੀ ਕਰਨ ਲਈ ਬਹੁਤ ਵੱਡੀ ਹੈ"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "ਬਾਈਨਰੀ ਫਾਇਲ %s ਮਿਲਦੀ ਹੈ\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "ਸਾਵਧਾਨ: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "ਲਗਾਤਾਰ ਡਾਇਰੈਕਟਰੀ ਲੂਪ"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "ਇੰਪੁੱਟ ਫਾਇਲ %s ਆਉਟਪੁੱਟ ਫਾਇਲ ਵੀ ਹੈ"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(ਸਟੈਂਡਰਡ ਆਉਟਪੁੱਟ)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "ਵਰਤੋਂ: %s [ਚੋਣਾਂ]... ਪੈਟਰਨ [ਫਾਇਲ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "ਹੋਰ ਜਾਣਕਾਰੀ ਲਈ '%s --help' ਨਾਲ ਕੋਸ਼ਿਸ਼ ਕਰੋ।\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "ਹਰੇਕ ਫਾਇਲ (FILE) ਜਾਂ ਸਟੈਂਡਰਡ ਆਉਟਪੁੱਟ ਲਈ ਪੈਟਰਨ ਦੀ ਖੋਜ।\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "ਪੈਟਰਨ (PATTERN) ਮੂਲ ਰੂਪ ਵਿੱਚ ਇੱਕ ਨਿਯਮਤ ਸਕਰੀਨ (BRE) ਹੁੰਦਾ ਹੈ।\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -522,7 +501,7 @@ msgstr ""
 "\n"
 "ਨਿਯਮਤ-ਸਮੀਕਰਨ (Regexp) ਚੋਣ ਅਤੇ ਚਲਾਉਣਾ:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -532,7 +511,7 @@ msgid ""
 "  -P, --perl-regexp         PATTERN is a Perl regular expression\n"
 msgstr ""
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -543,19 +522,18 @@ msgid ""
 "  -z, --null-data           a data line ends in 0 byte, not newline\n"
 msgstr ""
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -570,7 +548,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -580,7 +558,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -592,7 +570,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -603,7 +581,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -613,7 +591,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -623,7 +601,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -637,7 +615,14 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -647,88 +632,81 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "ਗਨੂ Grep ਮੁੱਖ ਪੇਜ਼: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr ""
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ਗਲਤ ਮੈਚਰ %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "ਅਣਜਾਣ ਜੰਤਰ ਢੰਗ"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ਗਲਤ ਵੱਧ ਤੋਂ ਵੱਧ ਗਿਣਤੀ"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "ਅਣਜਾਣ ਬਾਈਨਰੀ-ਫਾਇਲ ਕਿਸਮ"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr ""
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "ਅੰਦਰੂਨੀ ਗਲਤੀ"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "ਅੰਦਰੂਨੀ ਗਲਤੀ"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ਪੈਟਰਨ ਇੱਕ ਵਾਧੂ ਨਿਯਮਤ ਸਮੀਕਰਨ ਹੈ (ERE) ਹੈ।\n"
index 443a174..40486f5 100644 (file)
Binary files a/po/pl.gmo and b/po/pl.gmo differ
index 510805b..95b3055 100644 (file)
--- a/po/pl.po
+++ b/po/pl.po
@@ -1,13 +1,13 @@
 # Polish translation of the GNU grep messages
-# Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
+# Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
-# Rafał Maszkowski <rzm@icm.edu.pl>, 1996-2002, 2005, 2007-2013.
+# Rafał Maszkowski <rzm@icm.edu.pl>, 1996-2002, 2005, 2007-2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.15.15\n"
+"Project-Id-Version: GNU grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-23 10:45+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-12 18:00+0200\n"
 "Last-Translator: Rafał Maszkowski <rzm@icm.edu.pl>\n"
 "Language-Team: Polish <translation-team-pl@lists.sourceforge.net>\n"
 "Language: pl\n"
@@ -29,7 +29,7 @@ msgstr "dwuznaczny argument %s dla %s"
 msgid "Valid arguments are:"
 msgstr "Prawidłowe agrumenty to:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "błąd zapisu"
@@ -93,8 +93,8 @@ msgstr "%s: opcja '-W %s' nie może mieć argumentu\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opcja '-W %s' wymaga argumentu\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "pamięć wyczerpana"
@@ -178,7 +178,7 @@ msgstr "Nie pasujący ( albo \\("
 msgid "Unmatched \\{"
 msgstr "Nie pasujący \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Błędna zawartość \\{\\}"
 
@@ -198,7 +198,7 @@ msgstr "Błędne poprzedzające wyrażenie regularne"
 msgid "Premature end of regular expression"
 msgstr "Przedwczesny koniec wyrażenia regularnego"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Za duże wyrażenie regularne"
 
@@ -354,7 +354,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -378,7 +378,7 @@ msgstr "Strona domowa %s: %s\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Strona domowa %s: http://www.gnu.org/software/%s/\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Pomoc w używaniu oprogramowania GNU: http://www.gnu.org/gethelp/\n"
 
@@ -397,125 +397,102 @@ msgstr "błędny przyrostek w argumencie %s%s '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "argument %s%s '%s' jest za duży"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ nie do pary"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "błędna nazwa klasy znaków"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "składnia klasy znaków to [[:space:]], nie [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "niedokończona sekwencja \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( nie do pary"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "brak specyfikacji składni"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") nie do pary"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "WZORZEC jest rozszerzonym wyrażeniem regularnym (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Wywołanie jako `egrep' jest przestarzałe, używaj 'grep -E'.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "WZORZEC jest zbiorem łańcuchów znaków w kolejnych liniach.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Wywołanie jako `fgrep' jest przestarzałe, używaj 'grep -F'.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "WZORZEC domyślnie jest podstawowym wyrażeniem regularnym (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"`egrep' oznacza 'grep -E'. `fgrep' oznacza 'grep -F'.\n"
-"Używanie nazw 'egrep' i 'fgrep' jest przestarzałe.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike'a Haertela"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "innych, zobacz: http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "błędny argument długości kontekstowej"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "błąd lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "danych wejściowych jest zbyt dużo do policzenia"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Plik binarny %s pasuje do wzorca\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "uwaga: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "nieskończona pętla przeglądania katalogów"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "plik wejściowy %s jest również plikiem wyjściowym"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standardowe wejście)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Składnia: %s [OPCJA]... WZORZEC [PLIK] ...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Napisz '%s --help' żeby dowiedzieć się więcej.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Szukanie WZORCA w każdym PLIKU lub na standardowym wejściu\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "WZORZEC domyślnie jest podstawowym wyrażeniem regularnym (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -526,7 +503,7 @@ msgstr ""
 "\n"
 "Wybór i interpretacja wyrażeń regularnych:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -540,7 +517,7 @@ msgstr ""
 "  -G, --basic-regexp        WZORZEC jest podstawowym wyr. regularnym (BRE)\n"
 "  -P, --perl-regexp         WZORZEC jest wyrażeniem regularnym perla\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -558,26 +535,25 @@ msgstr ""
 "  -z, --null-data           linie są zakończone bajtem 0, nie znakiem\n"
 "                            nowej linii\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Różne:\n"
 "  -s, --no-messages         bez komunikatów o błędach\n"
-"  -v, --invert-match        wybierz linie nie pasujące\n"
-"  -V, --version             wypisz informację o wersji i zakończ\n"
-"      --help                wyświetl tę informację i zakończ\n"
-"      --mmap                przestarzałe; włącza ostrzeżenie\n"
+"  -v, --invert-match        wybranie nie pasujących linii\n"
+"  -V, --version             wypisanie informacji o wersji i zakończenie\n"
+"      --help                wypisanie tych informacji i zakończenie\n"
+"\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -601,7 +577,7 @@ msgstr ""
 "  -h, --no-filename         bez nazwy pliku w liniach wyjściowych\n"
 "      --label=ETYKIETA      w wyniku ETYKIETA zastępuje nazwe pliku\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -616,7 +592,7 @@ msgstr ""
 "                            TYP to 'binary', 'text' lub 'without-match'.\n"
 "  -a, --text                równoważne --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -639,7 +615,7 @@ msgstr ""
 "  -R, --dereference-recursive  podobnie, ale z podążaniem za dowiązaniami\n"
 "                              symbolicznymi\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -654,7 +630,7 @@ msgstr ""
 "      --exclude-from=PLIK   pominięcie plików pasujących do WZORCÓW w PLIKU\n"
 "      --exclude-dir=WZORZEC  katalogi pasujące do WZORCA będą pominięte\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -670,7 +646,7 @@ msgstr ""
 "  -T, --initial-tab         wyrównanie linii przez TAB (jeżeli potrzebne)\n"
 "  -Z, --null                wypisanie bajtu 0 po każdej nazwie PLIKU\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -685,7 +661,7 @@ msgstr ""
 "  -A, --after-context=ILE   wypisanie ILU linii kontekstu po\n"
 "  -C, --context=ILE         wypisanie ILU linii kontekstu\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -709,7 +685,16 @@ msgstr ""
 "                              (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"`egrep' oznacza 'grep -E'. `fgrep' oznacza 'grep -F'.\n"
+"Używanie nazw 'egrep' i 'fgrep' jest przestarzałe.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -726,16 +711,11 @@ msgstr ""
 "jeżeli\n"
 "nie; z 2, w razie błędów, gdy nie podano opcji -q.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Strona domowa Grepa GNU: %s\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s może użyć tylko składni wzorców %s"
-
 #  viendo los fuentes , hay varias opciones
 #  que hay sin documentar. O quiza es que getopt() lo he entendido mal
 #  Son las opciones X ( requiere argumento ) , switchs  -c, -b, -L e -y
@@ -744,79 +724,74 @@ msgstr "%s może użyć tylko składni wzorców %s"
 #  grep --help ->
 #  usage: grep [-[[AB] ]<num>] [-[CEFGVchilnqsvwx]] [-[ef]] <expr> [<files...>]
 #  La opción -X es a la que corresponde esta línea.
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "podane sprzeczne wzorce"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "błędna dopasowanie %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "nieznany sposób przeglądania urządzeń"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "błędna maksymalna liczba powtórzeń"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "nieznany typ pliku binarnego"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "opcja --mmap nie robi niczego od 2010 r."
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "program skompilowany bez opcji -P poprzez włączenie --disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "opcja -P może być użyta tylko do pojedynczego wzorca"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "błąd wewnętrzny (nigdy nie powinien się zdarzyć)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "nie udało się zaalokować pamięci dla stosu PCRE JIT"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "błąd wewnętrzny"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "przekroczony limit długości linii PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "przekroczony limit analizy wstecznej PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "błędna sekencje UTF-8 na wejściu"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "błąd wewnętrzny PCRE: %d"
index 4688ae9..b44d2ef 100644 (file)
Binary files a/po/pt.gmo and b/po/pt.gmo differ
index a764be1..41e2462 100644 (file)
--- a/po/pt.po
+++ b/po/pt.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5g\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2003-04-09 00:07+0100\n"
 "Last-Translator: Rui Malheiro <rmalheiro@6mil.pt>\n"
 "Language-Team: Portuguese <translation-team-pt@lists.sourceforge.net>\n"
@@ -30,7 +30,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -94,8 +94,8 @@ msgstr "%s: a opção `-W %s' não aceita um argumento\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "\"%s: a opção `%s' exige um argumento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memória esgotada"
@@ -179,7 +179,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -199,7 +199,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -333,7 +333,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -355,7 +355,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -374,128 +374,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "[ sem correspondência"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "\\ não terminado"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "( sem correspondência"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Sintaxe não especificada"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr ") sem correspondência"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "número de linhas de contexto inválido"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "ficheiro demasiado grande para manter contagem"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Padrão encontrado no ficheiro binário %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "aviso: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "directoria em ciclo recursivo"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standard input)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Utilização: %s [OPÇÃO]... PADRÃO [FICHEIRO]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Experimente `%s --help' para mais informação.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -507,7 +486,7 @@ msgstr ""
 "\n"
 "Selecção e interpretação de regexp\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -522,7 +501,7 @@ msgstr ""
 "  -G, --basic-regexp        PADRÃO é uma expressão regular básica\n"
 "  -P, --perl-regexp         PADRÃO é uma expressão regular de Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -543,16 +522,15 @@ msgstr ""
 "  -z, --null-data           uma linha é terminada com o byte 0, não com "
 "newline\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Miscellaneous:\\n\"\n"
@@ -562,7 +540,7 @@ msgstr ""
 "      --help                apresenta este texto de auxílio e termina\n"
 "      --mmap                utilizar 'memory-mapped input' se possível\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -577,7 +555,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -587,7 +565,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -599,7 +577,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -610,7 +588,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -620,7 +598,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -630,7 +608,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -665,7 +643,14 @@ msgstr ""
 "dois FICHEIROS, assume -h. Devolve 0 se encontrar pelo menos uma occorência\n"
 "de PADRÃO, 1 se não encontrar, 2 se tiver algum problema.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -675,88 +660,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "foram especificados métodos de pesquisa incompatíveis"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "número máximo inválido"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "método para acesso a «devices» desconhecido"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "número máximo inválido"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipo de ficheiro binário desconhecido"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "A opção -P não é suportada"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index ca04400..358f217 100644 (file)
Binary files a/po/pt_BR.gmo and b/po/pt_BR.gmo differ
index 935d96c..8296a6d 100644 (file)
@@ -13,7 +13,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: GNU grep-2.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-11-04 15:09-0200\n"
 "Last-Translator: Rodolfo Ribeiro Gomes <rodolforg@gmail.com>\n"
 "Language-Team: Brazilian Portuguese <ldpbr-translation@lists.sourceforge."
@@ -38,7 +38,7 @@ msgstr "%s é um argumento ambíguo para %s"
 msgid "Valid arguments are:"
 msgstr "Os argumentos válidos são:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "erro de escrita"
@@ -102,8 +102,8 @@ msgstr "%s: a opção \"-W %s\" não aceita argumentos\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: a opção \"-W %s\" requer um argumento\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memória esgotada"
@@ -187,7 +187,7 @@ msgstr "( ou \\( sem correspondente"
 msgid "Unmatched \\{"
 msgstr "\\{ sem correspondente"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Conteúdo inválido de \\{\\}"
 
@@ -207,7 +207,7 @@ msgstr "Expressão regular precedente é inválida"
 msgid "Premature end of regular expression"
 msgstr "Fim prematuro da expressão regular"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Expressão regular grande demais"
 
@@ -364,7 +364,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -388,7 +388,7 @@ msgstr "página de %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "página de %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Ajuda geral sobre uso de software GNU: <http://www.gnu.org/gethelp/>\n"
 
@@ -407,126 +407,102 @@ msgstr "sufixo inválido no argumento para %s%s: \"%s\""
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s: argumento \"%s\" é grande demais"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ sem correspondente"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "categoria de caracteres inválida"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "a sintaxe de categoria de caracteres é [[:space:]], e não [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "escape \\ não terminado"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( sem correspondente"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "nenhuma sintaxe especificada"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") sem correspondente"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PADRÃO é uma expressão regular estendida (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Invocar como \"egrep\" está obsoleto; use \"grep -E\".\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"PADRÃO é um conjunto de textos fixos separados por caractere de nova linha.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Invocar como \"fgrep\" está obsoleto; use \"grep -F\".\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PADRÃO é, por padrão, uma expressão regular básica (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"\"egrep\" significa \"grep -E\". \"fgrep\" significa \"grep -F\".\n"
-"A invocação direta tanto por \"egrep\" como por \"fgrep\" está obsoleta.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "outros, veja <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "argumento inválido para comprimento do contexto"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "a movimentação pelo arquivo (lseek) falhou"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "entrada longa demais para contar"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Arquivo binário %s coincide com o padrão\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "aviso: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "recursão cíclica de diretório"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "o arquivo de entrada %s é também o de saída"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(entrada padrão)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Uso: %s [OPÇÃO]... PADRÃO [ARQUIVO]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Experimente \"%s --help\" para mais informações.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Busca por PADRÃO em cada ARQUIVO ou entrada padrão.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PADRÃO é, por padrão, uma expressão regular básica (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -537,7 +513,7 @@ msgstr ""
 "\n"
 "Seleção e interpretação de expressão regular:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -551,7 +527,7 @@ msgstr ""
 "  -G, --basic-regexp        PADRÃO é uma expressão regular básica\n"
 "  -P, --perl-regexp         PADRÃO é uma expressão regular de sintaxe Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -571,16 +547,15 @@ msgstr ""
 "com\n"
 "                              caractere de nova linha\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Miscelânea:\n"
@@ -590,7 +565,7 @@ msgstr ""
 "      --help                exibe esta ajuda e sai\n"
 "      --mmap                obsoleta e inútil; emite um aviso\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -614,7 +589,7 @@ msgstr ""
 "  -h, --no-filename         inibe o nome de arquivo na saída\n"
 "      --label=RÓTULO        usa RÓTULO para identificar a entrada padrão\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -632,7 +607,7 @@ msgstr ""
 "                             ou \\\"without-match\\\" (nunca coincide)\n"
 "  -a, --text                equivalente a --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -655,7 +630,7 @@ msgstr ""
 "  -R, --dereference-recursive  similar, mas segue todas as ligações "
 "simbólicas\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -674,7 +649,7 @@ msgstr ""
 "                              em ARQUIvo\n"
 "      --exclude-dir=PADRÃO  diretórios que casam com PADRÃO serão ignorados\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -695,7 +670,7 @@ msgstr ""
 "  -T, --initial-tab         alinha por tabulação (se necessário)\n"
 "  -Z, --null                emite byte 0 depois do nome do ARQUIVO\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -710,7 +685,7 @@ msgstr ""
 "  -A, --after-context=NÚM   emite NÚM linhas de contexto posteriores\n"
 "  -C, --context=NÚM         emite NÚM linhas de contexto de saída\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -736,7 +711,16 @@ msgstr ""
 "                              (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"\"egrep\" significa \"grep -E\". \"fgrep\" significa \"grep -F\".\n"
+"A invocação direta tanto por \"egrep\" como por \"fgrep\" está obsoleta.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -754,93 +738,103 @@ msgstr ""
 "foi\n"
 "especificado, o estado de saída é 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Página do GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s só pode usar a sintaxe de padrão %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "especificou-se padrões de busca conflitantes"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "comparador inválido %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "método desconhecido de dispositivos"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "valor máximo inválido"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tipo de arquivo binário desconhecido"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "a opção --mmap não faz nada desde 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "o suporte à opção -P não foi compilado neste binário --disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "a opção -P só oferece suporte a apenas um único padrão"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "erro interno"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "atingiu o limite de comprimento de linha das PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "atingiu o limite de backtracking das PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "erro interno"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PADRÃO é uma expressão regular estendida (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Invocar como \"egrep\" está obsoleto; use \"grep -E\".\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "PADRÃO é um conjunto de textos fixos separados por caractere de nova "
+#~ "linha.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Invocar como \"fgrep\" está obsoleto; use \"grep -F\".\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s só pode usar a sintaxe de padrão %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "a opção --mmap não faz nada desde 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "contador de repetição não terminado"
 
index c965921..ce5a4c8 100644 (file)
Binary files a/po/ro.gmo and b/po/ro.gmo differ
index c9146eb..7a65483 100644 (file)
--- a/po/ro.po
+++ b/po/ro.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep-2.5g.ro\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2003-04-19 02:47+0000\n"
 "Last-Translator: Eugen Hoanca <eugenh@urban-grafx.ro>\n"
 "Language-Team: Romanian <translation-team-ro@lists.sourceforge.net>\n"
@@ -30,7 +30,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -94,8 +94,8 @@ msgstr "%s: op
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: opþiunea `%s' necesitã un parametru\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "memorie plinã"
@@ -179,7 +179,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -199,7 +199,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -333,7 +333,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -355,7 +355,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -374,128 +374,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "[ fãrã pereche"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "\\ escape neterminat"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "( fãrã pereche"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Nu s-a specificat sintaxa"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr ") fãra pereche"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "parametru lungime context invalid"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "intrarea(input) este prea mare pentru numãrare"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Fiºierul binar %s corespunde\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "avertisment: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "buclã recursivã de directoare"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(intrare standard)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Folosire: %s [OPÞIUNE]... TIPAR [FIªIER]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Încercaþi `%s --help' pentru mai multe informaþii.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -507,7 +486,7 @@ msgstr ""
 "\n"
 "Selecþie ºi interpretare regexp:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -522,7 +501,7 @@ msgstr ""
 "  -G, --basic-regexp       TIPAR este o expresie exactã primarã\n"
 "  -P, --perl-regexp        TIPAR este o expresie exactã Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -542,16 +521,15 @@ msgstr ""
 "  -z, --null-data           linia de date se terminã în octet 0, nu "
 "linie_nouã\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diverse:\n"
@@ -561,7 +539,7 @@ msgstr ""
 "      --help                afiºeazã acest ajutor ºi terminã\n"
 "      --mmap                foloseºte intrare memory-mapped dacã e posibil\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -576,7 +554,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -586,7 +564,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -598,7 +576,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -609,7 +587,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -619,7 +597,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -629,7 +607,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -662,7 +640,14 @@ msgstr ""
 "mai puþin de 2 FIªIERe, se presupune -h. Starea de ieºire e 0 pentru\n"
 "corespunzãtor, 1 pentru necorespunzãtor, ºi 2 pentru probleme.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -672,88 +657,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "conflicte între cãutãtorii (matchers) specificaþi"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "numãrare maximã invalidã"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "metodã dispozitive(devices) necunoscutã"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "numãrare maximã invalidã"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "tip fiºiere-binare necunoscut"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "Opþiunea -P nu este suportatã"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 7e2f940..f3e39a6 100644 (file)
Binary files a/po/ru.gmo and b/po/ru.gmo differ
index 9e10792..0457b4d 100644 (file)
--- a/po/ru.po
+++ b/po/ru.po
@@ -4,20 +4,20 @@
 # This file is distributed under the same license as the grep package.
 #
 # Denis Perchine <dyp@perchine.com>, 1998-2000.
-# Yuri Kozlov <yuray@komyakino.ru>, 2009, 2010, 2011, 2012, 2013.
+# Yuri Kozlov <yuray@komyakino.ru>, 2009, 2010, 2011, 2012, 2013, 2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: grep 2.15.15\n"
+"Project-Id-Version: grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-29 12:58+0400\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 18:52+0400\n"
 "Last-Translator: Yuri Kozlov <yuray@komyakino.ru>\n"
 "Language-Team: Russian <gnu@mx.ru>\n"
 "Language: ru\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Lokalize 1.4\n"
+"X-Generator: Lokalize 1.5\n"
 "Plural-Forms:  nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
 "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
 
@@ -35,7 +35,7 @@ msgstr "двусмысленный аргумент %s для %s"
 msgid "Valid arguments are:"
 msgstr "Допустимые аргументы:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "ошибка записи"
@@ -99,8 +99,8 @@ msgstr "%s: у параметра «-W %s» не может быть аргум
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: для параметра «-W %s» требуется аргумент\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "память исчерпана"
@@ -184,7 +184,7 @@ msgstr "Непарная ( или \\("
 msgid "Unmatched \\{"
 msgstr "Непарная \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Неправильное содержимое в \\{\\}"
 
@@ -204,7 +204,7 @@ msgstr "Неправильное предшествующее регулярно
 msgid "Premature end of regular expression"
 msgstr "Преждевременное завершение регулярного выражения"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Регулярное выражение слишком большое"
 
@@ -361,7 +361,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -386,7 +386,7 @@ msgstr "Домашняя страница %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Домашняя страница %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Справка по работе с программами GNU: <http://www.gnu.org/gethelp/>\n"
 
@@ -405,131 +405,103 @@ msgstr "недопустимый суффикс в аргументе %s%s дл
 msgid "%s%s argument '%s' too large"
 msgstr "аргумент %s%s слишком велик для «%s»"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "несбалансированная ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "неправильный класс символов"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "синтаксис класса символов: [[:space:]], а не [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "незавершённая \\ экранирующая последовательность"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "несбалансированная ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "не указан синтаксис"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "несбалансированная )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ШАБЛОН представляет собой расширенное регулярное выражение (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Запуск под именем «egrep» устарел; вместо этого используйте «grep -E».\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"ШАБЛОН представляет строки фиксированной длины, разделённые символом новой "
-"строки.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Запуск под именем «fgrep» устарел; вместо этого используйте «grep -F».\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-"По умолчанию, ШАБЛОН представляет собой простое регулярное выражение (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Вместо «egrep» предполагается запуск «grep -E». Вместо «fgrep» "
-"предполагается\n"
-"«grep -F». Запуск под именами «egrep» или «fgrep» лучше не выполнять.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Майк Хертель (Mike Haertel)"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "другие, см. <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "неверный аргумент длины контекста"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "Вызов lseek завершился неудачно"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "входные данные слишком велики, чтобы сосчитать"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Двоичный файл %s совпадает\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "предупреждение: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "каталоги зациклены"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "файл ввода %s также используется и для вывода"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандартный ввод)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Использование: %s [ПАРАМЕТР]… ШАБЛОН [ФАЙЛ]…\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Запустите «%s --help» для получения более подробного описания.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Поиск ШАБЛОНА в каждом ФАЙЛЕ или в стандартном вводе.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+"По умолчанию, ШАБЛОН представляет собой простое регулярное выражение (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -540,7 +512,7 @@ msgstr ""
 "\n"
 "Выбор типа регулярного выражения и его интерпретация:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -556,7 +528,7 @@ msgstr ""
 "  -G, --basic-regexp        ШАБЛОН - простое регулярное выражение (BRE)\n"
 "  -P, --perl-regexp         ШАБЛОН - регулярное выражения языка Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -575,28 +547,24 @@ msgstr ""
 "не\n"
 "                            символом конца строки\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Разное:\n"
-"  -s, --no-messages         Ð¿Ð¾Ð´Ð°Ð²Ð»Ñ\8fть сообщения об ошибках\n"
+"  -s, --no-messages         Ð½Ðµ Ð¿Ð¾ÐºÐ°Ð·Ñ\8bвать сообщения об ошибках\n"
 "  -v, --invert-match        выбирать не подходящие строки\n"
-"  -V, --version             напечатать информацию о версии и закончить "
-"работу\n"
+"  -V, --version             показать информацию о версии и закончить работу\n"
 "      --help                показать эту справку и закончить работу\n"
-"      --mmap                устарел, ничего не делается; показ "
-"предупреждения\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -623,7 +591,7 @@ msgstr ""
 "      --label=МЕТКА         использовать МЕТКУ в качестве имени файла для\n"
 "                            стандартного ввода\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -639,7 +607,7 @@ msgstr ""
 "                            «binary», «text» или «without-match».\n"
 "  -a, --text                то же что и --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -660,7 +628,7 @@ msgstr ""
 "  -R, --dereference-recursive                             тоже, но с "
 "переходом по всем символьным ссылкам\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -679,7 +647,7 @@ msgstr ""
 "      --exclude-dir=ШАБЛОН  каталоги, подпадающие под ШАБЛОН,\n"
 "                            будут пропущены\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -695,7 +663,7 @@ msgstr ""
 "  -T, --initial-tab         выравнивать табуляцией (если нужно)\n"
 "  -Z, --null                печатать байт 0 после имени ФАЙЛА\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -710,7 +678,7 @@ msgstr ""
 "  -A, --after-context=ЧИС   печатать ЧИСЛО строк последующего контекста\n"
 "  -C, --context[=ЧИС]       печатать ЧИСЛО строк контекста\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -734,7 +702,17 @@ msgstr ""
 "Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Вместо «egrep» предполагается запуск «grep -E». Вместо «fgrep» "
+"предполагается\n"
+"«grep -F». Запуск под именами «egrep» или «fgrep» лучше не выполнять.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -750,48 +728,37 @@ msgstr ""
 "0, и 1, если ничего не совпало. При возникновении ошибок и если не указан\n"
 "параметр -q, кодом завершения будет 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Домашняя страница GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "В %s можно использовать только шаблонный синтаксис %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "заданы конфликтующие образцы"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "неверный образец %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "неизвестный метод для устройств"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "неверное максимальное количество совпадений"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "неизвестный тип двоичных файлов"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-"начиная с 2010 года при указании параметра --mmap ничего не выполняется"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -799,46 +766,69 @@ msgstr ""
 "поддержка параметра -P не включена при компиляции данного исполняемого файла "
 "(--disable-perl-regexp)"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "параметр -P поддерживает только одиночный шаблон"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "внутренняя ошибка (не должна возникать)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "ошибка выделения памяти для стека PCRE JIT"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "внутренняя ошибка"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "превышено ограничение длины строки PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "исчерпан лимит в PCRE по возврату"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "недопустимая последовательность байтов UTF-8 во входных данных"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "внутренняя ошибка PCRE: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ШАБЛОН представляет собой расширенное регулярное выражение (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Запуск под именем «egrep» устарел; вместо этого используйте «grep -E».\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "ШАБЛОН представляет строки фиксированной длины, разделённые символом "
+#~ "новой строки.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Запуск под именем «fgrep» устарел; вместо этого используйте «grep -F».\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "В %s можно использовать только шаблонный синтаксис %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr ""
+#~ "начиная с 2010 года при указании параметра --mmap ничего не выполняется"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "незавершённое количество повторений"
 
index 773a9c9..6d331d8 100644 (file)
Binary files a/po/sk.gmo and b/po/sk.gmo differ
index b0b4e8a..a282490 100644 (file)
--- a/po/sk.po
+++ b/po/sk.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.13.16-pre1\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-08-17 13:52+0100\n"
 "Last-Translator: Ivan Masár <helix84@centrum.sk>\n"
 "Language-Team: Slovak <sk-i18n@lists.linux.sk>\n"
@@ -30,7 +30,7 @@ msgstr "nejednoznačný argument %s pre %s"
 msgid "Valid arguments are:"
 msgstr "Platné argumentu sú:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "chyba zápisu"
@@ -94,8 +94,8 @@ msgstr "%s: voľba „-W %s“ nepripúšťa argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: voľba „-W %s“ vyžaduje argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "pamäť bola vyčerpaná"
@@ -179,7 +179,7 @@ msgstr "( alebo \\( bez náprotivku."
 msgid "Unmatched \\{"
 msgstr "\\{ bez náprotivku."
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Neplatný obsah \\{\\}"
 
@@ -199,7 +199,7 @@ msgstr "Neplatný predošlý regulárny výraz"
 msgid "Premature end of regular expression"
 msgstr "Neplatný koniec regulárneho výrazu"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regulárny výraz je príliš veľký"
 
@@ -356,7 +356,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -380,7 +380,7 @@ msgstr "Domovská stránka %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Domovská stránka %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Všeobecná pomoc pri používaní softvéru GNU: <http://www.gnu.org/gethelp/>\n"
@@ -400,129 +400,102 @@ msgstr "neplatná prípona v argumente %s%s „%s“"
 msgid "%s%s argument '%s' too large"
 msgstr "argument %s%s „%s“ je príliš veľký"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "[ bez náprotivku"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "neplatná trieda znakov"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "syntax triedy znakov je [[:space:]], nie [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "nedokončená úniková klauzula \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( bez náprotivku"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "neuvedená syntax"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") bez náprotivku"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "VZORKA je rozšírený regulárny výraz (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Vyvolanie príkazu ako „egrep“ sa neodporúča; použite namiesto toho „grep -"
-"E“.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "VZORKA je množina pevných reťazcov oddelených znakom nového riadka.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Vyvolanie príkazu ako „fgrep“ sa neodporúča; použite namiesto toho „grep -"
-"F“.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "VZORKA je štandardne základný regulárny výraz (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep“ znamená „grep -E“. „fgrep“ znamená „grep -F“.\n"
-"Priame vyvolanie príkazu ako „egrep“ či „fgrep“ sa neodporúča.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "iní, pozri <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "neplatný argument dĺžky kontextu"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "nepodarilo sa vykonať lseek()"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "vstup je príliš veľký, aby sa dal spočítať"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Zhody v binárnom súbore %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "upozornenie: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekurzívna slučka v adresári"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "vstupný súbor %s je tiež uvedený ako výstupný"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(štandardný vstup)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Použitie: %s [VOĽBA]... VZORKA [SÚBOR]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Ďalšie informácie získate príkazom „%s --help“.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Hľadať VZORKU v každom SÚBORE alebo na štandardnom vstupe.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "VZORKA je štandardne základný regulárny výraz (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -533,7 +506,7 @@ msgstr ""
 "\n"
 "Výber a interpretácia regulárneho výrazu:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -548,7 +521,7 @@ msgstr ""
 "  -G, --basic-regexp        VZORKA je základný regulárny výraz (BRE)\n"
 "  -P, --perl-regexp         VZORKA je perlovský regulárny výraz\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -567,16 +540,15 @@ msgstr ""
 "riadkom\n"
 "  -z, --null-data           údaje končia bajtom 0, nie novým riadkom\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Rozličné:\n"
@@ -587,7 +559,7 @@ msgstr ""
 "      --mmap                zavrhovaný príkaz, ktorý nič nerobí, vyvolá "
 "upozornenie\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -612,7 +584,7 @@ msgstr ""
 "      --label=NÁVESTIE      vypísať NÁVESTIE ako názov súboru pre štand. "
 "vstup\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -629,7 +601,7 @@ msgstr ""
 "match“\n"
 "  -a, --text                ekvivalentné s --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -650,7 +622,7 @@ msgstr ""
 "  -r, --recursive           ekvivalentné s --directories=recurse\n"
 "  -R, --dereference-recursive  podobné, ale nasleduje symbolické odkazy\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -669,7 +641,7 @@ msgstr ""
 "                              súboru zo SÚBORU\n"
 "      --exclude-dir=VZOR      preskočiť adresáre, ktoré zodpovedajú VZORu\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -685,7 +657,7 @@ msgstr ""
 "  -T, --initial-tab         zarovnávať tabulátory (ak je to potrebné)\n"
 "  -Z, --null                vypísať za názvom SÚBORu bajt 0\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -700,7 +672,7 @@ msgstr ""
 "  -A, --after-context=POČ   vytlačiť POČ riadkov kontextu za\n"
 "  -C, --context=POČ         vytlačiť POČ riadkov kontextu výstupu\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -723,7 +695,16 @@ msgstr ""
 "                            znaky CR (MSDOS)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep“ znamená „grep -E“. „fgrep“ znamená „grep -F“.\n"
+"Priame vyvolanie príkazu ako „egrep“ či „fgrep“ sa neodporúča.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -738,93 +719,106 @@ msgstr ""
 "Chybová úroveň je 0 ak bol vybraný nejaký riadok a 1 inak;\n"
 "ak sa vyskytne nejaká chyba a nebolo zadané -q, chybová úroveň je 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Domovská stránka GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s môže používať iba syntax vzorky %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "boli zadané konfliktné špecifikátory"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "neplatný zástupný znak %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "neznáme metódy zariadení"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "neplatný maximálny počet"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "neznámy typ binárneho súboru"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "voľba --mmap nič nerobí od roku 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "podpora voľby -P nie je zakompilovaná do tejto binárky --disable-perl-regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "voľba -P podporuje iba jedinú vzorku"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "vnútorná chyba"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "prekročený limit dĺžky riadka PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "prekročený limit backtrackingu PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "vnútorná chyba"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "VZORKA je rozšírený regulárny výraz (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Vyvolanie príkazu ako „egrep“ sa neodporúča; použite namiesto toho „grep -"
+#~ "E“.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "VZORKA je množina pevných reťazcov oddelených znakom nového riadka.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Vyvolanie príkazu ako „fgrep“ sa neodporúča; použite namiesto toho „grep -"
+#~ "F“.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s môže používať iba syntax vzorky %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "voľba --mmap nič nerobí od roku 2010"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "Nedokončený počet opakovaní"
 
index bab3663..9b36724 100644 (file)
Binary files a/po/sl.gmo and b/po/sl.gmo differ
index d1945f6..9f16a30 100644 (file)
--- a/po/sl.po
+++ b/po/sl.po
@@ -1,16 +1,16 @@
 # -*- mode: po; coding: utf-8; -*- Slovenian message catalogue for grep
-# Copyright (C) 1996, 1999, 2000, 2007, 2008, 2009, 2011, 2012, 2013 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1999, 2000, 2007, 2008, 2009, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
-# Primož Peterlin <primozz.peterlin@gmail.com>, 1996, 1999, 2000, 2007, 2008, 2009, 2011, 2012, 2013.
+# Primož Peterlin <primozz.peterlin@gmail.com>, 1996, 1999, 2000, 2007, 2008, 2009, 2011, 2012, 2013, 2014.
 #
-# $Id: grep-2.15.15.sl.po,v 1.2 2013/12/22 21:30:32 peterlin Exp $
+# $Id: grep-2.18.143.sl.po,v 1.1 2014/05/18 20:42:06 peterlin Exp $
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: GNU grep 2.15.15\n"
+"Project-Id-Version: GNU grep 2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 22:30+0100\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-18 22:42+0200\n"
 "Last-Translator: Primož Peterlin <primozz.peterlin@gmail.com>\n"
 "Language-Team: Slovenian <translation-team-sl@lists.sourceforge.net>\n"
 "Language: sl\n"
@@ -34,7 +34,7 @@ msgstr "dvoumni argument %s za %s"
 msgid "Valid arguments are:"
 msgstr "Veljavni argumenti so:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "napaka pri pisanju"
@@ -98,8 +98,8 @@ msgstr "%s: izbira »-W %s« ne dovoljuje argumenta\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: izbira »-W %s« zahteva argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "pomnilnik porabljen"
@@ -183,7 +183,7 @@ msgstr "Uklepaj ( ali \\( brez para"
 msgid "Unmatched \\{"
 msgstr "Uklepaj \\{ brez para"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Neveljavna vsebina \\{\\}"
 
@@ -203,7 +203,7 @@ msgstr "Neveljaven predhodni regularni izraz"
 msgid "Premature end of regular expression"
 msgstr "Predčasen zaključek regularnega izraza"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Regularni izraz je preobsežen"
 
@@ -359,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -386,7 +386,7 @@ msgstr "Spletna stran %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Spletna stran %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Splošna pomoč za rabo programja GNU: <http://www.gnu.org/gethelp/>\n"
 
@@ -405,127 +405,102 @@ msgstr "neveljavna pripona pri %s%s argumentu '%s'"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s: argument '%s' je prevelik"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "uklepaj [ brez zaklepaja"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "neveljavno ime razreda znakov"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "skladnja imena razreda znakov je [[:space:]], ne [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "nedokončano ubežno zaporedje \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "uklepaj ( brez zaklepaja"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "skladnja ni podana"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "zaklepaj ) brez uklepaja"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "VZOREC je razširjeni regularni izraz (RRI).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Raba ukaza »egrep« je odsvetovana; namesto njega uporabite »grep -E«.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "VZOREC je množica nespremenljivih nizov, po eden v vrstici.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Raba ukaza »fgrep« je odsvetovana; namesto njega uporabite »grep -F«.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "VZOREC je privzeto osnovni regularni izraz (ORI).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"Ukaz »egrep« pomeni isto kot »grep -E«, »fgrep« pa isto kot  »grep -F«.\n"
-"Neposredna raba ukazov »egrep« ali »fgrep« je odsvetovana.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "drugi, glejte <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "velikost konteksta ni veljavna"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "klic lseek ni uspel"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "vhod je prevelik, da bi ga mogli prešteti"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binarna datoteka %s ustreza\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "opozorilo: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekurzivna zanka imenikov"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "vhodna datoteka %s je tudi izhodna"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standardni vhod)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Uporaba: %s [IZBIRA]... VZOREC [DATOTEKA]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Poskusite  »%s --help« za dodatna pojasnila.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "V DATOTEKI ali na standardnem vhodu se išče VZOREC.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "VZOREC je privzeto osnovni regularni izraz (ORI).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -536,7 +511,7 @@ msgstr ""
 "\n"
 "Izbira in tolmačenje regularnih izrazov:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -550,7 +525,7 @@ msgstr ""
 "  -G, --basic-regexp        VZOREC je osnovni regularni izraz (ORI)\n"
 "  -P, --perl-regexp         VZOREC je regularni izraz z razširitvami perla\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -568,16 +543,15 @@ msgstr ""
 "  -z, --null-data           vrstica podatkov je končana z znakom NUL, ne z\n"
 "                            znakom za skok v novo vrstico\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Razno:\n"
@@ -585,9 +559,8 @@ msgstr ""
 "  -v, --invert-match        izberi vrstice, ki se ne ujemajo\n"
 "  -V, --version             verzija programa\n"
 "      --help                ta pomoč\n"
-"      --mmap                brez učinka; izpiše opozorilo\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -612,7 +585,7 @@ msgstr ""
 "      --label=OZNAKA        z navedeno OZNAKO, kadar beremo s standardnega "
 "vhoda\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -628,7 +601,7 @@ msgstr ""
 "match«\n"
 "  -a, --text                isto kot --binary-type=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -648,7 +621,7 @@ msgstr ""
 "  -R, --dereference-recursive  podobno, vendar s sledenjem vseh simbolnih \n"
 "                               povezav\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -664,7 +637,7 @@ msgstr ""
 "DATOTEKI\n"
 "      --exclude-dir=VZOREC  izpusti imenike, ki ustrezajo VZORCU\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -682,7 +655,7 @@ msgstr ""
 "  -T, --initial-tab         dodaj začetni tabulator (če je potrebno)\n"
 "  -Z, --null                izpiši znak NUL za imenom DATOTEKE\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -698,7 +671,7 @@ msgstr ""
 "  -C, --context=ŠT          ŠT vrstic konteksta pred in za vrstico z "
 "VZORCEM\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -720,7 +693,16 @@ msgstr ""
 "  -u, --unix-byte-offsets   v odmikih ne štejemo znakov CR (MS-DOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"Ukaz »egrep« pomeni isto kot »grep -E«, »fgrep« pa isto kot  »grep -F«.\n"
+"Neposredna raba ukazov »egrep« ali »fgrep« je odsvetovana.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -735,52 +717,42 @@ msgstr ""
 "»-h«. Izhodna koda je 0 ob vsaj eni vrstici zadetka, sicer pa 1; če je\n"
 "prišlo do napake in ni bila podana izbira -q, program vrne kodo 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Spletna stran GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s lahko uporablja le skladnjo vzorcev %s"
-
 #  Sporočilo se pojavi pri nedokumentirani izbiri -X
 #  grep.c:622 ->
 #  opt = getopt(argc, argv, "0123456789A:B:CEFGVX:bce:f:hiLlnqsvwxy"
 #  grep --help ->
 #  usage: grep [-[[AB] ]<num>] [-[CEFGVchilnqsvwx]] [-[ef]] <expr> [<files...>]
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "podana navodila si nasprotujejo"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "neveljaven ujemalnik %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "neznana metoda datotek naprav"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "neveljavno največje število"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "neznan tip binarne datoteke"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "izbira --mmap je neaktivna od leta 2010 "
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -788,46 +760,66 @@ msgstr ""
 "podpora za izbiro -P ni bila vključena v ta prevedeni program (--disable-"
 "perl-regexp)"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "izbira -P podpira le en vzorec"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "interna napaka (to tega ne bi smelo priti)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "pomnilnika za sklad PCRE JIT se ni uspelo dodeliti"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "interna napaka"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "prekoračena meja PCRE za dolžino vrstice"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "prekoračena meja PCRE za iskanje s povratnim sledenjem"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "neveljavno zaporedje bajtov UTF-8 na vhodu"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "interna napaka PCRE: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "VZOREC je razširjeni regularni izraz (RRI).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Raba ukaza »egrep« je odsvetovana; namesto njega uporabite »grep -E«.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "VZOREC je množica nespremenljivih nizov, po eden v vrstici.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Raba ukaza »fgrep« je odsvetovana; namesto njega uporabite »grep -F«.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s lahko uporablja le skladnjo vzorcev %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "izbira --mmap je neaktivna od leta 2010 "
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "nedokončano število ponovitev"
 
index ee0c5a5..5594c5f 100644 (file)
Binary files a/po/sr.gmo and b/po/sr.gmo differ
index 94d62d7..296779a 100644 (file)
--- a/po/sr.po
+++ b/po/sr.po
@@ -2,13 +2,13 @@
 # Copyright (C) 2012 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 # Danilo Segan <dsegan@gmx.net>, 2003.
-# Мирослав Николић <miroslavnikolic@rocketmail.com>, 2011, 2012, 2013.
+# Мирослав Николић <miroslavnikolic@rocketmail.com>, 2011—2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.14.46\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-10-27 11:58+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-12 21:31+0200\n"
 "Last-Translator: Мирослав Николић <miroslavnikolic@rocketmail.com>\n"
 "Language-Team: Serbian <(nothing)>\n"
 "Language: sr\n"
@@ -32,10 +32,10 @@ msgstr "двосмислени аргумент %s за %s"
 msgid "Valid arguments are:"
 msgstr "Исправни аргументи су:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
-msgstr "грешка у писању"
+msgstr "грешка писања"
 
 #: lib/error.c:188
 msgid "Unknown system error"
@@ -96,8 +96,8 @@ msgstr "%s: опција „-W %s“ не дозвољава аргумент\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: опција „-W %s“ захтева аргумент\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "меморија је потрошена"
@@ -181,7 +181,7 @@ msgstr "Не одговара ( или \\("
 msgid "Unmatched \\{"
 msgstr "Не одговара \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Неисправан садржај \\{\\}"
 
@@ -202,7 +202,7 @@ msgstr "Неисправан регуларан израз који претхо
 msgid "Premature end of regular expression"
 msgstr "Прерани крај регуларног израза"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Регуларни израз је превелик"
 
@@ -359,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -383,7 +383,7 @@ msgstr "%s матична страница: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s матична страница: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Општа помоћ користећи ГНУ софтвер: <http://www.gnu.org/gethelp/>\n"
 
@@ -402,125 +402,102 @@ msgstr "неисправан суфикс у %s%s аргументу „%s“"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s аргумент „%s“ је превелик"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "неуравнотежена ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "неисправна класа знака"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "синтакса класе знака је [[:размак:]], а не [:размак:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "недовршена \\ излазим"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "неуравнотежена ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "синтакса није наведена"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "неуравнотежена )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ШАБЛОН је проширени регуларан израз (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Позив као „egrep“ није одобрен; користите „grep -E“ уместо тога.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "ШАБЛОН је скуп сталних низова у новим редовима.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Позив као „fgrep“ није одобрен; користите „grep -F“ уместо тога.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "ШАБЛОН је, по основи, основни регуларан израз (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"„egrep“ значи „grep -E“.  „fgrep“ значи „grep -F“.\n"
-"Директно призивање као „egrep“ или „fgrep“ није одобрено.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Мајк Хартел"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "остали, погледајте <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "неисправан аргумент дужине контекста"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "„lseek“ није успело"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "улаз је превелик за пребројавање"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Бинарна датотека %s одговара\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "упозорење: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "рекурзивно вртење кроз директоријуме"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "улазна датотека %s је такође излаз"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандардни улаз)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Употреба: %s [ОПЦИЈА]... ШАБЛОН [ДАТОТЕКА]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Пробајте „%s --help“ за више података.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Тражи наведени ШАБЛОН у свакој датотеци или стандардном улазу.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "ШАБЛОН је, по основи, основни регуларан израз (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -531,7 +508,7 @@ msgstr ""
 "\n"
 "Избор регуларних израза и обрада:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -546,7 +523,7 @@ msgstr ""
 "  -G, --basic-regexp              ШАБЛОН је основни регуларан израз\n"
 "  -P, --perl-regexp               ШАБЛОН је Перлов регуларан израз\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -566,16 +543,15 @@ msgstr ""
 "  -z, --null-data                 ред података се завршава 0-бајтом, не "
 "новим редом\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Разно:\n"
@@ -583,9 +559,8 @@ msgstr ""
 "  -v, --invert-match              бира не-одговарајуће редове\n"
 "  -V, --version                   исписује податке о издању и излази\n"
 "      --help                      приказује ову помоћ и излази\n"
-"      --mmap                      занемарено; призива упозорење\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -612,7 +587,7 @@ msgstr ""
 "      --label=НАТПИС              користи НАТПИС као префикс назива датотеке "
 "стандардног улаза\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -629,7 +604,7 @@ msgstr ""
 "„without-match“\n"
 "  -a, --text                      исто као и „--binary-files=text“\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -650,7 +625,7 @@ msgstr ""
 "  -r, --recursive                 исто као и „--directories=recurse“\n"
 "  -R, --dereference-recursive     слично, али прати све симболичке везе\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -669,7 +644,7 @@ msgstr ""
 "      --exclude-dir=ШАБЛОН        директоријуми који се поклапају са "
 "ШАБЛОНОМ биће прескочени.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -687,7 +662,7 @@ msgstr ""
 "  -T, --initial-tab               помера табове ред горе (ако је потребно)\n"
 "  -Z, --null                      исписује 0-ти бајт након назива ДАТОТЕКЕ\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -702,7 +677,7 @@ msgstr ""
 "  -A, --after-context=БРОЈ        исписује БРОЈ редова пратећег контекста\n"
 "  -C, --context=БРОЈ              исписује БРОЈ редова излазног контекста\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -727,7 +702,16 @@ msgstr ""
 "били ту (МСДОС/Виндоуз)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"„egrep“ значи „grep -E“.  „fgrep“ значи „grep -F“.\n"
+"Директно призивање као „egrep“ или „fgrep“ није одобрено.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -742,89 +726,94 @@ msgstr ""
 "Излазно стање је 0 ако је изабран неки ред, у супротном 1;\n"
 "ако је дошло до неке грешке а „-q“ није дато, онда је излазно стање 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Матична страница ГНУ Грепа: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s може да користи само %s синтаксу шаблона"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "наведени су трагачи у сукобу"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "неисправан трагач %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "непознат метод уређаја"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "неисправан највећи број"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "непозната врста бинарних датотека"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "„--mmap“ опција је била без опције од 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 "подршка за „-P“ опцију није преведена у овој „--disable-perl-regexp“ извршној"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "опција „-P“ подржава само самосталне шаблоне"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "унутрашња грешка (не треба никада да се деси)"
 
-#: src/pcresearch.c:130
-#, fuzzy, c-format
+#: src/pcresearch.c:120
+#, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
-msgstr "Ð\9dе Ð¼Ð¾Ð³Ñ\83 Ð´Ð° Ð´Ð¾Ð´ÐµÐ»Ð¸Ð¼ Ð¼ÐµÐ¼Ð¾Ñ\80иÑ\98Ñ\83 Ð·Ð° Ð\8fÐ\98Т Ñ\81Ñ\82ок"
+msgstr "ниÑ\81ам Ñ\83Ñ\81пео Ð´Ð° Ð´Ð¾Ð´ÐµÐ»Ð¸Ð¼ Ð¼ÐµÐ¼Ð¾Ñ\80иÑ\98Ñ\83 Ð·Ð° Ð\9fЦРÐ\95 Ð\8fÐ\98Т Ñ\81Ñ\82ек"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "унутрашња грешка"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "прекорачено је ограничење дужине реда ПЦРЕ-а"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "прекорачено је ПЦРЕ-ово ограничење тражења уназад"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
-msgstr ""
+msgstr "неисправан низ УТФ-8 бита у улазу"
 
-#: src/pcresearch.c:206
-#, fuzzy, c-format
+#: src/pcresearch.c:192
+#, c-format
 msgid "internal PCRE error: %d"
-msgstr "унутрашња грешка"
+msgstr "унутрашња грешка ПЦРЕ-а: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ШАБЛОН је проширени регуларан израз (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Позив као „egrep“ није одобрен; користите „grep -E“ уместо тога.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "ШАБЛОН је скуп сталних низова у новим редовима.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Позив као „fgrep“ није одобрен; користите „grep -F“ уместо тога.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s може да користи само %s синтаксу шаблона"
index 0d95173..bd16db1 100644 (file)
Binary files a/po/sv.gmo and b/po/sv.gmo differ
index ee2c973..7ef7ef5 100644 (file)
--- a/po/sv.po
+++ b/po/sv.po
@@ -9,7 +9,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.10\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2011-11-21 08:51+0100\n"
 "Last-Translator: Daniel Nylander <po@danielnylander.se>\n"
 "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
@@ -32,7 +32,7 @@ msgstr "tvetydligt argument %s för %s"
 msgid "Valid arguments are:"
 msgstr "Giltiga argument är:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "skrivfel"
@@ -96,8 +96,8 @@ msgstr "%s: flaggan \"-W %s\" tillåter inget argument\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: flaggan \"-W %s\" behöver ett argument\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "minnet är slut"
@@ -185,7 +185,7 @@ msgstr "Omatchad ( eller \\("
 msgid "Unmatched \\{"
 msgstr "Omatchad \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Ogiltigt innehåll i \\{\\}"
 
@@ -205,7 +205,7 @@ msgstr "Ogiltigt inledande reguljärt uttryck"
 msgid "Premature end of regular expression"
 msgstr "För tidigt slut på reguljärt uttryck"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Reguljärt uttryck är för stort"
 
@@ -362,7 +362,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -389,7 +389,7 @@ msgstr "Webbplats för %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Webbplats för %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "Allmän hjälp för GNU-programvara: <http://www.gnu.org/gethelp/>\n"
 
@@ -408,128 +408,102 @@ msgstr "ogiltigt suffix i %s%s-argumentet \"%s\""
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s-argumentet \"%s\" är för stort"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "obalanserad ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "ogiltig teckenklass"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "syntax för teckenklass är [[:space:]], inte [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "oavslutad \\-sekvens"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "obalanserad ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "ingen syntax angiven"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "obalanserad )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MÖNSTER är ett utökat reguljärt uttryck (ERE).\n"
-
-#: src/egrep.c:18
-#, fuzzy
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Körning som \"egrep\" är föråldrat; använd \"grep -E\" istället.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "MÖNSTER är en uppsättning nyradsseparerade fasta strängar.\n"
-
-#: src/fgrep.c:12
-#, fuzzy
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Körning som \"fgrep\" är föråldrat; använd \"grep -F\" istället.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MÖNSTER är, som standard, ett enkelt reguljärt uttryck (BRE).\n"
-
-#: src/grep.c:34
-#, fuzzy
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"\"egrep\" betyder \"grep -E\".  \"fgrep\" betyder \"grep -F\".\n"
-"Direktanrop som antingen \"egrep\" eller \"fgrep\" är föråldrat.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "andra, se <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ogiltigt argument till -A, -B eller -C"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek misslyckades"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "det är för mycket indata för att räkna"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Binär fil %s matchar\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "varning: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "rekursiv katalogloop"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "inmatningsfilen %s är även utmatningen"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standard in)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Användning: %s [FLAGGA]... MÖNSTER [FIL]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Försök med \"%s --help\" för mer information\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "Sök efter MÖNSTER i varje FIL eller standard in.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MÖNSTER är, som standard, ett enkelt reguljärt uttryck (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -540,7 +514,7 @@ msgstr ""
 "\n"
 "Val och tolkning av reguljära uttryck:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -555,7 +529,7 @@ msgstr ""
 " -G, --basic-regexp         MÖNSTER är ett enkelt reguljärt uttryck (BRE)\n"
 " -P, --perl-regexp          MÖNSTER är ett reguljärt uttryck som i Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -572,16 +546,15 @@ msgstr ""
 " -x, --line-regexp          tvinga MÖNSTER att endast matcha hela rader\n"
 " -z, --null-data            en datarad slutar i 0 byte, inte nyradstecken\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Diverse:\n"
@@ -591,7 +564,7 @@ msgstr ""
 "      --help                visa detta hjälpmeddelande och avsluta\n"
 "      --mmap                ignoreras för bakåtkompatibilitet\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -616,7 +589,7 @@ msgstr ""
 "      --label=ETIKETT       skriv ut ETIKETT som filnamnsprefix för standard "
 "in\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, fuzzy, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -633,7 +606,7 @@ msgstr ""
 "match\"\n"
 "  -a, --text                samma som --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, fuzzy, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -651,7 +624,7 @@ msgstr ""
 "                            ÅTGÄRD är \"read\" eller \"skip\"\n"
 "  -R, -r, --recursive       samma som --directories=recurse\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -668,7 +641,7 @@ msgstr ""
 "FIL\n"
 "      --exclude-dir=MÖNSTER kataloger som matchar MÖNSTER hoppas över.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -687,7 +660,7 @@ msgstr ""
 "behövs)\n"
 "  -Z, --null                skriv ut 0-tecken efter FILnamn\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -702,7 +675,7 @@ msgstr ""
 "  -A, --after-context=ANTAL  skriv ANTAL rader efter träffad rad\n"
 "  -C, --context=ANTAL        skriv ANTAL rader runt träffad rad\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -724,7 +697,16 @@ msgstr ""
 "  -u, --unix-byte-offsets   skriv offset som om CR-tecken inte förekommit\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, fuzzy, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"\"egrep\" betyder \"grep -E\".  \"fgrep\" betyder \"grep -F\".\n"
+"Direktanrop som antingen \"egrep\" eller \"fgrep\" är föråldrat.\n"
+
+#: src/grep.c:1619
 #, fuzzy, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -738,47 +720,37 @@ msgstr ""
 "anges, anta -h.  Avslutningsstatus är 0 om någon rad valdes, annars 1;\n"
 "om något fel inträffar och -q inte angavs, är avslutningsstatusen 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Webbplats för GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s kan endast använda %s-mönstersyntax"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "motstridiga söksträngar angivna"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ogiltig matchning %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "okänd metod för enheter"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ogiltigt värde för antal träffar"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "okänd binärfiltyp"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -786,46 +758,63 @@ msgstr ""
 "stöd för flaggan -P är inte inbyggd i den här binären med --disable-perl-"
 "regexp"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "flaggan -P har endast stöd för ett mönster"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "internt fel"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, fuzzy, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "översteg gräns för PCRE-bakåtspårning"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "översteg gräns för PCRE-bakåtspårning"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "internt fel"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MÖNSTER är ett utökat reguljärt uttryck (ERE).\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Körning som \"egrep\" är föråldrat; använd \"grep -E\" istället.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "MÖNSTER är en uppsättning nyradsseparerade fasta strängar.\n"
+
+#, fuzzy
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Körning som \"fgrep\" är föråldrat; använd \"grep -F\" istället.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s kan endast använda %s-mönstersyntax"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "oavslutad repetitionsräknare"
 
index 4c771fa..43cf6c3 100644 (file)
Binary files a/po/th.gmo and b/po/th.gmo differ
index 706cdfd..94c0370 100644 (file)
--- a/po/th.po
+++ b/po/th.po
@@ -1,14 +1,14 @@
 # Translation of grep messages to Thai.
-# Copyright (C) 2013 Free Software Foundation, Inc.
+# Copyright (C) 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
-# Seksan Poltree <seksan.poltree@gmail.com>, 2009-2013.
+# Seksan Poltree <seksan.poltree@gmail.com>, 2009-2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.15.15\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-24 01:26+0700\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-12 19:49+0700\n"
 "Last-Translator: Seksan Poltree <seksan.poltree@gmail.com>\n"
 "Language-Team: Thai <translation-team-th@lists.sourceforge.net>\n"
 "Language: th\n"
@@ -31,7 +31,7 @@ msgstr "อาร์กิวเมนต์ %s กำกวมไม่ชั
 msgid "Valid arguments are:"
 msgstr "อาร์กิวเมนต์ที่ถูกต้องได้แก่:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "การเขียนผิดพลาด"
@@ -43,60 +43,60 @@ msgstr "ข้อผิดพลาดของระบบที่ไม่ร
 #: lib/getopt.c:547 lib/getopt.c:576
 #, c-format
 msgid "%s: option '%s' is ambiguous; possibilities:"
-msgstr "%s: ตัวเลือก '%s' คลุมเครือไม่ชัดเจน; เป็นไปได้ที่จะเป็น:"
+msgstr "%s: ตัวเลือก ‘%s’ คลุมเครือไม่ชัดเจน; เป็นไปได้ที่จะเป็น:"
 
 #: lib/getopt.c:624 lib/getopt.c:628
 #, c-format
 msgid "%s: option '--%s' doesn't allow an argument\n"
-msgstr "%s: ตัวเลือก '--%s' ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
+msgstr "%s: ตัวเลือก ‘—%s’ ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
 
 #: lib/getopt.c:637 lib/getopt.c:642
 #, c-format
 msgid "%s: option '%c%s' doesn't allow an argument\n"
-msgstr "%s: ตัวเลือก '%c%s' ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
+msgstr "%s: ตัวเลือก ‘%c%s’ ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
 
 #: lib/getopt.c:685 lib/getopt.c:704
 #, c-format
 msgid "%s: option '--%s' requires an argument\n"
-msgstr "%s: ตัวเลือก '--%s' ต้องการอาร์กิวเมนต์\n"
+msgstr "%s: ตัวเลือก ‘—%s’ ต้องการอาร์กิวเมนต์\n"
 
 #: lib/getopt.c:742 lib/getopt.c:745
 #, c-format
 msgid "%s: unrecognized option '--%s'\n"
-msgstr "%s: ตัวเลือกที่ไม่รู้จัก '--%s'\n"
+msgstr "%s: ตัวเลือกที่ไม่รู้จัก ‘—%s’\n"
 
 #: lib/getopt.c:753 lib/getopt.c:756
 #, c-format
 msgid "%s: unrecognized option '%c%s'\n"
-msgstr "%s: ตัวเลือกที่ไม่รู้จัก '%c%s'\n"
+msgstr "%s: ตัวเลือกที่ไม่รู้จัก ‘%c%s’\n"
 
 #: lib/getopt.c:805 lib/getopt.c:808
 #, c-format
 msgid "%s: invalid option -- '%c'\n"
-msgstr "%s: ตัวเลือกไม่ถูกต้อง -- '%c'\n"
+msgstr "%s: ตัวเลือกไม่ถูกต้อง — ‘%c’\n"
 
 #: lib/getopt.c:861 lib/getopt.c:878 lib/getopt.c:1088 lib/getopt.c:1106
 #, c-format
 msgid "%s: option requires an argument -- '%c'\n"
-msgstr "%s: ตัวเลือกต้องการอาร์กิวเมนต์ -- '%c'\n"
+msgstr "%s: ตัวเลือกต้องการอาร์กิวเมนต์ — ‘%c’\n"
 
 #: lib/getopt.c:934 lib/getopt.c:950
 #, c-format
 msgid "%s: option '-W %s' is ambiguous\n"
-msgstr "%s: ตัวเลือก '-W %s' คลุมเครือไม่ชัดเจน\n"
+msgstr "%s: ตัวเลือก ‘-W %s’ คลุมเครือไม่ชัดเจน\n"
 
 #: lib/getopt.c:974 lib/getopt.c:992
 #, c-format
 msgid "%s: option '-W %s' doesn't allow an argument\n"
-msgstr "%s: ตัวเลือก '-W %s' ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
+msgstr "%s: ตัวเลือก ‘-W %s’ ไม่อนุญาตให้มีอาร์กิวเมนต์\n"
 
 #: lib/getopt.c:1013 lib/getopt.c:1031
 #, c-format
 msgid "%s: option '-W %s' requires an argument\n"
-msgstr "%s: ตัวเลือก '-W %s' ต้องการอาร์กิวเมนต์\n"
+msgstr "%s: ตัวเลือก ‘-W %s’ ต้องการอาร์กิวเมนต์\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "หน่วยความจำถูกใช้จนหมด"
@@ -109,7 +109,7 @@ msgstr "ไม่สามารถบันทีกไดเรกทอรี
 #: lib/openat-die.c:57
 #, c-format
 msgid "failed to return to initial working directory"
-msgstr "ล้มเหลวในการกลับไปยังไดเรกทอรีเริ่มต้น"
+msgstr "ลà¹\89มà¹\80หลวà¹\83à¸\99à¸\81ารà¸\81ลัà¸\9aà¹\84à¸\9bยัà¸\87à¹\84à¸\94à¹\80รà¸\81à¸\97อรีà¸\97ำà¸\87าà¸\99à¹\80ริà¹\88มà¸\95à¹\89à¸\99"
 
 #. TRANSLATORS:
 #. Get translations for open and closing quotation marks.
@@ -138,7 +138,7 @@ msgstr "`"
 
 #: lib/quotearg.c:313
 msgid "'"
-msgstr "'"
+msgstr ""
 
 #: lib/regcomp.c:131
 msgid "Success"
@@ -180,7 +180,7 @@ msgstr "ไม่ตรงกันกับ ( หรือ \\("
 msgid "Unmatched \\{"
 msgstr "ไม่ตรงกันกับ \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "เนื้อหาของ \\{\\} ไม่ถูกต้อง"
 
@@ -200,7 +200,7 @@ msgstr "นิพจน์ปกติก่อนหน้าไม่ถูก
 msgid "Premature end of regular expression"
 msgstr "นิพจน์ปกติจบโดยยังไม่สมบูรณ์"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "นิพจน์ปกติใหญ่เกินไป"
 
@@ -357,7 +357,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -381,155 +381,132 @@ msgstr "โฮมเพจของ %s : <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "โฮมเพจของ %s : <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "ความช่วยเหลือทั่วไปในการใช้ซอฟต์แวร์ GNU: <http://www.gnu.org/gethelp/>\n"
 
 #: lib/xstrtol-error.c:63
 #, c-format
 msgid "invalid %s%s argument '%s'"
-msgstr "%s%s รับอาร์กิวเมนต์ที่ไม่ถูกต้อง '%s'"
+msgstr "%s%s รับอาร์กิวเมนต์ที่ไม่ถูกต้อง ‘%s’"
 
 #: lib/xstrtol-error.c:68
 #, c-format
 msgid "invalid suffix in %s%s argument '%s'"
-msgstr "คำเสริมท้ายไม่ถูกต้องใน %s%s อาร์กิวเมนต์  '%s'"
+msgstr "คำเสริมท้ายไม่ถูกต้องใน %s%s อาร์กิวเมนต์  ‘%s’"
 
 #: lib/xstrtol-error.c:72
 #, c-format
 msgid "%s%s argument '%s' too large"
-msgstr "%s%s อาร์กิวเมนต์ '%s' ใหญ่มากเกินไป"
+msgstr "%s%s อาร์กิวเมนต์ ‘%s’ ใหญ่มากเกินไป"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr " [ ไม่สมดุลกัน"
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "ชื่อกลุ่มชุดอักขระไม่ถูกต้อง"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "character class syntax is [[:space:]], not [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "เครื่องหมายหลีก \\ ไม่เสร็จสิ้น"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "( ไม่สมดุลกัน"
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "ไม่ระบุวากยสัมพันธ์"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr ") ไม่สมดุลกัน"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATTERN เป็นส่วนเสริมนิพจน์ปกติ (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "การร้องขอด้วย 'egrep'  ไม่สนับสนุนให้ใช้; ใช้ `grep -E' แทน.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATTERN  เป็นชุดของสายอักขระตัวแบ่งบรรทัดใหม่.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "การร้องขอด้วย 'fgrep' ไม่สนับสนุนให้ใช้; ใช้  'grep -F' แทน.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATTERN โดยมาตรฐานเป็นนิพจน์ปกติพื้นฐาน (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"'egrep'  หมายถึง `grep -E'. 'fgrep' หมายถึง `grep -F'.\n"
-"การร้องขอโดยตรงทั้ง `egrep' หรือ `fgrep' ได้ถูกคัดค้าน.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "ไมค์ ฮาเออร์เทล"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "อื่น ๆ , ดูที่ <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "ความยาวบริบทอาร์กิวเมนต์ไม่ถูกต้อง"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek ล้มเหลว"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "ข้อมูลเข้ายาวเกินกว่าจะนับได้"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "ตรงกันกันกับแฟ้มฐานสอง %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "คำเตือน: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "เรียกซ้ำไดเรกทอรีเป็นวงวน"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "แฟ้มนำเข้า %s เป็นแฟ้มส่งออกด้วยเหมือนกัน"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(นำเข้ามาตรฐาน)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
-msgstr "วิธีใช้: %s [OPTION]... PATTERN [FILE]...\n"
+msgstr "วิธีใช้: %s [OPTION]… PATTERN [FILE]…\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
-msgstr "ลองใช้ '%s --help' เพื่อข้อมูลเพิ่มเติม.\n"
+msgstr "ลองใช้ ‘%s —help’ เพื่อข้อมูลเพิ่มเติม.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "ค้นหาสำหรับ PATTERN ในแต่ละ FILE หรือตัวนำเข้ามาตรฐาน.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATTERN โดยมาตรฐานเป็นนิพจน์ปกติพื้นฐาน (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
 "\n"
 "Regexp selection and interpretation:\n"
 msgstr ""
-"ตัวอย่าง: %s -i 'hello world' menu.h main.c\n"
+"ตัวอย่าง: %s -i ‘hello world’ menu.h main.c\n"
 "\n"
 "การเลือกนิพจน์ปกติและการแปลความหมาย:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -538,12 +515,12 @@ msgid ""
 "  -G, --basic-regexp        PATTERN is a basic regular expression (BRE)\n"
 "  -P, --perl-regexp         PATTERN is a Perl regular expression\n"
 msgstr ""
-"  -E, --extended-regexp     PATTERN เป็นส่วนขยายนิพจน์ปกติ (ERE)\n"
-"  -F, --fixed-strings       PATTERN เป็นชุดสายอักขระของตัวแบ่งขึ้นบรรทัดใหม่\n"
-"  -G, --basic-regexp        PATTERN\" เป็นนิพจน์ปกติพื้นฐาน (BRE)\n"
-"  -P, --perl-regexp         PATTERN เป็นนิจน์ปกติภาษาเพิร์ล\n"
+"  -E, extended-regexp     PATTERN เป็นส่วนขยายนิพจน์ปกติ (ERE)\n"
+"  -F, fixed-strings       PATTERN เป็นชุดสายอักขระของตัวแบ่งขึ้นบรรทัดใหม่\n"
+"  -G, basic-regexp        PATTERN\" เป็นนิพจน์ปกติพื้นฐาน (BRE)\n"
+"  -P, perl-regexp         PATTERN เป็นนิจน์ปกติภาษาเพิร์ล\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -553,33 +530,31 @@ msgid ""
 "  -x, --line-regexp         force PATTERN to match only whole lines\n"
 "  -z, --null-data           a data line ends in 0 byte, not newline\n"
 msgstr ""
-"  -e, --regexp=PATTERN      ใช้ PATTERN สำหรับการจับคู่กัน\n"
-"  -f, --file=FILE           รับ PATTERN มาจาก FILE\n"
-"  -i, --ignore-case         เพิกเฉยต่อความแตกต่างอักษรใหญ่เล็ก\n"
-"  -w, --word-regexp         บังคับ PATTERN ให้จับคู่เฉพาะที่ตรงกันทั้งคำเท่านั้น\n"
-"  -x, --line-regexp         บังคับ PATTERN ให้จับคู่เฉพาะที่ตรงกันทั้งบรรทัดเท่าทั้น\n"
-"  -z, --null-data           ข้อมูลบรรทัดจบด้วยขนาด 0 ไบต์, ไม่มีตัวขึ้นบรรทัดใหม่\n"
+"  -e, regexp=PATTERN      ใช้ PATTERN สำหรับการจับคู่กัน\n"
+"  -f, file=FILE           รับ PATTERN มาจาก FILE\n"
+"  -i, ignore-case         เพิกเฉยต่อความแตกต่างอักษรใหญ่เล็ก\n"
+"  -w, word-regexp         บังคับ PATTERN ให้จับคู่เฉพาะที่ตรงกันทั้งคำเท่านั้น\n"
+"  -x, line-regexp         บังคับ PATTERN ให้จับคู่เฉพาะที่ตรงกันทั้งบรรทัดเท่าทั้น\n"
+"  -z, null-data           ข้อมูลบรรทัดจบด้วยขนาด 0 ไบต์, ไม่มีตัวขึ้นบรรทัดใหม่\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "เบ็ดเตล็ด:\n"
-"  -s, --no-messages         ระงับข้อความแสดงข้อผิดพลาด\n"
-"  -v, --invert-match        เลือกบรรทัดที่ไม่ตรงกัน\n"
-"  -V, --version             พิมพ์ข้อมูลรุ่นแล้วออก\n"
-"      --help                แสดงความช่วยเหลือนี้แล้วออก\n"
-"      --mmap                ไม่สนับสนุนให้ใช้ no-op; แสดงคำเตือน\n"
+"  -s, —no-messages         ระงับข้อความแสดงข้อผิดพลาด\n"
+"  -v, —invert-match        เลือกบรรทัดที่ไม่ตรงกัน\n"
+"  -V, —version             พิมพ์ข้อมูลรุ่นแล้วออก\n"
+"      —help                แสดงความช่วยเหลือนี้แล้วออก\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -595,15 +570,15 @@ msgid ""
 msgstr ""
 "\n"
 "ควบคุมการนำออก:\n"
-"  -m, --max-count=NUM       หยุดหลังจากมีการตรงกัน NUM ครั้ง\n"
-"  -b, --byte-offset         พิมพ์การชดเชยไบต์กับบรรทัดนำออก\n"
-"  -n, --line-number         พิมพ์หมายเลขบรรทัดกับบรรทัดนำออก\n"
-"      --line-buffered       ล้างนำออกบนทุก ๆ บรรทัด\n"
-"  -H, --with-filename       พิมพ์ชื่อแฟ้มที่ตรงกันในแต่ละครั้ง\n"
-"  -h, --no-filename         ระงับคำนำหน้าชื่อแฟ้มในการนำออก\n"
-"      --label=LABEL         พิมพ์ LABEL เป็นชื่อคำนำหน้าแฟ้มสำหรับนำเข้ามาตรฐาน\n"
+"  -m, max-count=NUM       หยุดหลังจากมีการตรงกัน NUM ครั้ง\n"
+"  -b, byte-offset         พิมพ์การชดเชยไบต์กับบรรทัดนำออก\n"
+"  -n, line-number         พิมพ์หมายเลขบรรทัดกับบรรทัดนำออก\n"
+"      line-buffered       ล้างนำออกบนทุก ๆ บรรทัด\n"
+"  -H, with-filename       พิมพ์ชื่อแฟ้มที่ตรงกันในแต่ละครั้ง\n"
+"  -h, no-filename         ระงับคำนำหน้าชื่อแฟ้มในการนำออก\n"
+"      label=LABEL         พิมพ์ LABEL เป็นชื่อคำนำหน้าแฟ้มสำหรับนำเข้ามาตรฐาน\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -612,13 +587,13 @@ msgid ""
 "                            TYPE is 'binary', 'text', or 'without-match'\n"
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
-"  -o, --only-matching       แสดงเพียงแต่ส่วนของบรรทัดที่ตรงกันกับ PATTERN\n"
-"  -q, --quiet, --silent     ระงับนำออกปกติทั้งหมด\n"
-"      --binary-files=TYPE   ทึกทักเอาว่าแฟ้มฐานสองเป็น TYPE;\n"
-"                            TYPE เป็น `binary', `text', หรือ `without-match'\n"
-"  -a, --text                มีค่าเท่ากันกับ --binary-files=text\n"
+"  -o, only-matching       แสดงเพียงแต่ส่วนของบรรทัดที่ตรงกันกับ PATTERN\n"
+"  -q, —quiet, —silent     ระงับนำออกปกติทั้งหมด\n"
+"      binary-files=TYPE   ทึกทักเอาว่าแฟ้มฐานสองเป็น TYPE;\n"
+"                            TYPE เป็น `binary’, `text’, หรือ `without-match’\n"
+"  -a, —text                มีค่าเท่ากันกับ —binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -629,15 +604,15 @@ msgid ""
 "  -r, --recursive           like --directories=recurse\n"
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
-"  -I                        มีค่าเท่ากันกับ --binary-files=without-match\n"
-"  -d, --directories=ACTION  จะทำการจัดการไดเรกทอรีอย่างไร;\n"
-"                            ACTION เป็น `read', `recurse', หรือ `skip'\n"
-"  -D, --devices=ACTION      จะทำการจัดการอุปกรณ์อย่างไร, FIFOs and sockets;\n"
-"                            ACTION is `read' or `skip'\n"
-"  -r, --recursive           เหมือนกับ --directories=recurse\n"
-"  -R, --dereference-recursive  เช่นกัน, แต่ตาม symlink ทั้งหมด\n"
+"  -I                        มีค่าเท่ากันกับ binary-files=without-match\n"
+"  -d, directories=ACTION  จะทำการจัดการไดเรกทอรีอย่างไร;\n"
+"                            ACTION เป็น `read’, `recurse’, หรือ `skip’\n"
+"  -D, devices=ACTION      จะทำการจัดการอุปกรณ์อย่างไร, FIFOs and sockets;\n"
+"                            ACTION is `read’ or `skip’\n"
+"  -r, —recursive           เหมือนกับ —directories=recurse\n"
+"  -R, dereference-recursive  เช่นกัน, แต่ตาม symlink ทั้งหมด\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -647,12 +622,12 @@ msgid ""
 "      --exclude-dir=PATTERN  directories that match PATTERN will be "
 "skipped.\n"
 msgstr ""
-"      --include=FILE_PATTERN  ค้นหาเพียงแต่แฟ้มที่ตรงกันกับ FILE_PATTERN\n"
-"      --exclude=FILE_PATTERN  ข้ามแฟ้มและไดเร็กทอรีที่ตรงกันกับ FILE_PATTERN\n"
-"      --exclude-from=FILE   ข้ามแฟ้มที่ตรงกันกับแบบแผนแฟ้มจาก FILE\n"
-"      --exclude-dir=PATTERN  ไดเร็กทอรีที่ตรงกันกับ PATTERN จะถูกข้ามไป.\n"
+"      include=FILE_PATTERN  ค้นหาเพียงแต่แฟ้มที่ตรงกันกับ FILE_PATTERN\n"
+"      exclude=FILE_PATTERN  ข้ามแฟ้มและไดเร็กทอรีที่ตรงกันกับ FILE_PATTERN\n"
+"      exclude-from=FILE   ข้ามแฟ้มที่ตรงกันกับแบบแผนแฟ้มจาก FILE\n"
+"      exclude-dir=PATTERN  ไดเร็กทอรีที่ตรงกันกับ PATTERN จะถูกข้ามไป.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -661,13 +636,13 @@ msgid ""
 "  -T, --initial-tab         make tabs line up (if needed)\n"
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
-"  -L, --files-without-match  พิมพ์เพียงแค่ชื่อของ FILE ที่ไม่ตรงกันกับที่อยู่ภายใน\n"
-"  -l, --files-with-matches  พิมพ์เพียงแค่ชื่อของ FILE ที่มีตรงกับที่อยู่ภายใน\n"
-"  -c, --count               พิมพ์เพียงแต่จำนวนบรรทัดที่ตรงกันที่นับได้ในแต่ละ FILE\n"
-"  -T, --initial-tab         ทำการจัดเตรียมแท็บ (ถ้าจำเป็น)\n"
-"  -Z, --null                พิมพ์ 0 ไบต์หลังชื่อ FILE\n"
+"  -L, files-without-match  พิมพ์เพียงแค่ชื่อของ FILE ที่ไม่ตรงกันกับที่อยู่ภายใน\n"
+"  -l, files-with-matches  พิมพ์เพียงแค่ชื่อของ FILE ที่มีตรงกับที่อยู่ภายใน\n"
+"  -c, count               พิมพ์เพียงแต่จำนวนบรรทัดที่ตรงกันที่นับได้ในแต่ละ FILE\n"
+"  -T, initial-tab         ทำการจัดเตรียมแท็บ (ถ้าจำเป็น)\n"
+"  -Z, null                พิมพ์ 0 ไบต์หลังชื่อ FILE\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -678,11 +653,11 @@ msgid ""
 msgstr ""
 "\n"
 "ควบคุมบริบท:\n"
-"  -B, --before-context=NUM  พิมพ์ NUM บรรทัดของบริบทส่วนนำ\n"
-"  -A, --after-context=NUM   พิมพ์ NUM บรรทัดของบริบทส่วนตาม\n"
-"  -C, --context=NUM         พิมพ์ NUM บรรทัดของบริบทส่งออก\n"
+"  -B, before-context=NUM  พิมพ์ NUM บรรทัดของบริบทส่วนนำ\n"
+"  -A, after-context=NUM   พิมพ์ NUM บรรทัดของบริบทส่วนตาม\n"
+"  -C, context=NUM         พิมพ์ NUM บรรทัดของบริบทส่งออก\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -695,16 +670,25 @@ msgid ""
 "                            (MSDOS/Windows)\n"
 "\n"
 msgstr ""
-"  -NUM                      เหมือนกับ --context=NUM\n"
-"      --color[=WHEN],\n"
-"      --colour[=WHEN]       ใช้เครื่องหมายกำกับเพื่อเน้นข้อความที่ตรงกัน;\n"
-"                            เมื่อ WHEN ได้แก่ `always', `never', หรือ `auto'\n"
-"  -U, --binary              ไม่ต้องถอดอักขระ CR ที่ EOL  (MSDOS/Windows)\n"
-"  -u, --unix-byte-offsets   รายงานการชดเชยก็ต่อเมื่อ CR ไม่ได้มีอยู่\n"
+"  -NUM                      เหมือนกับ context=NUM\n"
+"      color[=WHEN],\n"
+"      colour[=WHEN]       ใช้เครื่องหมายกำกับเพื่อเน้นข้อความที่ตรงกัน;\n"
+"                            เมื่อ WHEN ได้แก่ `always’, `never’, หรือ `auto’\n"
+"  -U, binary              ไม่ต้องถอดอักขระ CR ที่ EOL  (MSDOS/Windows)\n"
+"  -u, unix-byte-offsets   รายงานการชดเชยก็ต่อเมื่อ CR ไม่ได้มีอยู่\n"
 "                            (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"‘egrep’  หมายถึง `grep -E’. ‘fgrep’ หมายถึง `grep -F’.\n"
+"การร้องขอโดยตรงทั้ง `egrep’ หรือ `fgrep’ ไม่แนะนำให้ใช้.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -718,88 +702,78 @@ msgstr ""
 "สถานะการออกเป็น 0 เมื่อบรรทัดใด ๆ ถูกเลือก, มิฉะนั้น 1 ;\n"
 "ถ้าเกิดข้อผิดพลาดขึ้นและ -q ไม่ได้ถูกให้มา, สถานะการออกเป็น 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "โฮมเพจ GNU Grep : <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s สามารถใช้แบบแผนวากยสัมพันธ์ได้เพียง %s "
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "การขัดแย้งของการตรงกันได้รับการระบุ"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "ตัวจับคู่ไม่ถูกต้อง %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "ไม่รู้จักกระบวนการอุปกรณ์"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "ตัวนับสูงสุดไม่ถูกต้อง"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "ไม่รู้จักชนิดแฟ้มฐานสอง"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "ตัวเลือก --mmap ได้กำหนดให้ไม่ดำเนินการใดตั้งแต่ 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
-msgstr "การสนับสนุนตัวเลือก -P ไม่ได้ถูกรวบรวมไปยังแฟ้มฐานสอง --disable-perl-regexp นี้"
+msgstr "การสนับสนุนตัวเลือก -P ไม่ได้ถูกรวบรวมไปยังแฟ้มฐานสอง disable-perl-regexp นี้"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "ตัวเลือก -P สนับสนุนรูปแบบเดียวเท่านั้น"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "ข้อผิดพลาดภายใน (ไม่ควรเกิดขึ้นมาก่อน)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "ล้มเหลวที่จะจัดสรรหน่วยความจำสำหรับสแต็ก PCRE JIT"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "ข้อผิดพลาดภายใน"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "ขอบเขตความยาวบรรทัด PCRE เกินจากข้อจำกัด"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "ขอบเขตการ backtrack ของ PCRE เกินจากข้อจำกัด"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "ลำดับไบต์ UTF-8 ที่นำเข้าไม่ถูกต้อง"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "ข้อผิดพลาด PCRE ภายใน: %d"
index b9c900b..8a042e7 100644 (file)
Binary files a/po/tr.gmo and b/po/tr.gmo differ
index 983b2a1..7cd459f 100644 (file)
--- a/po/tr.po
+++ b/po/tr.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.5.1a\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2005-03-04 16:37+0300\n"
 "Last-Translator: Nilgün Belma Bugüner <nilgun@superonline.com>\n"
 "Language-Team: Turkish <gnu-tr-u12a@lists.sourceforge.net>\n"
@@ -30,7 +30,7 @@ msgstr ""
 msgid "Valid arguments are:"
 msgstr ""
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr ""
@@ -94,8 +94,8 @@ msgstr "%s: `-W %s' seçeneği argümansız kullanılır\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: `%s' seçeneği bir argümanla kullanılır\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "bellek tükendi"
@@ -179,7 +179,7 @@ msgstr ""
 msgid "Unmatched \\{"
 msgstr ""
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr ""
 
@@ -199,7 +199,7 @@ msgstr ""
 msgid "Premature end of regular expression"
 msgstr ""
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr ""
 
@@ -333,7 +333,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, fuzzy, c-format
 msgid ""
 "\n"
@@ -358,7 +358,7 @@ msgstr ""
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr ""
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 
@@ -377,128 +377,107 @@ msgstr ""
 msgid "%s%s argument '%s' too large"
 msgstr ""
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 #, fuzzy
 msgid "unbalanced ["
 msgstr "Karşılıksız ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr ""
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 #, fuzzy
 msgid "unfinished \\ escape"
 msgstr "Tamamlanmamış \\ öncelemi"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 #, fuzzy
 msgid "unbalanced ("
 msgstr "Karşılıksız ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 #, fuzzy
 msgid "no syntax specified"
 msgstr "Sözdizimi belirtilmemiş"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 #, fuzzy
 msgid "unbalanced )"
 msgstr "Karşılıksız )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr ""
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr ""
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr ""
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "bağlam uzunluk değeri geçersiz"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr ""
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "girdi sayılamayacak kadar büyük"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "İkilik dosya %s eşleşir\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, fuzzy, c-format
 msgid "warning: %s: %s"
 msgstr "uyarı: %s: %s\n"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "ardışık dizin çevrimi"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr ""
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(standart girdi)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Kullanımı: %s [SEÇENEK]... MASKE [DOSYA]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, fuzzy, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Daha fazla bilgi için `%s --help' yazın.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr ""
+
+#: src/grep.c:1537
 #, fuzzy, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -510,7 +489,7 @@ msgstr ""
 "\n"
 "Düzenli ifade seçimi ve yorumlanması:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, fuzzy, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -524,7 +503,7 @@ msgstr ""
 "  -G, --basic-regexp        KALIP bir temel düzenli ifadedir\n"
 "  -P, --perl-regexp         KALIP bir Perl düzenli ifadesidir\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, fuzzy, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -541,16 +520,15 @@ msgstr ""
 "  -x, --line-regexp      KALIP bir bütün satır olarak ele alınır\n"
 "  -z, --null-data        satır sonu içermeyen 0 baytlık satır\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Çeşitli:\n"
@@ -560,7 +538,7 @@ msgstr ""
 "      --help                bu iletileri gösterir ve çıkar\n"
 "      --mmap                mümkünse bellek-eşlemli girdi kullanılır\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -575,7 +553,7 @@ msgid ""
 "prefix\n"
 msgstr ""
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -585,7 +563,7 @@ msgid ""
 "  -a, --text                equivalent to --binary-files=text\n"
 msgstr ""
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -597,7 +575,7 @@ msgid ""
 "  -R, --dereference-recursive  likewise, but follow all symlinks\n"
 msgstr ""
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -608,7 +586,7 @@ msgid ""
 "skipped.\n"
 msgstr ""
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -618,7 +596,7 @@ msgid ""
 "  -Z, --null                print 0 byte after FILE name\n"
 msgstr ""
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -628,7 +606,7 @@ msgid ""
 "  -C, --context=NUM         print NUM lines of output context\n"
 msgstr ""
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -659,7 +637,14 @@ msgstr ""
 "İki DOSYAdan az verilmişse -h varsayılır.\n"
 "Çıkışta durum eşleşme varsa 0, yoksa 1, belirsizlik varsa 2 dir.\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -669,88 +654,78 @@ msgid ""
 "if any error occurs and -q is not given, the exit status is 2.\n"
 msgstr ""
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr ""
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr ""
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "birbiriyle çatışan eşleştiriciler belirtildi"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, fuzzy, c-format
 msgid "invalid matcher %s"
 msgstr "en çok miktarı geçersiz"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "bilinmeyen aygıt yöntemi"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "en çok miktarı geçersiz"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "bilinmeyen ikilik dosya türü"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr ""
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr ""
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, fuzzy, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P seçeneği desteklenmiyor"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr ""
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr ""
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr ""
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr ""
index 56a4d29..bc55cd5 100644 (file)
Binary files a/po/uk.gmo and b/po/uk.gmo differ
index a094557..c6a5ca7 100644 (file)
--- a/po/uk.po
+++ b/po/uk.po
@@ -4,13 +4,13 @@
 #
 # Volodymyr M. Lisivka <lvm@mystery.lviv.net>, 2001-2002.
 # Dmytro O. Redchuk <dor@kiev-online.net>, 2002.
-# Yuri Chornoivan <yurchor@ukr.net>, 2011, 2012, 2013.
+# Yuri Chornoivan <yurchor@ukr.net>, 2011, 2012, 2013, 2014.
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.15.15\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-22 15:54+0200\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-11 14:49+0300\n"
 "Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n"
 "Language-Team: Ukrainian <translation-team-uk@lists.sourceforge.net>\n"
 "Language: uk\n"
@@ -34,7 +34,7 @@ msgstr "неоднозначний аргумент, %s, %s"
 msgid "Valid arguments are:"
 msgstr "Список коректних аргументів:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "помилка запису"
@@ -98,8 +98,8 @@ msgstr "%s: додавання аргументів до параметра «-W
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: до параметра «-W %s» слід додати аргумент\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "пам'ять вичерпано"
@@ -183,7 +183,7 @@ msgstr "Неврівноважена послідовність ( або \\("
 msgid "Unmatched \\{"
 msgstr "Неврівноважена послідовність \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "Некоректний вміст \\{\\}"
 
@@ -203,7 +203,7 @@ msgstr "Помилка у попередньому формальному вир
 msgid "Premature end of regular expression"
 msgstr "Неочікуване завершення формального виразу"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Занадто об'ємний формальний вираз"
 
@@ -361,7 +361,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -385,7 +385,7 @@ msgstr "Домашня сторінка %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Домашня сторінка %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Загальна довідкова інформація щодо використання програмного забезпечення "
@@ -406,133 +406,105 @@ msgstr "некоректний суфікс у аргументі %s%s «%s»"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s, аргумент «%s» є занадто об'ємним"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "неврівноважена дужка ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "некоректний клас символів"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr ""
 "синтаксичну конструкцію класу символів слід визначати так: [[:space:]], а не "
 "так: [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "незавершена \\-послідовність"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "неврівноважена дужка ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "не вказано синтаксис"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "неврівноважена дужка )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "ШАБЛОНОМ є розширений формальний вираз (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr ""
-"Виклик команди «egrep» вважається застарілим, скористайтеся командою «grep -"
-"E».\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr ""
-"ШАБЛОН є набором незмінних рядків, відокремлених символом нового рядка.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr ""
-"Виклик команди «fgrep» вважається застарілим, скористайтеся командою «grep -"
-"F».\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "ШАБЛОНом, типово, є звичайний формальний вираз (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"«egrep» відповідає команді «grep -E». «fgrep» — «grep -F».\n"
-"Безпосередній виклик команд «egrep» та «fgrep» використовувати не варто.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "інші, див. <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "помилковий аргумент довжини контексту"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "помилка lseek"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "вхідні дані занадто довгі для обліку"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "Двійковий файл %s містить збіжність\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "попередження: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "зациклення рекурсивного проходу каталогів"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "файл вхідних даних %s є також файлом вихідних даних"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(стандартне джерело вхідних даних)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Використання: %s [ПАРАМЕТР]... ШАБЛОН [ФАЙЛ]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "Віддайте команду «%s --help», щоб дізнатися більше.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr ""
 "Шукати ШАБЛОН у кожному ФАЙЛі або стандартному джерелі вхідних даних.\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "ШАБЛОНом, типово, є звичайний формальний вираз (BRE).\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -543,7 +515,7 @@ msgstr ""
 "\n"
 "Вибір за формальними виразами і інтерпретація:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -557,7 +529,7 @@ msgstr ""
 "  -G, --basic-regexp        ШАБЛОН є звичайним формальним виразом (BRE)\n"
 "  -P, --perl-regexp         ШАБЛОН є формальним виразом Perl\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -579,16 +551,15 @@ msgstr ""
 "символом\n"
 "                            кінця рядка (\\n)\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Інше:\n"
@@ -596,11 +567,8 @@ msgstr ""
 "  -v, --invert-match        вибирати рядки без збіжностей\n"
 "  -V, --version             показати дані щодо версії і завершити роботу\n"
 "      --help                показати ці довідкові дані і завершити роботу\n"
-"      --mmap                застарілий, не обробляється, викликає "
-"відповідне\n"
-"                                   повідомлення\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -628,7 +596,7 @@ msgstr ""
 "      --label=МІТКА         показувати МІТКУ замість назви файла для "
 "стандартного джерела вхідних даних\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -646,7 +614,7 @@ msgstr ""
 "match'\n"
 "  -a, --text                те саме, що і --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -670,7 +638,7 @@ msgstr ""
 "символічними\n"
 "                            посиланнями\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -689,7 +657,7 @@ msgstr ""
 "      --exclude-dir=ШАБЛОН    пропустити каталоги, назви яких відповідають "
 "ШАБЛОНу.\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -708,7 +676,7 @@ msgstr ""
 "потрібно)\n"
 "  -Z, --null                вивести байти 0 після назви ФАЙЛа\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -726,7 +694,7 @@ msgstr ""
 "  -C, --context=ЧИСЛО        показати ЧИСЛО рядків контексту виведених "
 "даних\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -751,7 +719,16 @@ msgstr ""
 "                             CR (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"«egrep» відповідає команді «grep -E». «fgrep» — «grep -F».\n"
+"Безпосередній виклик команд «egrep» та «fgrep» використовувати не варто.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -766,47 +743,37 @@ msgstr ""
 "Код завершення 0 — якщо було виявлено відповідники, 1 — коли їх нема,\n"
 "2 — якщо сталася помилка і не було використано параметр -q.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Домашня сторінка GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "У %s можна використовувати лише синтаксис шаблонів %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "задані умови відповідності є суперечливими"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "некоректний вираз порівняння %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "невідомий спосіб обробки для пристроїв"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "помилкова максимальна кількість"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "невідомий тип двійкових файлів"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "параметр --mmap не обробляється з 2010 року"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -814,46 +781,69 @@ msgstr ""
 "цей виконуваний файл зібрано без підтримки параметра -P (--disable-perl-"
 "regexp)"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "аргументом параметра -P може бути лише один шаблон"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "внутрішня помилка (такої помилки не повинно було статися)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "не вдалося отримати область пам’яті під стек JIT PCRE"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "внутрішня помилка"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "перевищено обмеження на довжину рядка PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "перевищено обмеження на зворотне стеження у PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "некоректна послідовність байтів UTF-8 у вхідних даних"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
 msgstr "внутрішня помилка PCRE: %d"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "ШАБЛОНОМ є розширений формальний вираз (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr ""
+#~ "Виклик команди «egrep» вважається застарілим, скористайтеся командою "
+#~ "«grep -E».\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "ШАБЛОН є набором незмінних рядків, відокремлених символом нового рядка.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr ""
+#~ "Виклик команди «fgrep» вважається застарілим, скористайтеся командою "
+#~ "«grep -F».\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "У %s можна використовувати лише синтаксис шаблонів %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "параметр --mmap не обробляється з 2010 року"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "не завершено лічильник повторів"
 
index 62d7bd0..ff7c049 100644 (file)
Binary files a/po/vi.gmo and b/po/vi.gmo differ
index 6c707f0..1ace764 100644 (file)
--- a/po/vi.po
+++ b/po/vi.po
@@ -1,16 +1,16 @@
 # Vietnamese Translation for Grep.
 # Bản dịch tiếng Việt dành cho Grep.
-# Copyright © 2013 Free Software Foundation, Inc.
+# Copyright © 2014 Free Software Foundation, Inc.
 # This file is distributed under the same license as the grep package.
 # Clytie Siddall <clytie@riverland.net.au>, 2005-2010.
-# Trần Ngọc Quân <vnwildman@gmail.com>, 2012-2013.
+# Trần Ngọc Quân <vnwildman@gmail.com>, 2012-2014.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: grep-2.15.15\n"
+"Project-Id-Version: grep-2.18.143\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
-"PO-Revision-Date: 2013-12-23 07:48+0700\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
+"PO-Revision-Date: 2014-05-12 07:23+0700\n"
 "Last-Translator: Trần Ngọc Quân <vnwildman@gmail.com>\n"
 "Language-Team: Vietnamese <translation-team-vi@lists.sourceforge.net>\n"
 "Language: vi\n"
@@ -35,7 +35,7 @@ msgstr "đối số %s không rõ ràng đối với %s"
 msgid "Valid arguments are:"
 msgstr "Các đối số hợp lệ là:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "lỗi ghi"
@@ -99,8 +99,8 @@ msgstr "%s: tùy chọn “-W %s” không cho phép đối số\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: tùy chọn “-W %s” yêu cầu một đối số\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "hết bộ nhớ"
@@ -184,7 +184,7 @@ msgstr "Có ký tự “(” hoặc “\\(” lẻ cặp"
 msgid "Unmatched \\{"
 msgstr "Có ký tự “\\{” lẻ cặp"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "\\{\\} có nội dung sai"
 
@@ -204,7 +204,7 @@ msgstr "Biểu thức chính quy đi trước mà không hợp lệ"
 msgid "Premature end of regular expression"
 msgstr "Biểu thức chính quy kết thức quá sớm"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "Biểu thức chính quy quá lớn"
 
@@ -361,7 +361,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -388,7 +388,7 @@ msgstr "Trang chủ của %s: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "Trang chủ của %s: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr ""
 "Trợ giúp chung về sử dụng phần mềm GNU: <http://www.gnu.org/gethelp/>\n"
@@ -396,7 +396,7 @@ msgstr ""
 #: lib/xstrtol-error.c:63
 #, c-format
 msgid "invalid %s%s argument '%s'"
-msgstr "đối số %s%s không hợp lệ “%s”"
+msgstr "đối số  %s%s không hợp lệ “%s”"
 
 #: lib/xstrtol-error.c:68
 #, c-format
@@ -408,126 +408,103 @@ msgstr "hậu tố không hợp lệ trong %s%s đối số “%s”"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s đối số  “%s” quá lớn"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "thiếu dấu ngoặc vuông mở ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "sai lớp ký tự"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "cú pháp lớp ký tự là [[:space:]], không phải [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "chưa kết thúc dãy thoát \\"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "thiếu dấu ngoặc đơn mở ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "chưa chỉ rõ cú pháp"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "thiếu dấu ngoặc đơn đóng )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "MẪU là một biểu thức chính quy mở rộng (ERE).\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "Không tán thành việc gọi như “egrep” nên thay thế bằng “grep -E”.\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "MẪU là một tập hợp các chuỗi cố định phân cách bằng ký tự dòng mới.\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "Không tán thành việc gọi như “fgrep” nên thay thế bằng “grep -F”.\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "MẪU, theo mặc định, là một biểu thức chính quy cơ bản (BRE).\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"“egrep” nên là “grep -E”, “fgrep” nên là “grep -F”.\n"
-"Không tán thành gọi trực tiếp “egrep” cũng như “fgrep”.\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr ""
 "nhiều người khác, xem tại <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "đối số chiều dài ngữ cảnh không hợp lệ"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek gặp lỗi"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "dữ liệu đầu vào quá lớn nên không thể đếm được"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
-msgstr "Tập tin nhị phân %s tương ứng với\n"
+msgstr "Tập tin nhị phân “%s” khớp mẫu tìm kiếm\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "cảnh báo: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "vòng lặp thư mục đệ quy"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
-msgstr "tập tin đầu vào %s cũng là kết xuất"
+msgstr "tập tin đầu vào “%s” cũng là kết xuất"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(đầu vào tiêu chuẩn)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "Cách dùng: %s [TÙY_CHỌN]... MẪU [TẬP_TIN]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
-msgstr "Hãy chạy lệnh “%s --help” (trợ giúp) để biết thêm thông tin.\n"
+msgstr "Hãy chạy lệnh “%s --help” để biết thêm thông tin.\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
-msgstr "Tìm kiếm MẪU trong mỗi TẬP_TIN hay đầu vào tiêu chuẩn.\n"
+msgstr "Tìm kiếm MẪU trong mỗi TẬP_TIN hay từ đầu vào tiêu chuẩn.\n"
+
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "MẪU, theo mặc định, là một biểu thức chính quy cơ bản (BRE).\n"
 
-#: src/main.c:1550
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -538,7 +515,7 @@ msgstr ""
 "\n"
 "Chọn và biên dịch biểu thức chính quy:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -553,7 +530,7 @@ msgstr ""
 "  -G, --basic-regexp        MẪU là một biểu thức chính quy cơ bản (BRE).\n"
 "  -P, --perl-regexp         MẪU là một biểu thức chính quy Perl.\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -571,26 +548,24 @@ msgstr ""
 "  -z, --null-data           một dòng dữ liệu kết thúc bằng byte 0,\n"
 "                            không phải ký tự dòng mới\n"
 
-#: src/main.c:1568
+#: src/grep.c:1554
 #, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "Hỗn tạp:\n"
-"  -s, --no-messages         chặn các thông điệp lỗi\n"
+"  -s, --no-messages         chặn các thông báo lỗi\n"
 "  -v, --invert-match        chọn các dòng không khớp\n"
-"  -V, --version             in ra thông tin phiên bản, sau đó thoát\n"
-"      --help                hiển thị trợ giúp này, sau đó thoát\n"
-"      --mmap                không được thực thi; gây ra một cảnh báo\n"
+"  -V, --version             in ra thông tin phiên bản rồi thoát\n"
+"      --help                hiển thị trợ giúp này rồi thoát\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -616,7 +591,7 @@ msgstr ""
 "      --label=NHÃN          sử dụng NHÃN này làm tiền tố cho tập tin\n"
 "                              cho đầu ra tiêu chuẩn\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -633,7 +608,7 @@ msgstr ""
 "                                  * “without-match”  không khớp\n"
 "  -a, --text                giống với tùy chọn “--binary-files=text”\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -657,7 +632,7 @@ msgstr ""
 "  -r, --recursive           giống với tùy chọn “--directories=recurse”\n"
 "  -R, --dereference-recursive  cũng vậy nhưng cho phép cả các liên kết mềm\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -674,7 +649,7 @@ msgstr ""
 "                              tin trong tập tin này\n"
 "      --exclude-dir=MẪU     thư mục nào khớp với mẫu này thì bị bỏ qua\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -689,7 +664,7 @@ msgstr ""
 "  -T, --initial-tab         sắp hàng cột tab (nếu cần)\n"
 "  -Z, --null                in ra byte 0 (null) đằng sau tên TẬP TIN\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -704,7 +679,7 @@ msgstr ""
 "  -A, --after-context=SỐ    in ra SỐ dòng ngữ cảnh đi sau\n"
 "  -C, --context=SỐ          in ra SỐ dòng ngữ cảnh kết xuất\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -729,7 +704,16 @@ msgstr ""
 "                            (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"“egrep” nên là “grep -E”, “fgrep” nên là “grep -F”.\n"
+"Không tán thành gọi trực tiếp “egrep” cũng như “fgrep”.\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -745,47 +729,37 @@ msgstr ""
 "Trạng thái thoát là 0 nếu dòng nào được chọn, không thì bằng 1.\n"
 "Nếu có lỗi phát sinh và “-q” không được đưa ra thì trạng thái thoát là 2.\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "Trang chủ của GNU Grep: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s chỉ có khả năng sử dụng cú pháp mẫu %s"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "đã ghi rõ dữ liệu khớp mà xung đột"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "sai mẫu so khớp %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "không rõ phương thức thiết bị"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
-msgstr "số đếm tối đa không hợp lệ"
+msgstr "số lượng tối đa không hợp lệ"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "không rõ kiểu tập tin nhị phân (binary-files)"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "tùy chọn --mmap không còn được thực thi kể từ năm 2010"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
@@ -793,45 +767,64 @@ msgstr ""
 "khả năng hỗ trợ tùy chọn -P không được biên dịch vào tập tin nhị phân --"
 "disable-perl-regexp này"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "tùy chọn “-P” chỉ hỗ trợ một mẫu riêng lẻ"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr "lỗi nội bộ (không nên xảy ra như thế)"
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr "gặp lỗi khi cấp phát bộ nhớ cho stack (ngăn xếp) PCRE JIT"
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "lỗi nội bộ"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "đã vượt quá giới hạn chiều dài dòng của PCRE"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "đã vượt quá giới hạn tìm ngược của PCRE"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr "chuỗi byte UTF-8 không hợp lệ ở đầu vào"
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, c-format
 msgid "internal PCRE error: %d"
-msgstr "lỗi PCRE nội bộ: %d"
+msgstr "lỗi nội bộ PCRE: %d"
+
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "MẪU là một biểu thức chính quy mở rộng (ERE).\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "Không tán thành việc gọi như “egrep” nên thay thế bằng “grep -E”.\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr ""
+#~ "MẪU là một tập hợp các chuỗi cố định phân cách bằng ký tự dòng mới.\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "Không tán thành việc gọi như “fgrep” nên thay thế bằng “grep -F”.\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s chỉ có khả năng sử dụng cú pháp mẫu %s"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "tùy chọn --mmap không còn được thực thi kể từ năm 2010"
 
 #~ msgid "unfinished repeat count"
 #~ msgstr "chưa kết thúc sự đếm lặp lại"
@@ -845,7 +838,7 @@ msgstr "lỗi PCRE nội bộ: %d"
 #~ msgid ""
 #~ "in GREP_COLORS='%s', the `%s' capacity needs a value ('=...'); skipped"
 #~ msgstr ""
-#~ "trong chuỗi “GREP_COLORS='%s'”, khả năng “%s” cần thiết giá trị ('=...'); "
+#~ "trong chuỗi “GREP_COLORS='%s'”, khả năng “%s” cần thiết giá trị ('=...); "
 #~ "nên bỏ qua"
 
 #~ msgid ""
@@ -853,7 +846,7 @@ msgstr "lỗi PCRE nội bộ: %d"
 #~ "('=%s'); skipped"
 #~ msgstr ""
 #~ "trong chuỗi “GREP_COLORS='%s'”, khả năng “%s” là luận lý thì không chấp "
-#~ "nhận được giá trị ('=%s'); nên bỏ qua"
+#~ "nhận được giá trị ('=%s); nên bỏ qua"
 
 #~ msgid "in GREP_COLORS='%s', the `%s' capacity %s"
 #~ msgstr "trong GREP_COLORS='%s”, khả năng “%s” %s"
index e87168d..70bfe71 100644 (file)
Binary files a/po/zh_CN.gmo and b/po/zh_CN.gmo differ
index 20ebc49..0d4dff9 100644 (file)
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.11.11-pre1\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2012-04-15 14:48+0800\n"
 "Last-Translator: Ji ZhengYu <zhengyuji@gmail.com>\n"
 "Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n"
@@ -29,7 +29,7 @@ msgstr "%2$s 的参数 %1$s 有歧义"
 msgid "Valid arguments are:"
 msgstr "有效参数是:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "写错误"
@@ -93,8 +93,8 @@ msgstr "%s: 选项 ‘-W %s’不允许带参数\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: 选项 ‘-W %s’必须带参数\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "内存耗尽"
@@ -178,7 +178,7 @@ msgstr "( 或 \\( 不匹配"
 msgid "Unmatched \\{"
 msgstr "\\{ 不匹配"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "\\{\\} 中的内容无效"
 
@@ -198,7 +198,7 @@ msgstr "之前的正则表达式无效"
 msgid "Premature end of regular expression"
 msgstr "正则表达式非正常结束"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "正则表达式太大"
 
@@ -355,7 +355,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -379,7 +379,7 @@ msgstr "%s 主页: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s 主页: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "GNU 软件的通用帮助: <http://www.gnu.org/gethelp/>\n"
 
@@ -398,125 +398,102 @@ msgstr "%s%s 参数‘%s’的后缀无效"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s 参数‘%s’过多"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "有未匹配的 ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "无效的字符类名"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "字符类的语法是 [[:space:]],而非 [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "未做好 \\ 转义"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "有未匹配的 ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "未指定语法"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "有未匹配的 )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATTERN 是一个可扩展的正则表达式(缩写为 ERE)。\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "‘egrep’已不再使用了;请用‘grep -E’代替。\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATTERN 是一组由断行符分隔的定长字符串。\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "‘fgrep’已不再使用了;请用 ‘grep -F’代替。\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "默认的 PATTERN 是一个基本正则表达式(缩写为 BRE)。\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"‘egrep’即‘grep -E’。‘fgrep’即‘grep -F’。\n"
-"直接使用‘egrep’或是‘fgrep’均已不可行了。\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "其余作者请参看 <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "无效的文本长度参数"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek 失败"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "输入太多无法计数"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "匹配到二进制文件 %s\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "警告: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "嵌套目录循环"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "输入文件 %s 同时也作输出"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(标准输入)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "用法: %s [选项]... PATTERN [FILE]...\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "试用‘%s --help’来获得更多信息。\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "在每个 FILE 或是标准输入中查找 PATTERN。\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "默认的 PATTERN 是一个基本正则表达式(缩写为 BRE)。\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -527,7 +504,7 @@ msgstr ""
 "\n"
 "正则表达式选择与解释:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -541,7 +518,7 @@ msgstr ""
 "  -G, --basic-regexp        PATTERN 是一个基本正则表达式(缩写为 BRE)\n"
 "  -P, --perl-regexp         PATTERN 是一个 Perl 正则表达式\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -558,16 +535,15 @@ msgstr ""
 "  -x, --line-regexp         强制 PATTERN 仅完全匹配一行\n"
 "  -z, --null-data           一个 0 字节的数据行,但不是空行\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "杂项:\n"
@@ -577,7 +553,7 @@ msgstr ""
 "      --help                显示此帮助并退出\n"
 "      --mmap                忽略向后兼容性\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -601,7 +577,7 @@ msgstr ""
 "  -h, --no-filename         输出时不显示文件名前缀\n"
 "      --label=LABEL         将LABEL 作为标准输入文件名前缀\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, fuzzy, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -616,7 +592,7 @@ msgstr ""
 "                            TYPE 可以是`binary', `text', 或`without-match'\n"
 "  -a, --text                等同于 --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, fuzzy, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -635,7 +611,7 @@ msgstr ""
 "  -r, --recursive           等同于--directories=recurse\n"
 "  -R, --dereference-recursive       与上类似,但遍历所有符号链接\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -650,7 +626,7 @@ msgstr ""
 "      --exclude-from=FILE   跳过所有除FILE 以外的文件\n"
 "      --exclude-dir=PATTERN  跳过所有匹配PATTERN 的目录。\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -665,7 +641,7 @@ msgstr ""
 "  -T, --initial-tab         行首tabs 分隔(如有必要)\n"
 "  -Z, --null                在FILE 文件最后打印空字符\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -680,7 +656,7 @@ msgstr ""
 "  -A, --after-context=NUM   打印以文本结尾的NUM 行\n"
 "  -C, --context=NUM         打印输出文本NUM 行\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, fuzzy, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -702,7 +678,16 @@ msgstr ""
 "式)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"‘egrep’即‘grep -E’。‘fgrep’即‘grep -F’。\n"
+"直接使用‘egrep’或是‘fgrep’均已不可行了。\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -717,92 +702,100 @@ msgstr ""
 "如果有任意行被匹配,那退出状态为 0,否则为 1;\n"
 "如果有错误产生,且未指定 -q 参数,那退出状态为 2。\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep 主页: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s 只能使用 %s 匹配语法"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "指定了互相冲突的比较程序"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "无效的比较 %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "未知的设备处理方法"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "无效的最大计数"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "未知的二进制文件类型"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "--mmap 选项从2010 年起已不再是操作符了"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr "-P 选项的支持未编译入 --disable-perl-regexp binary"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P 选项仅支持单一匹配字词"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "内部错误"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "超过PCRE 的行长度限制"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "超过PCRE 的回溯限制"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "内部错误"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATTERN 是一个可扩展的正则表达式(缩写为 ERE)。\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "‘egrep’已不再使用了;请用‘grep -E’代替。\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATTERN 是一组由断行符分隔的定长字符串。\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "‘fgrep’已不再使用了;请用 ‘grep -F’代替。\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s 只能使用 %s 匹配语法"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "--mmap 选项从2010 年起已不再是操作符了"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "未定义重复次数"
 
index 4a00ddc..7963c78 100644 (file)
Binary files a/po/zh_TW.gmo and b/po/zh_TW.gmo differ
index e119695..e218dc0 100644 (file)
@@ -10,7 +10,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: grep 2.14\n"
 "Report-Msgid-Bugs-To: bug-grep@gnu.org\n"
-"POT-Creation-Date: 2014-01-01 20:44-0800\n"
+"POT-Creation-Date: 2014-05-22 21:06-0700\n"
 "PO-Revision-Date: 2013-03-19 00:10+1000\n"
 "Last-Translator: Wei-Lun Chao <bluebat@member.fsf.org>\n"
 "Language-Team: Chinese (traditional) <zh-l10n@linux.org.tw>\n"
@@ -34,7 +34,7 @@ msgstr "%2$s 的引數 %1$s 不明確"
 msgid "Valid arguments are:"
 msgstr "有效的引數為:"
 
-#: lib/closeout.c:112 src/main.c:954
+#: lib/closeout.c:112 src/grep.c:949
 #, c-format
 msgid "write error"
 msgstr "寫入發生錯誤"
@@ -98,8 +98,8 @@ msgstr "%s: 選項 \"-W %s\" 不接受引數\n"
 msgid "%s: option '-W %s' requires an argument\n"
 msgstr "%s: 選項 \"-W %s\" 需要一個引數\n"
 
-#: lib/obstack.c:413 lib/obstack.c:415 lib/xalloc-die.c:34 src/kwset.c:178
-#: src/kwset.c:186 src/kwset.c:409 src/pcresearch.c:191
+#: lib/obstack.c:416 lib/obstack.c:418 lib/xalloc-die.c:34
+#: src/pcresearch.c:177
 #, c-format
 msgid "memory exhausted"
 msgstr "記憶體用盡"
@@ -183,7 +183,7 @@ msgstr "沒有對應的 ( 或 \\("
 msgid "Unmatched \\{"
 msgstr "沒有對應的 \\{"
 
-#: lib/regcomp.c:161 src/dfa.c:1374
+#: lib/regcomp.c:161 src/dfa.c:1412
 msgid "Invalid content of \\{\\}"
 msgstr "無效的 \\{\\} 內容"
 
@@ -203,7 +203,7 @@ msgstr "無效的前置正規表示式"
 msgid "Premature end of regular expression"
 msgstr "正規表示式過早結束"
 
-#: lib/regcomp.c:176 src/dfa.c:1377
+#: lib/regcomp.c:176 src/dfa.c:1415
 msgid "Regular expression too big"
 msgstr "正規表示式過長"
 
@@ -359,7 +359,7 @@ msgstr ""
 #. for this package.  Please add _another line_ saying
 #. "Report translation bugs to <...>\n" with the address for translation
 #. bugs (typically your translation team's web or email address).
-#: lib/version-etc.c:245 src/main.c:1637
+#: lib/version-etc.c:245 src/grep.c:1624
 #, c-format
 msgid ""
 "\n"
@@ -383,7 +383,7 @@ msgstr "%s 首頁: <%s>\n"
 msgid "%s home page: <http://www.gnu.org/software/%s/>\n"
 msgstr "%s 首頁: <http://www.gnu.org/software/%s/>\n"
 
-#: lib/version-etc.c:256 src/main.c:1640
+#: lib/version-etc.c:256 src/grep.c:1627
 msgid "General help using GNU software: <http://www.gnu.org/gethelp/>\n"
 msgstr "GNU 軟體用法的一般說明: <http://www.gnu.org/gethelp/>\n"
 
@@ -402,125 +402,102 @@ msgstr "%s%s 引數 \"%s\" 中有無效的尾綴"
 msgid "%s%s argument '%s' too large"
 msgstr "%s%s 引數 \"%s\" 過大"
 
-#: src/dfa.c:956 src/dfa.c:959 src/dfa.c:979 src/dfa.c:989 src/dfa.c:1001
-#: src/dfa.c:1052 src/dfa.c:1061 src/dfa.c:1064 src/dfa.c:1069 src/dfa.c:1082
-#: src/dfa.c:1138
+#: src/dfa.c:1017 src/dfa.c:1020 src/dfa.c:1039 src/dfa.c:1049 src/dfa.c:1061
+#: src/dfa.c:1097 src/dfa.c:1106 src/dfa.c:1109 src/dfa.c:1114 src/dfa.c:1128
+#: src/dfa.c:1174
 msgid "unbalanced ["
 msgstr "不對稱的 ["
 
-#: src/dfa.c:1010
+#: src/dfa.c:1073
 msgid "invalid character class"
 msgstr "無效的字元類別"
 
-#: src/dfa.c:1175
+#: src/dfa.c:1217
 msgid "character class syntax is [[:space:]], not [:space:]"
 msgstr "字元類別的語法為 [[:space:]], 非 [:space:]"
 
-#: src/dfa.c:1227
+#: src/dfa.c:1265
 msgid "unfinished \\ escape"
 msgstr "不完整的 \\ 逸出"
 
-#: src/dfa.c:1794
+#: src/dfa.c:1845
 msgid "unbalanced ("
 msgstr "不對稱的 ("
 
-#: src/dfa.c:1920
+#: src/dfa.c:1971
 msgid "no syntax specified"
 msgstr "沒有指定的語法"
 
-#: src/dfa.c:1928
+#: src/dfa.c:1979
 msgid "unbalanced )"
 msgstr "不對稱的 )"
 
-#: src/egrep.c:16
-msgid "PATTERN is an extended regular expression (ERE).\n"
-msgstr "PATTERN 是一個延伸正規表示式 (ERE)。\n"
-
-#: src/egrep.c:18
-msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
-msgstr "\"egrep\" 的呼叫方式已被廢除; 請用 \"grep -E\" 代替。\n"
-
-#: src/fgrep.c:10
-msgid "PATTERN is a set of newline-separated fixed strings.\n"
-msgstr "PATTERN 是一組以換列分隔開的固定字串。\n"
-
-#: src/fgrep.c:12
-msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
-msgstr "\"fgrep\" 的呼叫方式已被廢除; 請用 \"grep -F\" 代替。\n"
-
-#: src/grep.c:32
-msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
-msgstr "PATTERN 原則上是一個基本正規表示式 (BRE)。\n"
-
-#: src/grep.c:34
-msgid ""
-"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
-"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
-msgstr ""
-"\"egrep\" 等同於 \"grep -E\".  \"fgrep\" 等同於 \"grep -F\"。\n"
-"直接呼叫 \"egrep\" 或 \"fgrep\" 的做法已被廢除。\n"
-
 #. This is a proper name. See the gettext manual, section Names.
-#: src/main.c:57
+#: src/grep.c:57
 msgid "Mike Haertel"
 msgstr "Mike Haertel"
 
-#: src/main.c:58
+#: src/grep.c:58
 msgid "others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 msgstr "其他作者,請見 <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>"
 
-#: src/main.c:500
+#: src/grep.c:502
 msgid "invalid context length argument"
 msgstr "無效的內容列數值"
 
-#: src/main.c:569
+#: src/grep.c:571
 msgid "lseek failed"
 msgstr "lseek 失敗"
 
-#: src/main.c:707
+#: src/grep.c:704
 #, c-format
 msgid "input is too large to count"
 msgstr "輸入過長無法計數"
 
-#: src/main.c:1273
+#: src/grep.c:1261
 #, c-format
 msgid "Binary file %s matches\n"
 msgstr "二進位格式檔案 %s 符合\n"
 
-#: src/main.c:1316
+#: src/grep.c:1304
 #, c-format
 msgid "warning: %s: %s"
 msgstr "警告: %s: %s"
 
-#: src/main.c:1317
+#: src/grep.c:1305
 msgid "recursive directory loop"
 msgstr "遞迴的目錄結構"
 
-#: src/main.c:1465
+#: src/grep.c:1453
 #, c-format
 msgid "input file %s is also the output"
 msgstr "輸入檔 %s 也是輸出對象"
 
-#: src/main.c:1523
+#: src/grep.c:1511
 msgid "(standard input)"
 msgstr "(標準輸入)"
 
-#: src/main.c:1539 src/main.c:1546
+#: src/grep.c:1527 src/grep.c:1534
 #, c-format
 msgid "Usage: %s [OPTION]... PATTERN [FILE]...\n"
 msgstr "用法: %s [選項]… PATTERN [檔案]…\n"
 
-#: src/main.c:1541
+#: src/grep.c:1529
 #, c-format
 msgid "Try '%s --help' for more information.\n"
 msgstr "請使用 \"%s --help\" 以閱讀更多的資訊。\n"
 
-#: src/main.c:1547
+#: src/grep.c:1535
 #, c-format
 msgid "Search for PATTERN in each FILE or standard input.\n"
 msgstr "對每個 檔案 或標準輸入搜尋 PATTERN。\n"
 
-#: src/main.c:1550
+#: src/grep.c:1536
+#, c-format
+msgid "PATTERN is, by default, a basic regular expression (BRE).\n"
+msgstr "PATTERN 原則上是一個基本正規表示式 (BRE)。\n"
+
+#: src/grep.c:1537
 #, c-format
 msgid ""
 "Example: %s -i 'hello world' menu.h main.c\n"
@@ -531,7 +508,7 @@ msgstr ""
 "\n"
 "正規表示式選項及解釋:\n"
 
-#: src/main.c:1555
+#: src/grep.c:1541
 #, c-format
 msgid ""
 "  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n"
@@ -545,7 +522,7 @@ msgstr ""
 "  -G, --basic-regexp        PATTERN 是一個基本正規表示式 (BRE)\n"
 "  -P, --perl-regexp         PATTERN 是一個 Perl 的正規表示式\n"
 
-#: src/main.c:1561
+#: src/grep.c:1547
 #, c-format
 msgid ""
 "  -e, --regexp=PATTERN      use PATTERN for matching\n"
@@ -562,16 +539,15 @@ msgstr ""
 "  -x, --line-regexp         限制整列符合 PATTERN\n"
 "  -z, --null-data           設定資料列結尾為空白位元組,非換列符號\n"
 
-#: src/main.c:1568
-#, c-format
+#: src/grep.c:1554
+#, fuzzy, c-format
 msgid ""
 "\n"
 "Miscellaneous:\n"
 "  -s, --no-messages         suppress error messages\n"
 "  -v, --invert-match        select non-matching lines\n"
-"  -V, --version             print version information and exit\n"
-"      --help                display this help and exit\n"
-"      --mmap                deprecated no-op; evokes a warning\n"
+"  -V, --version             display version information and exit\n"
+"      --help                display this help text and exit\n"
 msgstr ""
 "\n"
 "雜項:\n"
@@ -581,7 +557,7 @@ msgstr ""
 "      --help                顯示此說明然後結束\n"
 "      --mmap                已廢除,無作用;會誘發警告\n"
 
-#: src/main.c:1576
+#: src/grep.c:1561
 #, c-format
 msgid ""
 "\n"
@@ -605,7 +581,7 @@ msgstr ""
 "  -h, --no-filename         抑制輸出列的檔名前綴\n"
 "      --label=LABEL         以 LABEL 作標準輸入的檔名前綴\n"
 
-#: src/main.c:1587
+#: src/grep.c:1572
 #, c-format
 msgid ""
 "  -o, --only-matching       show only the part of a line matching PATTERN\n"
@@ -621,7 +597,7 @@ msgstr ""
 "\"\n"
 "  -a, --text                等同於 --binary-files=text\n"
 
-#: src/main.c:1594
+#: src/grep.c:1579
 #, c-format
 msgid ""
 "  -I                        equivalent to --binary-files=without-match\n"
@@ -639,7 +615,7 @@ msgstr ""
 "                            ACTION 為 \"read\" 或 \"skip\"\n"
 "  -R, -r, --recursive       等同於 --directories=recurse\n"
 
-#: src/main.c:1603
+#: src/grep.c:1588
 #, c-format
 msgid ""
 "      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n"
@@ -654,7 +630,7 @@ msgstr ""
 "      --exclude-from=FILE     跳過檔名符合 FILE 中樣式的檔案\n"
 "      --exclude-dir=PATTERN   跳過名字符合 PATTERN 的檔案目錄。\n"
 
-#: src/main.c:1609
+#: src/grep.c:1594
 #, c-format
 msgid ""
 "  -L, --files-without-match  print only names of FILEs containing no match\n"
@@ -669,7 +645,7 @@ msgstr ""
 "  -T, --initial-tab         (需要時) 對齊欄標符號\n"
 "  -Z, --null                在 檔案 名稱後印出空白位元組\n"
 
-#: src/main.c:1615
+#: src/grep.c:1600
 #, c-format
 msgid ""
 "\n"
@@ -684,7 +660,7 @@ msgstr ""
 "  -A, --after-context=NUM   印出 NUM 列的後文\n"
 "  -C, --context=NUM         印出 NUM 列的內容\n"
 
-#: src/main.c:1622
+#: src/grep.c:1607
 #, c-format
 msgid ""
 "  -NUM                      same as --context=NUM\n"
@@ -706,7 +682,16 @@ msgstr ""
 "                            (MSDOS/Windows)\n"
 "\n"
 
-#: src/main.c:1632
+#: src/grep.c:1616
+#, c-format
+msgid ""
+"'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n"
+"Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"
+msgstr ""
+"\"egrep\" 等同於 \"grep -E\".  \"fgrep\" 等同於 \"grep -F\"。\n"
+"直接呼叫 \"egrep\" 或 \"fgrep\" 的做法已被廢除。\n"
+
+#: src/grep.c:1619
 #, c-format
 msgid ""
 "When FILE is -, read standard input.  With no FILE, read . if a command-"
@@ -720,92 +705,100 @@ msgstr ""
 "如果有符合的行列時,結束狀態為 0,否則為 1;\n"
 "如果有任何錯誤且沒有採用 -q 選項時,結束狀態則為 2。\n"
 
-#: src/main.c:1638
+#: src/grep.c:1625
 #, c-format
 msgid "GNU Grep home page: <%s>\n"
 msgstr "GNU Grep 首頁: <%s>\n"
 
-#: src/main.c:1670
-#, c-format
-msgid "%s can only use the %s pattern syntax"
-msgstr "%s 只能使用 %s 樣式的語法"
-
-#: src/main.c:1673
+#: src/grep.c:1691
 #, c-format
 msgid "conflicting matchers specified"
 msgstr "指定了互相衝突的配對選項"
 
-#: src/main.c:1687
+#: src/grep.c:1702
 #, c-format
 msgid "invalid matcher %s"
 msgstr "無效的配對選項 %s"
 
-#: src/main.c:1940
+#: src/grep.c:2010
 #, c-format
 msgid "unknown devices method"
 msgstr "未知的裝置方法"
 
-#: src/main.c:2071
+#: src/grep.c:2137
 #, c-format
 msgid "invalid max count"
 msgstr "無效的最大計次"
 
-#: src/main.c:2128
+#: src/grep.c:2194
 #, c-format
 msgid "unknown binary-files type"
 msgstr "未知的二進位檔案類別"
 
-#: src/main.c:2187
-#, c-format
-msgid "the --mmap option has been a no-op since 2010"
-msgstr "--mmap 選項自 2010 年起已經沒有任何效用"
-
-#: src/pcresearch.c:51
+#: src/pcresearch.c:48
 msgid ""
 "support for the -P option is not compiled into this --disable-perl-regexp "
 "binary"
 msgstr "-P 選項的支援沒有被編譯進此 --disable-perl-regexp 的二進位檔案"
 
-#: src/pcresearch.c:74
+#: src/pcresearch.c:64
 #, c-format
 msgid "the -P option only supports a single pattern"
 msgstr "-P 選項只支援單一樣式"
 
-#: src/pcresearch.c:120
+#: src/pcresearch.c:110
 #, c-format
 msgid "internal error (should never happen)"
 msgstr ""
 
-#: src/pcresearch.c:130
+#: src/pcresearch.c:120
 #, c-format
 msgid "failed to allocate memory for the PCRE JIT stack"
 msgstr ""
 
-#: src/pcresearch.c:144
+#: src/pcresearch.c:134
 #, c-format
 msgid "internal error"
 msgstr "內部錯誤"
 
-#: src/pcresearch.c:176
+#: src/pcresearch.c:162
 #, c-format
 msgid "exceeded PCRE's line length limit"
 msgstr "已超過 PCRE 的字數上限"
 
-#: src/pcresearch.c:195
+#: src/pcresearch.c:181
 #, c-format
 msgid "exceeded PCRE's backtracking limit"
 msgstr "已超過 PCRE 的回溯上限"
 
-#: src/pcresearch.c:199
+#: src/pcresearch.c:185
 #, c-format
 msgid "invalid UTF-8 byte sequence in input"
 msgstr ""
 
-#: src/pcresearch.c:206
+#: src/pcresearch.c:192
 #, fuzzy, c-format
 msgid "internal PCRE error: %d"
 msgstr "內部錯誤"
 
+#~ msgid "PATTERN is an extended regular expression (ERE).\n"
+#~ msgstr "PATTERN 是一個延伸正規表示式 (ERE)。\n"
+
+#~ msgid "Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n"
+#~ msgstr "\"egrep\" 的呼叫方式已被廢除; 請用 \"grep -E\" 代替。\n"
+
+#~ msgid "PATTERN is a set of newline-separated fixed strings.\n"
+#~ msgstr "PATTERN 是一組以換列分隔開的固定字串。\n"
+
+#~ msgid "Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n"
+#~ msgstr "\"fgrep\" 的呼叫方式已被廢除; 請用 \"grep -F\" 代替。\n"
+
+#~ msgid "%s can only use the %s pattern syntax"
+#~ msgstr "%s 只能使用 %s 樣式的語法"
+
+#~ msgid "the --mmap option has been a no-op since 2010"
+#~ msgstr "--mmap 選項自 2010 年起已經沒有任何效用"
+
 #~ msgid "unfinished repeat count"
 #~ msgstr "未完成的重複計次"
 
index 9283d1a..e2c82a4 100644 (file)
@@ -21,15 +21,13 @@ AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
 # Tell the linker to omit references to unused shared libraries.
 AM_LDFLAGS = $(IGNORE_UNUSED_LIBRARIES_CFLAGS)
 
-bin_PROGRAMS = grep egrep fgrep
-grep_SOURCES  = grep.c
-egrep_SOURCES = egrep.c
-fgrep_SOURCES = fgrep.c
-noinst_HEADERS = grep.h dfa.h kwset.h search.h system.h mbsupport.h
-
-noinst_LIBRARIES = libgrep.a
-libgrep_a_SOURCES = kwset.c dfa.c searchutils.c dfasearch.c kwsearch.c \
-       pcresearch.c main.c
+bin_PROGRAMS = grep
+bin_SCRIPTS = egrep fgrep
+grep_SOURCES = grep.c searchutils.c \
+          dfa.c dfasearch.c \
+          kwset.c kwsearch.c \
+          pcresearch.c
+noinst_HEADERS = grep.h dfa.h kwset.h search.h system.h
 
 # Sometimes, the expansion of $(LIBINTL) includes -lc which may
 # include modules defining variables like 'optind', so libgreputils.a
@@ -37,7 +35,6 @@ libgrep_a_SOURCES = kwset.c dfa.c searchutils.c dfasearch.c kwsearch.c \
 # But libgreputils.a must also follow $(LIBINTL), since libintl uses
 # replacement functions defined in libgreputils.a.
 LDADD = \
-  libgrep.a \
   ../lib/libgreputils.a $(LIBINTL) ../lib/libgreputils.a $(LIBICONV) \
   $(LIBTHREAD)
 
@@ -45,4 +42,22 @@ grep_LDADD = $(LDADD) $(LIB_PCRE)
 localedir = $(datadir)/locale
 AM_CPPFLAGS = -I$(top_builddir)/lib -I$(top_srcdir)/lib
 
-EXTRA_DIST = dosbuf.c
+EXTRA_DIST = dosbuf.c egrep.sh
+
+egrep fgrep: egrep.sh Makefile
+       $(AM_V_GEN)grep=`echo grep | sed -e '$(transform)'`     && \
+       case $@ in egrep) option=-E;; fgrep) option=-F;; esac   && \
+       shell_does_substrings='set x/y && d=$${1%/*} && test "$$d" = x' && \
+       if $(SHELL) -c "$$shell_does_substrings" 2>/dev/null; then \
+         edit_substring='s,X,X,'; \
+       else \
+         edit_substring='s,\$${0%/\*},`expr "X$$0" : '\''X\\(.*\\)/'\''`,g'; \
+       fi && \
+       sed -e 's|[@]SHELL@|$(SHELL)|g' \
+           -e "$$edit_substring" \
+           -e "s|[@]grep@|$$grep|g" \
+           -e "s|[@]option@|$$option|g" <$(srcdir)/egrep.sh >$@-t
+       $(AM_V_at)chmod +x $@-t
+       $(AM_V_at)mv $@-t $@
+
+CLEANFILES = egrep fgrep *-t
index 83a12b4..ebab52d 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -94,7 +94,7 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-bin_PROGRAMS = grep$(EXEEXT) egrep$(EXEEXT) fgrep$(EXEEXT)
+bin_PROGRAMS = grep$(EXEEXT)
 subdir = src
 DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
        $(top_srcdir)/build-aux/depcomp $(noinst_HEADERS)
@@ -198,38 +198,45 @@ mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
-LIBRARIES = $(noinst_LIBRARIES)
-AM_V_AR = $(am__v_AR_@AM_V@)
-am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
-am__v_AR_0 = @echo "  AR      " $@;
-am__v_AR_1 = 
-libgrep_a_AR = $(AR) $(ARFLAGS)
-libgrep_a_LIBADD =
-am_libgrep_a_OBJECTS = kwset.$(OBJEXT) dfa.$(OBJEXT) \
-       searchutils.$(OBJEXT) dfasearch.$(OBJEXT) kwsearch.$(OBJEXT) \
-       pcresearch.$(OBJEXT) main.$(OBJEXT)
-libgrep_a_OBJECTS = $(am_libgrep_a_OBJECTS)
-am__installdirs = "$(DESTDIR)$(bindir)"
+am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(bindir)"
 PROGRAMS = $(bin_PROGRAMS)
-am_egrep_OBJECTS = egrep.$(OBJEXT)
-egrep_OBJECTS = $(am_egrep_OBJECTS)
-egrep_LDADD = $(LDADD)
-am__DEPENDENCIES_1 =
-egrep_DEPENDENCIES = libgrep.a ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
-am_fgrep_OBJECTS = fgrep.$(OBJEXT)
-fgrep_OBJECTS = $(am_fgrep_OBJECTS)
-fgrep_LDADD = $(LDADD)
-fgrep_DEPENDENCIES = libgrep.a ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
-am_grep_OBJECTS = grep.$(OBJEXT)
+am_grep_OBJECTS = grep.$(OBJEXT) searchutils.$(OBJEXT) dfa.$(OBJEXT) \
+       dfasearch.$(OBJEXT) kwset.$(OBJEXT) kwsearch.$(OBJEXT) \
+       pcresearch.$(OBJEXT)
 grep_OBJECTS = $(am_grep_OBJECTS)
-am__DEPENDENCIES_2 = libgrep.a ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) ../lib/libgreputils.a \
-       $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
+am__DEPENDENCIES_1 =
+am__DEPENDENCIES_2 = ../lib/libgreputils.a $(am__DEPENDENCIES_1) \
+       ../lib/libgreputils.a $(am__DEPENDENCIES_1) \
+       $(am__DEPENDENCIES_1)
 grep_DEPENDENCIES = $(am__DEPENDENCIES_2) $(am__DEPENDENCIES_1)
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+SCRIPTS = $(bin_SCRIPTS)
 AM_V_P = $(am__v_P_@AM_V@)
 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
 am__v_P_0 = false
@@ -259,10 +266,8 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@)
 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
 am__v_CCLD_0 = @echo "  CCLD    " $@;
 am__v_CCLD_1 = 
-SOURCES = $(libgrep_a_SOURCES) $(egrep_SOURCES) $(fgrep_SOURCES) \
-       $(grep_SOURCES)
-DIST_SOURCES = $(libgrep_a_SOURCES) $(egrep_SOURCES) $(fgrep_SOURCES) \
-       $(grep_SOURCES)
+SOURCES = $(grep_SOURCES)
+DIST_SOURCES = $(grep_SOURCES)
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -1059,6 +1064,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -1148,14 +1154,13 @@ AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
 
 # Tell the linker to omit references to unused shared libraries.
 AM_LDFLAGS = $(IGNORE_UNUSED_LIBRARIES_CFLAGS)
-grep_SOURCES = grep.c
-egrep_SOURCES = egrep.c
-fgrep_SOURCES = fgrep.c
-noinst_HEADERS = grep.h dfa.h kwset.h search.h system.h mbsupport.h
-noinst_LIBRARIES = libgrep.a
-libgrep_a_SOURCES = kwset.c dfa.c searchutils.c dfasearch.c kwsearch.c \
-       pcresearch.c main.c
+bin_SCRIPTS = egrep fgrep
+grep_SOURCES = grep.c searchutils.c \
+          dfa.c dfasearch.c \
+          kwset.c kwsearch.c \
+          pcresearch.c
 
+noinst_HEADERS = grep.h dfa.h kwset.h search.h system.h
 
 # Sometimes, the expansion of $(LIBINTL) includes -lc which may
 # include modules defining variables like 'optind', so libgreputils.a
@@ -1163,13 +1168,13 @@ libgrep_a_SOURCES = kwset.c dfa.c searchutils.c dfasearch.c kwsearch.c \
 # But libgreputils.a must also follow $(LIBINTL), since libintl uses
 # replacement functions defined in libgreputils.a.
 LDADD = \
-  libgrep.a \
   ../lib/libgreputils.a $(LIBINTL) ../lib/libgreputils.a $(LIBICONV) \
   $(LIBTHREAD)
 
 grep_LDADD = $(LDADD) $(LIB_PCRE)
 AM_CPPFLAGS = -I$(top_builddir)/lib -I$(top_srcdir)/lib
-EXTRA_DIST = dosbuf.c
+EXTRA_DIST = dosbuf.c egrep.sh
+CLEANFILES = egrep fgrep *-t
 all: all-am
 
 .SUFFIXES:
@@ -1186,7 +1191,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --gnu src/Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -1204,14 +1208,6 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
        cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
-
-clean-noinstLIBRARIES:
-       -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
-
-libgrep.a: $(libgrep_a_OBJECTS) $(libgrep_a_DEPENDENCIES) $(EXTRA_libgrep_a_DEPENDENCIES) 
-       $(AM_V_at)-rm -f libgrep.a
-       $(AM_V_AR)$(libgrep_a_AR) libgrep.a $(libgrep_a_OBJECTS) $(libgrep_a_LIBADD)
-       $(AM_V_at)$(RANLIB) libgrep.a
 install-binPROGRAMS: $(bin_PROGRAMS)
        @$(NORMAL_INSTALL)
        @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
@@ -1255,17 +1251,44 @@ uninstall-binPROGRAMS:
 clean-binPROGRAMS:
        -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
 
-egrep$(EXEEXT): $(egrep_OBJECTS) $(egrep_DEPENDENCIES) $(EXTRA_egrep_DEPENDENCIES) 
-       @rm -f egrep$(EXEEXT)
-       $(AM_V_CCLD)$(LINK) $(egrep_OBJECTS) $(egrep_LDADD) $(LIBS)
-
-fgrep$(EXEEXT): $(fgrep_OBJECTS) $(fgrep_DEPENDENCIES) $(EXTRA_fgrep_DEPENDENCIES) 
-       @rm -f fgrep$(EXEEXT)
-       $(AM_V_CCLD)$(LINK) $(fgrep_OBJECTS) $(fgrep_LDADD) $(LIBS)
-
 grep$(EXEEXT): $(grep_OBJECTS) $(grep_DEPENDENCIES) $(EXTRA_grep_DEPENDENCIES) 
        @rm -f grep$(EXEEXT)
        $(AM_V_CCLD)$(LINK) $(grep_OBJECTS) $(grep_LDADD) $(LIBS)
+install-binSCRIPTS: $(bin_SCRIPTS)
+       @$(NORMAL_INSTALL)
+       @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \
+       if test -n "$$list"; then \
+         echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
+         $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
+       fi; \
+       for p in $$list; do \
+         if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+         if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \
+       done | \
+       sed -e 'p;s,.*/,,;n' \
+           -e 'h;s|.*|.|' \
+           -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \
+       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \
+         { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+           if ($$2 == $$4) { files[d] = files[d] " " $$1; \
+             if (++n[d] == $(am__install_max)) { \
+               print "f", d, files[d]; n[d] = 0; files[d] = "" } } \
+           else { print "f", d "/" $$4, $$1 } } \
+         END { for (d in files) print "f", d, files[d] }' | \
+       while read type dir files; do \
+            if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+            test -z "$$files" || { \
+              echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \
+              $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
+            } \
+       ; done
+
+uninstall-binSCRIPTS:
+       @$(NORMAL_UNINSTALL)
+       @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \
+       files=`for p in $$list; do echo "$$p"; done | \
+              sed -e 's,.*/,,;$(transform)'`; \
+       dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir)
 
 mostlyclean-compile:
        -rm -f *.$(OBJEXT)
@@ -1275,12 +1298,9 @@ distclean-compile:
 
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dfa.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dfasearch.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/egrep.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fgrep.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/grep.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kwsearch.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kwset.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcresearch.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/searchutils.Po@am__quote@
 
@@ -1384,9 +1404,9 @@ distdir: $(DISTFILES)
        done
 check-am: all-am
 check: check-am
-all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(HEADERS)
+all-am: Makefile $(PROGRAMS) $(SCRIPTS) $(HEADERS)
 installdirs:
-       for dir in "$(DESTDIR)$(bindir)"; do \
+       for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(bindir)"; do \
          test -z "$$dir" || $(MKDIR_P) "$$dir"; \
        done
 install: install-am
@@ -1411,6 +1431,7 @@ install-strip:
 mostlyclean-generic:
 
 clean-generic:
+       -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
 
 distclean-generic:
        -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
@@ -1421,8 +1442,7 @@ maintainer-clean-generic:
        @echo "it deletes files that may require special tools to rebuild."
 clean: clean-am
 
-clean-am: clean-binPROGRAMS clean-generic clean-noinstLIBRARIES \
-       mostlyclean-am
+clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
 
 distclean: distclean-am
        -rm -rf ./$(DEPDIR)
@@ -1448,7 +1468,7 @@ install-dvi: install-dvi-am
 
 install-dvi-am:
 
-install-exec-am: install-binPROGRAMS
+install-exec-am: install-binPROGRAMS install-binSCRIPTS
 
 install-html: install-html-am
 
@@ -1487,24 +1507,42 @@ ps: ps-am
 
 ps-am:
 
-uninstall-am: uninstall-binPROGRAMS
+uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS
 
 .MAKE: install-am install-strip
 
 .PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \
-       clean-binPROGRAMS clean-generic clean-noinstLIBRARIES \
-       cscopelist-am ctags ctags-am distclean distclean-compile \
-       distclean-generic distclean-tags distdir dvi dvi-am html \
-       html-am info info-am install install-am install-binPROGRAMS \
-       install-data install-data-am install-dvi install-dvi-am \
-       install-exec install-exec-am install-html install-html-am \
-       install-info install-info-am install-man install-pdf \
-       install-pdf-am install-ps install-ps-am install-strip \
-       installcheck installcheck-am installdirs maintainer-clean \
+       clean-binPROGRAMS clean-generic cscopelist-am ctags ctags-am \
+       distclean distclean-compile distclean-generic distclean-tags \
+       distdir dvi dvi-am html html-am info info-am install \
+       install-am install-binPROGRAMS install-binSCRIPTS install-data \
+       install-data-am install-dvi install-dvi-am install-exec \
+       install-exec-am install-html install-html-am install-info \
+       install-info-am install-man install-pdf install-pdf-am \
+       install-ps install-ps-am install-strip installcheck \
+       installcheck-am installdirs maintainer-clean \
        maintainer-clean-generic mostlyclean mostlyclean-compile \
        mostlyclean-generic pdf pdf-am ps ps-am tags tags-am uninstall \
-       uninstall-am uninstall-binPROGRAMS
+       uninstall-am uninstall-binPROGRAMS uninstall-binSCRIPTS
+
+.PRECIOUS: Makefile
+
 
+egrep fgrep: egrep.sh Makefile
+       $(AM_V_GEN)grep=`echo grep | sed -e '$(transform)'`     && \
+       case $@ in egrep) option=-E;; fgrep) option=-F;; esac   && \
+       shell_does_substrings='set x/y && d=$${1%/*} && test "$$d" = x' && \
+       if $(SHELL) -c "$$shell_does_substrings" 2>/dev/null; then \
+         edit_substring='s,X,X,'; \
+       else \
+         edit_substring='s,\$${0%/\*},`expr "X$$0" : '\''X\\(.*\\)/'\''`,g'; \
+       fi && \
+       sed -e 's|[@]SHELL@|$(SHELL)|g' \
+           -e "$$edit_substring" \
+           -e "s|[@]grep@|$$grep|g" \
+           -e "s|[@]option@|$$option|g" <$(srcdir)/egrep.sh >$@-t
+       $(AM_V_at)chmod +x $@-t
+       $(AM_V_at)mv $@-t $@
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
index 6ab4e05..8ff29d0 100644 (file)
--- a/src/dfa.c
+++ b/src/dfa.c
 #include <assert.h>
 #include <ctype.h>
 #include <stdio.h>
-#include <stddef.h>
 #include <stdlib.h>
 #include <limits.h>
 #include <string.h>
 #include <locale.h>
-#include <stdbool.h>
 
 #define STREQ(a, b) (strcmp (a, b) == 0)
 
    host does not conform to Posix.  */
 #define ISASCIIDIGIT(c) ((unsigned) (c) - '0' <= 9)
 
-/* gettext.h ensures that we don't use gettext if ENABLE_NLS is not defined */
 #include "gettext.h"
 #define _(str) gettext (str)
 
-#include "mbsupport.h" /* Define MBS_SUPPORT to 1 or 0, as appropriate.  */
-#if MBS_SUPPORT
-/* We can handle multibyte strings.  */
-# include <wchar.h>
-# include <wctype.h>
-#endif
-
-#if HAVE_LANGINFO_CODESET
-# include <langinfo.h>
-#endif
+#include <wchar.h>
+#include <wctype.h>
 
 #include "xalloc.h"
 
 # undef clrbit
 #endif
 
-/* Number of bits in an unsigned char.  */
-#ifndef CHARBITS
-# define CHARBITS 8
-#endif
-
 /* First integer value that is greater than any character code.  */
-#define NOTCHAR (1 << CHARBITS)
+enum { NOTCHAR = 1 << CHAR_BIT };
 
-/* INTBITS need not be exact, just a lower bound.  */
-#ifndef INTBITS
-# define INTBITS (CHARBITS * sizeof (int))
-#endif
+/* This represents part of a character class.  It must be unsigned and
+   at least CHARCLASS_WORD_BITS wide.  Any excess bits are zero.  */
+typedef unsigned int charclass_word;
 
-/* Number of ints required to hold a bit for every character.  */
-#define CHARCLASS_INTS ((NOTCHAR + INTBITS - 1) / INTBITS)
+/* The number of bits used in a charclass word.  utf8_classes assumes
+   this is exactly 32.  */
+enum { CHARCLASS_WORD_BITS = 32 };
+
+/* The maximum useful value of a charclass_word; all used bits are 1.  */
+#define CHARCLASS_WORD_MASK \
+  (((charclass_word) 1 << (CHARCLASS_WORD_BITS - 1) << 1) - 1)
+
+/* Number of words required to hold a bit for every character.  */
+enum
+{
+  CHARCLASS_WORDS = (NOTCHAR + CHARCLASS_WORD_BITS - 1) / CHARCLASS_WORD_BITS
+};
 
 /* Sets of unsigned characters are stored as bit vectors in arrays of ints.  */
-typedef unsigned int charclass[CHARCLASS_INTS];
+typedef charclass_word charclass[CHARCLASS_WORDS];
 
 /* Convert a possibly-signed character to an unsigned character.  This is
    a bit safer than casting to unsigned char, since it catches some type
    errors that the cast doesn't.  */
-static inline unsigned char
+static unsigned char
 to_uchar (char ch)
 {
   return ch;
@@ -182,7 +176,8 @@ enum
   EMPTY = NOTCHAR,              /* EMPTY is a terminal symbol that matches
                                    the empty string.  */
 
-  BACKREF,                      /* BACKREF is generated by \<digit>; it
+  BACKREF,                      /* BACKREF is generated by \<digit>
+                                   or by any other construct that
                                    is not completely handled.  If the scanner
                                    detects a transition on backref, it returns
                                    a kind of "semi-success" indicating that
@@ -190,27 +185,25 @@ enum
                                    a backtracking matcher.  */
 
   BEGLINE,                      /* BEGLINE is a terminal symbol that matches
-                                   the empty string if it is at the beginning
-                                   of a line.  */
+                                   the empty string at the beginning of a
+                                   line.  */
 
   ENDLINE,                      /* ENDLINE is a terminal symbol that matches
-                                   the empty string if it is at the end of
-                                   a line.  */
+                                   the empty string at the end of a line.  */
 
   BEGWORD,                      /* BEGWORD is a terminal symbol that matches
-                                   the empty string if it is at the beginning
-                                   of a word.  */
+                                   the empty string at the beginning of a
+                                   word.  */
 
   ENDWORD,                      /* ENDWORD is a terminal symbol that matches
-                                   the empty string if it is at the end of
-                                   a word.  */
+                                   the empty string at the end of a word.  */
 
   LIMWORD,                      /* LIMWORD is a terminal symbol that matches
-                                   the empty string if it is at the beginning
-                                   or the end of a word.  */
+                                   the empty string at the beginning or the
+                                   end of a word.  */
 
   NOTLIMWORD,                   /* NOTLIMWORD is a terminal symbol that
-                                   matches the empty string if it is not at
+                                   matches the empty string not at
                                    the beginning or end of a word.  */
 
   QMARK,                        /* QMARK is an operator of one argument that
@@ -291,7 +284,8 @@ typedef struct
   size_t hash;                  /* Hash of the positions of this state.  */
   position_set elems;           /* Positions this state could match.  */
   unsigned char context;        /* Context from previous state.  */
-  char backref;                 /* True if this state matches a \<digit>.  */
+  bool has_backref;            /* This state matches a \<digit>.  */
+  bool has_mbcset;             /* This state matches a MBCSET.  */
   unsigned short constraint;    /* Constraint for this state to accept.  */
   token first_end;              /* Token value of the first END in elems.  */
   position_set mbps;            /* Positions which can match multibyte
@@ -308,13 +302,16 @@ typedef ptrdiff_t state_num;
 struct mb_char_classes
 {
   ptrdiff_t cset;
-  int invert;
+  bool invert;
   wchar_t *chars;               /* Normal characters.  */
   size_t nchars;
   wctype_t *ch_classes;         /* Character classes.  */
   size_t nch_classes;
-  wchar_t *range_sts;           /* Range characters (start of the range).  */
-  wchar_t *range_ends;          /* Range characters (end of the range).  */
+  struct                       /* Range characters.  */
+  {
+    wchar_t beg;               /* Range start.  */
+    wchar_t end;               /* Range end.  */
+  } *ranges;
   size_t nranges;
   char **equivs;                /* Equivalence classes.  */
   size_t nequivs;
@@ -340,10 +337,12 @@ struct dfa
   size_t nleaves;               /* Number of leaves on the parse tree.  */
   size_t nregexps;              /* Count of parallel regexps being built
                                    with dfaparse.  */
-  unsigned int mb_cur_max;      /* Cached value of MB_CUR_MAX.  */
+  bool fast;                   /* The DFA is fast.  */
+  bool multibyte;              /* MB_CUR_MAX > 1.  */
   token utf8_anychar_classes[5]; /* To lower ANYCHAR in UTF-8 locales.  */
+  mbstate_t mbs;               /* Multibyte conversion state.  */
 
-  /* The following are used only if MB_CUR_MAX > 1.  */
+  /* The following are valid only if MB_CUR_MAX > 1.  */
 
   /* The value of multibyte_prop[i] is defined by following rule.
      if tokens[i] < NOTCHAR
@@ -362,18 +361,25 @@ struct dfa
      multibyte_prop
      = 3     , 1               ,  0              ,  2              , 3
    */
-  size_t nmultibyte_prop;
   int *multibyte_prop;
 
+  /* A table indexed by byte values that contains the corresponding wide
+     character (if any) for that byte.  WEOF means the byte is not a
+     valid single-byte character.  */
+  wint_t mbrtowc_cache[NOTCHAR];
+
   /* Array of the bracket expression in the DFA.  */
   struct mb_char_classes *mbcsets;
   size_t nmbcsets;
   size_t mbcsets_alloc;
 
+  /* Fields filled by the superset.  */
+  struct dfa *superset;             /* Hint of the dfa.  */
+
   /* Fields filled by the state builder.  */
   dfa_state *states;            /* States of the dfa.  */
   state_num sindex;             /* Index for adding new states.  */
-  state_num salloc;             /* Number of states currently allocated.  */
+  size_t salloc;               /* Number of states currently allocated.  */
 
   /* Fields filled by the parse tree->NFA conversion.  */
   position_set *follows;        /* Array of follow sets, indexed by position
@@ -383,7 +389,7 @@ struct dfa
                                    matching the given position in a string
                                    matching the regexp.  Allocated to the
                                    maximum possible position index.  */
-  int searchflag;               /* True if we are supposed to build a searching
+  bool searchflag;             /* We are supposed to build a searching
                                    as opposed to an exact matcher.  A searching
                                    matcher finds the first and shortest string
                                    matching a regexp anywhere in the buffer,
@@ -393,16 +399,16 @@ struct dfa
 
   /* Fields filled by dfaexec.  */
   state_num tralloc;            /* Number of transition tables that have
-                                   slots so far.  */
+                                   slots so far, not counting trans[-1].  */
   int trcount;                  /* Number of transition tables that have
                                    actually been built.  */
   state_num **trans;            /* Transition tables for states that can
                                    never accept.  If the transitions for a
                                    state have not yet been computed, or the
                                    state could possibly accept, its entry in
-                                   this table is NULL.  */
-  state_num **realtrans;        /* Trans always points to realtrans + 1; this
-                                   is so trans[-1] can contain NULL.  */
+                                   this table is NULL.  This points to one
+                                   past the start of the allocated array,
+                                   and trans[-1] is always NULL.  */
   state_num **fails;            /* Transition tables after failing to accept
                                    on a state that potentially could do so.  */
   int *success;                 /* Table of acceptance conditions used in
@@ -417,55 +423,77 @@ struct dfa
   struct dfamust *musts;        /* List of strings, at least one of which
                                    is known to appear in any r.e. matching
                                    the dfa.  */
+  position_set mb_follows;     /* Follow set added by ANYCHAR and/or MBCSET
+                                   on demand.  */
+  int *mb_match_lens;           /* Array of length reduced by ANYCHAR and/or
+                                   MBCSET.  Null if mb_follows.elems has not
+                                   been allocated.  */
 };
 
 /* Some macros for user access to dfa internals.  */
 
-/* ACCEPTING returns true if s could possibly be an accepting state of r.  */
+/* S could possibly be an accepting state of R.  */
 #define ACCEPTING(s, r) ((r).states[s].constraint)
 
-/* ACCEPTS_IN_CONTEXT returns true if the given state accepts in the
-   specified context.  */
+/* STATE accepts in the specified context.  */
 #define ACCEPTS_IN_CONTEXT(prev, curr, state, dfa) \
   SUCCEEDS_IN_CONTEXT ((dfa).states[state].constraint, prev, curr)
 
 static void dfamust (struct dfa *dfa);
 static void regexp (void);
 
-/* These two macros are identical to the ones in gnulib's xalloc.h,
-   except that they do not cast the result to "(t *)", and thus may
-   be used via type-free CALLOC and MALLOC macros.  */
-#undef XNMALLOC
-#undef XCALLOC
-
-/* Allocate memory for N elements of type T, with error checking.  */
-/* extern t *XNMALLOC (size_t n, typename t); */
-# define XNMALLOC(n, t) \
-    (sizeof (t) == 1 ? xmalloc (n) : xnmalloc (n, sizeof (t)))
-
-/* Allocate memory for N elements of type T, with error checking,
-   and zero it.  */
-/* extern t *XCALLOC (size_t n, typename t); */
-# define XCALLOC(n, t) \
-    (sizeof (t) == 1 ? xzalloc (n) : xcalloc (n, sizeof (t)))
-
-#define CALLOC(p, n) do { (p) = XCALLOC (n, *(p)); } while (0)
-#define MALLOC(p, n) do { (p) = XNMALLOC (n, *(p)); } while (0)
-#define REALLOC(p, n) do {(p) = xnrealloc (p, n, sizeof (*(p))); } while (0)
-
-/* Reallocate an array of type *P if N_ALLOC is <= N_REQUIRED.  */
-#define REALLOC_IF_NECESSARY(p, n_alloc, n_required)           \
-  do                                                           \
-    {                                                          \
-      if ((n_alloc) <= (n_required))                           \
-        {                                                      \
-          size_t new_n_alloc = (n_required) + !(p);            \
-          (p) = x2nrealloc (p, &new_n_alloc, sizeof (*(p)));   \
-          (n_alloc) = new_n_alloc;                             \
-        }                                                      \
-    }                                                          \
-  while (false)
+static void
+dfambcache (struct dfa *d)
+{
+  int i;
+  for (i = CHAR_MIN; i <= CHAR_MAX; ++i)
+    {
+      char c = i;
+      unsigned char uc = i;
+      mbstate_t s = { 0 };
+      wchar_t wc;
+      d->mbrtowc_cache[uc] = mbrtowc (&wc, &c, 1, &s) <= 1 ? wc : WEOF;
+    }
+}
+
+/* Store into *PWC the result of converting the leading bytes of the
+   multibyte buffer S of length N bytes, using the mbrtowc_cache in *D
+   and updating the conversion state in *D.  On conversion error,
+   convert just a single byte, to WEOF.  Return the number of bytes
+   converted.
+
+   This differs from mbrtowc (PWC, S, N, &D->mbs) as follows:
+
+   * PWC points to wint_t, not to wchar_t.
+   * The last arg is a dfa *D instead of merely a multibyte conversion
+     state D->mbs.  D also contains an mbrtowc_cache for speed.
+   * N must be at least 1.
+   * S[N - 1] must be a sentinel byte.
+   * Shift encodings are not supported.
+   * The return value is always in the range 1..N.
+   * D->mbs is always valid afterwards.
+   * *PWC is always set to something.  */
+static size_t
+mbs_to_wchar (wint_t *pwc, char const *s, size_t n, struct dfa *d)
+{
+  unsigned char uc = s[0];
+  wint_t wc = d->mbrtowc_cache[uc];
 
+  if (wc == WEOF)
+    {
+      wchar_t wch;
+      size_t nbytes = mbrtowc (&wch, s, n, &d->mbs);
+      if (0 < nbytes && nbytes < (size_t) -2)
+        {
+          *pwc = wch;
+          return nbytes;
+        }
+      memset (&d->mbs, 0, sizeof d->mbs);
+    }
+
+  *pwc = wc;
+  return 1;
+}
 
 #ifdef DEBUG
 
@@ -550,19 +578,20 @@ prtok (token t)
 static bool
 tstbit (unsigned int b, charclass const c)
 {
-  return c[b / INTBITS] >> b % INTBITS & 1;
+  return c[b / CHARCLASS_WORD_BITS] >> b % CHARCLASS_WORD_BITS & 1;
 }
 
 static void
 setbit (unsigned int b, charclass c)
 {
-  c[b / INTBITS] |= 1U << b % INTBITS;
+  c[b / CHARCLASS_WORD_BITS] |= (charclass_word) 1 << b % CHARCLASS_WORD_BITS;
 }
 
 static void
 clrbit (unsigned int b, charclass c)
 {
-  c[b / INTBITS] &= ~(1U << b % INTBITS);
+  c[b / CHARCLASS_WORD_BITS] &= ~((charclass_word) 1
+                                  << b % CHARCLASS_WORD_BITS);
 }
 
 static void
@@ -582,40 +611,64 @@ notset (charclass s)
 {
   int i;
 
-  for (i = 0; i < CHARCLASS_INTS; ++i)
-    s[i] = ~s[i];
+  for (i = 0; i < CHARCLASS_WORDS; ++i)
+    s[i] = CHARCLASS_WORD_MASK & ~s[i];
 }
 
-static int
+static bool
 equal (charclass const s1, charclass const s2)
 {
   return memcmp (s1, s2, sizeof (charclass)) == 0;
 }
 
-/* A pointer to the current dfa is kept here during parsing.  */
-static struct dfa *dfa;
+/* Ensure that the array addressed by PTR holds at least NITEMS +
+   (PTR || !NITEMS) items.  Either return PTR, or reallocate the array
+   and return its new address.  Although PTR may be null, the returned
+   value is never null.
 
-/* Find the index of charclass s in dfa->charclasses, or allocate a
-   new charclass.  */
+   The array holds *NALLOC items; *NALLOC is updated on reallocation.
+   ITEMSIZE is the size of one item.  Avoid O(N**2) behavior on arrays
+   growing linearly.  */
+static void *
+maybe_realloc (void *ptr, size_t nitems, size_t *nalloc, size_t itemsize)
+{
+  if (nitems < *nalloc)
+    return ptr;
+  *nalloc = nitems;
+  return x2nrealloc (ptr, nalloc, itemsize);
+}
+
+/* In DFA D, find the index of charclass S, or allocate a new one.  */
 static size_t
-charclass_index (charclass const s)
+dfa_charclass_index (struct dfa *d, charclass const s)
 {
   size_t i;
 
-  for (i = 0; i < dfa->cindex; ++i)
-    if (equal (s, dfa->charclasses[i]))
+  for (i = 0; i < d->cindex; ++i)
+    if (equal (s, d->charclasses[i]))
       return i;
-  REALLOC_IF_NECESSARY (dfa->charclasses, dfa->calloc, dfa->cindex + 1);
-  ++dfa->cindex;
-  copyset (s, dfa->charclasses[i]);
+  d->charclasses = maybe_realloc (d->charclasses, d->cindex, &d->calloc,
+                                  sizeof *d->charclasses);
+  ++d->cindex;
+  copyset (s, d->charclasses[i]);
   return i;
 }
 
+/* A pointer to the current dfa is kept here during parsing.  */
+static struct dfa *dfa;
+
+/* Find the index of charclass S in the current DFA, or allocate a new one.  */
+static size_t
+charclass_index (charclass const s)
+{
+  return dfa_charclass_index (dfa, s);
+}
+
 /* Syntax bits controlling the behavior of the lexical analyzer.  */
 static reg_syntax_t syntax_bits, syntax_bits_set;
 
 /* Flag for case-folding letters into sets.  */
-static int case_fold;
+static bool case_fold;
 
 /* End-of-line byte in data.  */
 static unsigned char eolbyte;
@@ -635,17 +688,17 @@ static charclass newline;
 #ifdef __GLIBC__
 # define is_valid_unibyte_character(c) 1
 #else
-# define is_valid_unibyte_character(c) (! (MBS_SUPPORT && btowc (c) == WEOF))
+# define is_valid_unibyte_character(c) (btowc (c) != WEOF)
 #endif
 
-/* Return non-zero if C is a "word-constituent" byte; zero otherwise.  */
+/* C is a "word-constituent" byte.  */
 #define IS_WORD_CONSTITUENT(C) \
   (is_valid_unibyte_character (C) && (isalnum (C) || (C) == '_'))
 
 static int
 char_context (unsigned char c)
 {
-  if (c == eolbyte || c == 0)
+  if (c == eolbyte)
     return CTX_NEWLINE;
   if (IS_WORD_CONSTITUENT (c))
     return CTX_LETTER;
@@ -670,7 +723,7 @@ dfasyntax (reg_syntax_t bits, int fold, unsigned char eol)
 
   syntax_bits_set = 1;
   syntax_bits = bits;
-  case_fold = fold;
+  case_fold = fold != 0;
   eolbyte = eol;
 
   for (i = 0; i < NOTCHAR; ++i)
@@ -693,7 +746,6 @@ dfasyntax (reg_syntax_t bits, int fold, unsigned char eol)
    this may happen when folding case in weird Turkish locales where
    dotless i/dotted I are not included in the chosen character set.
    Return whether a bit was set in the charclass.  */
-#if MBS_SUPPORT
 static bool
 setbit_wc (wint_t wc, charclass c)
 {
@@ -705,70 +757,75 @@ setbit_wc (wint_t wc, charclass c)
   return true;
 }
 
-/* Set a bit in the charclass for the given single byte character,
-   if it is valid in the current character set.  */
-static void
-setbit_c (int b, charclass c)
-{
-  /* Do nothing if b is invalid in this character set.  */
-  if (MB_CUR_MAX > 1 && btowc (b) == WEOF)
-    return;
-  setbit (b, c);
-}
-#else
-# define setbit_c setbit
-static inline bool
-setbit_wc (wint_t wc, charclass c)
-{
-  abort ();
-   /*NOTREACHED*/ return false;
-}
-#endif
-
-/* Like setbit_c, but if case is folded, set both cases of a letter.  For
-   MB_CUR_MAX > 1, the resulting charset is only used as an optimization,
-   and the caller takes care of setting the appropriate field of struct
-   mb_char_classes.  */
+/* Set a bit for B and its case variants in the charclass C.
+   MB_CUR_MAX must be 1.  */
 static void
 setbit_case_fold_c (int b, charclass c)
 {
-  if (MB_CUR_MAX > 1)
-    {
-      wint_t wc = btowc (b);
-      if (wc == WEOF)
-        return;
-      setbit (b, c);
-      if (case_fold && iswalpha (wc))
-        setbit_wc (iswupper (wc) ? towlower (wc) : towupper (wc), c);
-    }
-  else
-    {
-      setbit (b, c);
-      if (case_fold && isalpha (b))
-        setbit_c (isupper (b) ? tolower (b) : toupper (b), c);
-    }
+  int ub = toupper (b);
+  int i;
+  for (i = 0; i < NOTCHAR; i++)
+    if (toupper (i) == ub)
+      setbit (i, c);
 }
 
 
 
 /* UTF-8 encoding allows some optimizations that we can't otherwise
    assume in a multibyte encoding.  */
-static inline int
+int
 using_utf8 (void)
 {
   static int utf8 = -1;
-  if (utf8 == -1)
+  if (utf8 < 0)
     {
-#if defined HAVE_LANGINFO_CODESET && MBS_SUPPORT
-      utf8 = (STREQ (nl_langinfo (CODESET), "UTF-8"));
-#else
-      utf8 = 0;
-#endif
+      wchar_t wc;
+      mbstate_t mbs = { 0 };
+      utf8 = mbrtowc (&wc, "\xc4\x80", 2, &mbs) == 2 && wc == 0x100;
     }
-
   return utf8;
 }
 
+/* The current locale is known to be a unibyte locale
+   without multicharacter collating sequences and where range
+   comparisons simply use the native encoding.  These locales can be
+   processed more efficiently.  */
+
+static bool
+using_simple_locale (void)
+{
+  /* The native character set is known to be compatible with
+     the C locale.  The following test isn't perfect, but it's good
+     enough in practice, as only ASCII and EBCDIC are in common use
+     and this test correctly accepts ASCII and rejects EBCDIC.  */
+  enum { native_c_charset =
+    ('\b' == 8 && '\t' == 9 && '\n' == 10 && '\v' == 11 && '\f' == 12
+     && '\r' == 13 && ' ' == 32 && '!' == 33 && '"' == 34 && '#' == 35
+     && '%' == 37 && '&' == 38 && '\'' == 39 && '(' == 40 && ')' == 41
+     && '*' == 42 && '+' == 43 && ',' == 44 && '-' == 45 && '.' == 46
+     && '/' == 47 && '0' == 48 && '9' == 57 && ':' == 58 && ';' == 59
+     && '<' == 60 && '=' == 61 && '>' == 62 && '?' == 63 && 'A' == 65
+     && 'Z' == 90 && '[' == 91 && '\\' == 92 && ']' == 93 && '^' == 94
+     && '_' == 95 && 'a' == 97 && 'z' == 122 && '{' == 123 && '|' == 124
+     && '}' == 125 && '~' == 126)
+  };
+
+  if (! native_c_charset || dfa->multibyte)
+    return false;
+  else
+    {
+      static int unibyte_c = -1;
+      if (unibyte_c < 0)
+        {
+          char const *locale = setlocale (LC_ALL, NULL);
+          unibyte_c = (!locale
+                       || STREQ (locale, "C")
+                       || STREQ (locale, "POSIX"));
+        }
+      return unibyte_c;
+    }
+}
+
 /* Lexical analyzer.  All the dross that deals with the obnoxious
    GNU Regex syntax bits is located here.  The poor, suffering
    reader is referred to the GNU Regex documentation for the
@@ -777,39 +834,27 @@ using_utf8 (void)
 static char const *lexptr;      /* Pointer to next input character.  */
 static size_t lexleft;          /* Number of characters remaining.  */
 static token lasttok;           /* Previous token returned; initially END.  */
-static int laststart;           /* True if we're separated from beginning or (,
+static bool laststart;         /* We're separated from beginning or (,
                                    | only by zero-width characters.  */
 static size_t parens;           /* Count of outstanding left parens.  */
 static int minrep, maxrep;      /* Repeat counts for {m,n}.  */
 
 static int cur_mb_len = 1;      /* Length of the multibyte representation of
                                    wctok.  */
-/* These variables are used only if (MB_CUR_MAX > 1).  */
-static mbstate_t mbs;           /* Mbstate for mbrlen.  */
-static wchar_t wctok;           /* Wide character representation of the current
-                                   multibyte character.  */
-static unsigned char *mblen_buf;/* Correspond to the input buffer in dfaexec.
-                                   Each element stores the number of remaining
-                                   bytes of the corresponding multibyte
-                                   character in the input string.  A element's
-                                   value is 0 if the corresponding character is
-                                   single-byte.
-                                   e.g., input : 'a', <mb(0)>, <mb(1)>, <mb(2)>
-                                   mblen_buf   :  0,       3,       2,       1
-                                 */
-static wchar_t *inputwcs;       /* Wide character representation of the input
-                                   string in dfaexec.
-                                   The length of this array is the same as
-                                   the length of input string (char array).
-                                   inputstring[i] is a single-byte char,
-                                   or the first byte of a multibyte char;
-                                   inputwcs[i] is the codepoint.  */
-static unsigned char const *buf_begin;  /* reference to begin in dfaexec.  */
-static unsigned char const *buf_end;    /* reference to end in dfaexec.  */
-
-
-#if MBS_SUPPORT
-/* Note that characters become unsigned here.  */
+
+static wint_t wctok;           /* Wide character representation of the current
+                                   multibyte character, or WEOF if there was
+                                   an encoding error.  Used only if
+                                   MB_CUR_MAX > 1.  */
+
+
+/* Fetch the next lexical input character.  Set C (of type int) to the
+   next input byte, except set C to EOF if the input is a multibyte
+   character of length greater than 1.  Set WC (of type wint_t) to the
+   value of the input if it is a valid multibyte character (possibly
+   of length 1); otherwise set WC to WEOF.  If there is no more input,
+   report EOFERR if EOFERR is not null, and return lasttok = END
+   otherwise.  */
 # define FETCH_WC(c, wc, eoferr)               \
   do {                                         \
     if (! lexleft)                             \
@@ -821,53 +866,67 @@ static unsigned char const *buf_end;    /* reference to end in dfaexec.  */
       }                                                \
     else                                       \
       {                                                \
-        wchar_t _wc;                           \
-        cur_mb_len = mbrtowc (&_wc, lexptr, lexleft, &mbs); \
-        if (cur_mb_len <= 0)                   \
-          {                                    \
-            cur_mb_len = 1;                    \
-            --lexleft;                         \
-            (wc) = (c) = to_uchar (*lexptr++);  \
-          }                                    \
-        else                                   \
-          {                                    \
-            lexptr += cur_mb_len;              \
-            lexleft -= cur_mb_len;             \
-            (wc) = _wc;                                \
-            (c) = wctob (wc);                  \
-          }                                    \
+        wint_t _wc;                            \
+        size_t nbytes = mbs_to_wchar (&_wc, lexptr, lexleft, dfa); \
+        cur_mb_len = nbytes;                   \
+        (wc) = _wc;                            \
+        (c) = nbytes == 1 ? to_uchar (*lexptr) : EOF;    \
+        lexptr += nbytes;                      \
+        lexleft -= nbytes;                     \
       }                                                \
   } while (0)
 
-# define FETCH(c, eoferr)                      \
-  do {                                         \
-    wint_t wc;                                 \
-    FETCH_WC (c, wc, eoferr);                  \
-  } while (0)
-
-#else
-/* Note that characters become unsigned here.  */
-# define FETCH(c, eoferr)            \
-  do {                               \
-    if (! lexleft)                   \
-      {                                      \
-        if ((eoferr) != 0)           \
-          dfaerror (eoferr);         \
-        else                         \
-          return lasttok = END;              \
-      }                                      \
-    (c) = to_uchar (*lexptr++);       \
-    --lexleft;                       \
-  } while (0)
-
-# define FETCH_WC(c, unused, eoferr) FETCH (c, eoferr)
-
-#endif /* MBS_SUPPORT */
-
 #ifndef MIN
 # define MIN(a,b) ((a) < (b) ? (a) : (b))
 #endif
 
+/* The set of wchar_t values C such that there's a useful locale
+   somewhere where C != towupper (C) && C != towlower (towupper (C)).
+   For example, 0x00B5 (U+00B5 MICRO SIGN) is in this table, because
+   towupper (0x00B5) == 0x039C (U+039C GREEK CAPITAL LETTER MU), and
+   towlower (0x039C) == 0x03BC (U+03BC GREEK SMALL LETTER MU).  */
+static short const lonesome_lower[] =
+  {
+    0x00B5, 0x0131, 0x017F, 0x01C5, 0x01C8, 0x01CB, 0x01F2, 0x0345,
+    0x03C2, 0x03D0, 0x03D1, 0x03D5, 0x03D6, 0x03F0, 0x03F1,
+
+    /* U+03F2 GREEK LUNATE SIGMA SYMBOL lacks a specific uppercase
+       counterpart in locales predating Unicode 4.0.0 (April 2003).  */
+    0x03F2,
+
+    0x03F5, 0x1E9B, 0x1FBE,
+  };
+
+/* Maximum number of characters that can be the case-folded
+   counterparts of a single character, not counting the character
+   itself.  This is 1 for towupper, 1 for towlower, and 1 for each
+   entry in LONESOME_LOWER.  */
+enum
+{ CASE_FOLDED_BUFSIZE = 2 + sizeof lonesome_lower / sizeof *lonesome_lower };
+
+/* Find the characters equal to C after case-folding, other than C
+   itself, and store them into FOLDED.  Return the number of characters
+   stored.  */
+static int
+case_folded_counterparts (wchar_t c, wchar_t folded[CASE_FOLDED_BUFSIZE])
+{
+  int i;
+  int n = 0;
+  wint_t uc = towupper (c);
+  wint_t lc = towlower (uc);
+  if (uc != c)
+    folded[n++] = uc;
+  if (lc != uc && lc != c && towupper (lc) == uc)
+    folded[n++] = lc;
+  for (i = 0; i < sizeof lonesome_lower / sizeof *lonesome_lower; i++)
+    {
+      wint_t li = lonesome_lower[i];
+      if (li != lc && li != uc && li != c && towupper (li) == uc)
+        folded[n++] = li;
+    }
+  return n;
+}
+
 typedef int predicate (int);
 
 /* The following list maps the names of the Posix named character classes
@@ -886,7 +945,7 @@ static const struct dfa_ctype prednames[] = {
   {"upper", isupper, false},
   {"lower", islower, false},
   {"digit", isdigit, true},
-  {"xdigit", isxdigit, true},
+  {"xdigit", isxdigit, false},
   {"space", isspace, false},
   {"punct", ispunct, false},
   {"alnum", isalnum, false},
@@ -913,10 +972,14 @@ find_pred (const char *str)
 static token
 parse_bracket_exp (void)
 {
-  int invert;
+  bool invert;
   int c, c1, c2;
   charclass ccl;
 
+  /* This is a bracket expression that dfaexec is known to
+     process correctly.  */
+  bool known_bracket_exp = true;
+
   /* Used to warn about [:space:].
      Bit 0 = first character is a colon.
      Bit 1 = last character is a colon.
@@ -930,16 +993,14 @@ parse_bracket_exp (void)
 
   /* Work area to build a mb_char_classes.  */
   struct mb_char_classes *work_mbc;
-  size_t chars_al, range_sts_al, range_ends_al, ch_classes_al,
-    equivs_al, coll_elems_al;
+  size_t chars_al, ranges_al, ch_classes_al, equivs_al, coll_elems_al;
 
-  chars_al = 0;
-  range_sts_al = range_ends_al = 0;
-  ch_classes_al = equivs_al = coll_elems_al = 0;
-  if (MB_CUR_MAX > 1)
+  chars_al = ranges_al = ch_classes_al = equivs_al = coll_elems_al = 0;
+  if (dfa->multibyte)
     {
-      REALLOC_IF_NECESSARY (dfa->mbcsets, dfa->mbcsets_alloc,
-                            dfa->nmbcsets + 1);
+      dfa->mbcsets = maybe_realloc (dfa->mbcsets, dfa->nmbcsets,
+                                    &dfa->mbcsets_alloc,
+                                    sizeof *dfa->mbcsets);
 
       /* dfa->multibyte_prop[] hold the index of dfa->mbcsets.
          We will update dfa->multibyte_prop[] in addtok, because we can't
@@ -957,32 +1018,31 @@ parse_bracket_exp (void)
   if (c == '^')
     {
       FETCH_WC (c, wc, _("unbalanced ["));
-      invert = 1;
+      invert = true;
+      known_bracket_exp = using_simple_locale ();
     }
   else
-    invert = 0;
+    invert = false;
 
   colon_warning_state = (c == ':');
   do
     {
-      c1 = EOF;                 /* mark c1 is not initialized".  */
+      c1 = NOTCHAR;    /* Mark c1 as not initialized.  */
       colon_warning_state &= ~2;
 
       /* Note that if we're looking at some other [:...:] construct,
          we just treat it as a bunch of ordinary characters.  We can do
          this because we assume regex has checked for syntax errors before
          dfa is ever called.  */
-      if (c == '[' && (syntax_bits & RE_CHAR_CLASSES))
+      if (c == '[')
         {
-#define MAX_BRACKET_STRING_LEN 32
-          char str[MAX_BRACKET_STRING_LEN + 1];
           FETCH_WC (c1, wc1, _("unbalanced ["));
 
-          /* If pattern contains '[[:', '[[.', or '[[='.  */
-          if (c1 == ':'
-              /* TODO: handle '[[.' and '[[=' also for MB_CUR_MAX == 1.  */
-              || (MB_CUR_MAX > 1 && (c1 == '.' || c1 == '=')))
+          if ((c1 == ':' && (syntax_bits & RE_CHAR_CLASSES))
+              || c1 == '.' || c1 == '=')
             {
+              enum { MAX_BRACKET_STRING_LEN = 32 };
+              char str[MAX_BRACKET_STRING_LEN + 1];
               size_t len = 0;
               for (;;)
                 {
@@ -1000,7 +1060,10 @@ parse_bracket_exp (void)
               /* Fetch bracket.  */
               FETCH_WC (c, wc, _("unbalanced ["));
               if (c1 == ':')
-                /* build character class.  */
+                /* Build character class.  POSIX allows character
+                   classes to match multicharacter collating elements,
+                   but the regex code does not support that, so do not
+                   worry about that possibility.  */
                 {
                   char const *class
                     = (case_fold && (STREQ (str, "upper")
@@ -1009,43 +1072,25 @@ parse_bracket_exp (void)
                   if (!pred)
                     dfaerror (_("invalid character class"));
 
-                  if (MB_CUR_MAX > 1 && !pred->single_byte_only)
+                  if (dfa->multibyte && !pred->single_byte_only)
                     {
                       /* Store the character class as wctype_t.  */
                       wctype_t wt = wctype (class);
 
-                      REALLOC_IF_NECESSARY (work_mbc->ch_classes,
-                                            ch_classes_al,
-                                            work_mbc->nch_classes + 1);
+                      work_mbc->ch_classes
+                        = maybe_realloc (work_mbc->ch_classes,
+                                         work_mbc->nch_classes, &ch_classes_al,
+                                         sizeof *work_mbc->ch_classes);
                       work_mbc->ch_classes[work_mbc->nch_classes++] = wt;
                     }
 
                   for (c2 = 0; c2 < NOTCHAR; ++c2)
                     if (pred->func (c2))
-                      setbit_case_fold_c (c2, ccl);
+                      setbit (c2, ccl);
                 }
+              else
+                known_bracket_exp = false;
 
-              else if (MBS_SUPPORT && (c1 == '=' || c1 == '.'))
-                {
-                  char *elem = xmemdup (str, len + 1);
-
-                  if (c1 == '=')
-                    /* build equivalence class.  */
-                    {
-                      REALLOC_IF_NECESSARY (work_mbc->equivs,
-                                            equivs_al, work_mbc->nequivs + 1);
-                      work_mbc->equivs[work_mbc->nequivs++] = elem;
-                    }
-
-                  if (c1 == '.')
-                    /* build collating element.  */
-                    {
-                      REALLOC_IF_NECESSARY (work_mbc->coll_elems,
-                                            coll_elems_al,
-                                            work_mbc->ncoll_elems + 1);
-                      work_mbc->coll_elems[work_mbc->ncoll_elems++] = elem;
-                    }
-                }
               colon_warning_state |= 8;
 
               /* Fetch new lookahead character.  */
@@ -1060,113 +1105,110 @@ parse_bracket_exp (void)
       if (c == '\\' && (syntax_bits & RE_BACKSLASH_ESCAPE_IN_LISTS))
         FETCH_WC (c, wc, _("unbalanced ["));
 
-      if (c1 == EOF)
+      if (c1 == NOTCHAR)
         FETCH_WC (c1, wc1, _("unbalanced ["));
 
       if (c1 == '-')
         /* build range characters.  */
         {
           FETCH_WC (c2, wc2, _("unbalanced ["));
-          if (c2 == ']')
+
+          /* A bracket expression like [a-[.aa.]] matches an unknown set.
+             Treat it like [-a[.aa.]] while parsing it, and
+             remember that the set is unknown.  */
+          if (c2 == '[' && *lexptr == '.')
             {
-              /* In the case [x-], the - is an ordinary hyphen,
-                 which is left in c1, the lookahead character.  */
-              lexptr -= cur_mb_len;
-              lexleft += cur_mb_len;
+              known_bracket_exp = false;
+              c2 = ']';
             }
-        }
 
-      if (c1 == '-' && c2 != ']')
-        {
-          if (c2 == '\\' && (syntax_bits & RE_BACKSLASH_ESCAPE_IN_LISTS))
-            FETCH_WC (c2, wc2, _("unbalanced ["));
-
-          if (MB_CUR_MAX > 1)
+          if (c2 != ']')
             {
-              /* When case folding map a range, say [m-z] (or even [M-z])
-                 to the pair of ranges, [m-z] [M-Z].  */
-              REALLOC_IF_NECESSARY (work_mbc->range_sts,
-                                    range_sts_al, work_mbc->nranges + 1);
-              REALLOC_IF_NECESSARY (work_mbc->range_ends,
-                                    range_ends_al, work_mbc->nranges + 1);
-              work_mbc->range_sts[work_mbc->nranges] =
-                case_fold ? towlower (wc) : (wchar_t) wc;
-              work_mbc->range_ends[work_mbc->nranges++] =
-                case_fold ? towlower (wc2) : (wchar_t) wc2;
-
-#ifndef GREP
-              if (case_fold && (iswalpha (wc) || iswalpha (wc2)))
+              if (c2 == '\\' && (syntax_bits & RE_BACKSLASH_ESCAPE_IN_LISTS))
+                FETCH_WC (c2, wc2, _("unbalanced ["));
+
+              if (dfa->multibyte)
                 {
-                  REALLOC_IF_NECESSARY (work_mbc->range_sts,
-                                        range_sts_al, work_mbc->nranges + 1);
-                  work_mbc->range_sts[work_mbc->nranges] = towupper (wc);
-                  REALLOC_IF_NECESSARY (work_mbc->range_ends,
-                                        range_ends_al, work_mbc->nranges + 1);
-                  work_mbc->range_ends[work_mbc->nranges++] = towupper (wc2);
+                  /* When case folding map a range, say [m-z] (or even [M-z])
+                     to the pair of ranges, [m-z] [M-Z].  Although this code
+                     is wrong in multiple ways, it's never used in practice.
+                     FIXME: Remove this (and related) unused code.  */
+                  if (wc != WEOF && wc2 != WEOF)
+                    {
+                      work_mbc->ranges
+                        = maybe_realloc (work_mbc->ranges, work_mbc->nranges + 2,
+                                         &ranges_al, sizeof *work_mbc->ranges);
+                      work_mbc->ranges[work_mbc->nranges].beg
+                        = case_fold ? towlower (wc) : wc;
+                      work_mbc->ranges[work_mbc->nranges++].end
+                        = case_fold ? towlower (wc2) : wc2;
+
+                      if (case_fold && (iswalpha (wc) || iswalpha (wc2)))
+                        {
+                          work_mbc->ranges[work_mbc->nranges].beg = towupper (wc);
+                          work_mbc->ranges[work_mbc->nranges++].end
+                            = towupper (wc2);
+                        }
+                    }
                 }
-#endif
-            }
-          else
-            {
-              /* Defer to the system regex library about the meaning
-                 of range expressions.  */
-              regex_t re;
-              char pattern[6] = { '[', 0, '-', 0, ']', 0 };
-              char subject[2] = { 0, 0 };
-              c1 = c;
-              if (case_fold)
+              else if (using_simple_locale ())
                 {
-                  c1 = tolower (c1);
-                  c2 = tolower (c2);
+                  for (c1 = c; c1 <= c2; c1++)
+                    setbit (c1, ccl);
+                  if (case_fold)
+                    {
+                      int uc = toupper (c);
+                      int uc2 = toupper (c2);
+                      for (c1 = 0; c1 < NOTCHAR; c1++)
+                        {
+                          int uc1 = toupper (c1);
+                          if (uc <= uc1 && uc1 <= uc2)
+                            setbit (c1, ccl);
+                        }
+                    }
                 }
+              else
+                known_bracket_exp = false;
 
-              pattern[1] = c1;
-              pattern[3] = c2;
-              regcomp (&re, pattern, REG_NOSUB);
-              for (c = 0; c < NOTCHAR; ++c)
-                {
-                  if ((case_fold && isupper (c)))
-                    continue;
-                  subject[0] = c;
-                  if (regexec (&re, subject, 0, NULL, 0) != REG_NOMATCH)
-                    setbit_case_fold_c (c, ccl);
-                }
-              regfree (&re);
+              colon_warning_state |= 8;
+              FETCH_WC (c1, wc1, _("unbalanced ["));
+              continue;
             }
 
-          colon_warning_state |= 8;
-          FETCH_WC (c1, wc1, _("unbalanced ["));
-          continue;
+          /* In the case [x-], the - is an ordinary hyphen,
+             which is left in c1, the lookahead character.  */
+          lexptr -= cur_mb_len;
+          lexleft += cur_mb_len;
         }
 
       colon_warning_state |= (c == ':') ? 2 : 4;
 
-      if (MB_CUR_MAX == 1)
+      if (!dfa->multibyte)
         {
-          setbit_case_fold_c (c, ccl);
+          if (case_fold)
+            setbit_case_fold_c (c, ccl);
+          else
+            setbit (c, ccl);
           continue;
         }
 
-      if (case_fold && iswalpha (wc))
-        {
-          wc = towlower (wc);
-          if (!setbit_wc (wc, ccl))
-            {
-              REALLOC_IF_NECESSARY (work_mbc->chars, chars_al,
-                                    work_mbc->nchars + 1);
-              work_mbc->chars[work_mbc->nchars++] = wc;
-            }
-#ifdef GREP
-          continue;
-#else
-          wc = towupper (wc);
-#endif
-        }
-      if (!setbit_wc (wc, ccl))
+      if (wc == WEOF)
+        known_bracket_exp = false;
+      else
         {
-          REALLOC_IF_NECESSARY (work_mbc->chars, chars_al,
-                                work_mbc->nchars + 1);
-          work_mbc->chars[work_mbc->nchars++] = wc;
+          wchar_t folded[CASE_FOLDED_BUFSIZE + 1];
+          int i;
+          int n = (case_fold ? case_folded_counterparts (wc, folded + 1) + 1
+                   : 1);
+          folded[0] = wc;
+          for (i = 0; i < n; i++)
+            if (!setbit_wc (folded[i], ccl))
+              {
+                work_mbc->chars
+                  = maybe_realloc (work_mbc->chars, work_mbc->nchars,
+                                   &chars_al, sizeof *work_mbc->chars);
+                work_mbc->chars[work_mbc->nchars++] = folded[i];
+              }
         }
     }
   while ((wc = wc1, (c = c1) != ']'));
@@ -1174,7 +1216,10 @@ parse_bracket_exp (void)
   if (colon_warning_state == 7)
     dfawarn (_("character class syntax is [[:space:]], not [:space:]"));
 
-  if (MB_CUR_MAX > 1)
+  if (! known_bracket_exp)
+    return BACKREF;
+
+  if (dfa->multibyte)
     {
       static charclass zeroclass;
       work_mbc->invert = invert;
@@ -1184,7 +1229,7 @@ parse_bracket_exp (void)
 
   if (invert)
     {
-      assert (MB_CUR_MAX == 1);
+      assert (!dfa->multibyte);
       notset (ccl);
       if (syntax_bits & RE_HAT_LISTS_NOT_NEWLINE)
         clrbit (eolbyte, ccl);
@@ -1196,8 +1241,8 @@ parse_bracket_exp (void)
 static token
 lex (void)
 {
-  unsigned int c, c2;
-  int backslash = 0;
+  int c, c2;
+  bool backslash = false;
   charclass ccl;
   int i;
 
@@ -1209,14 +1254,7 @@ lex (void)
      "if (backslash) ...".  */
   for (i = 0; i < 2; ++i)
     {
-      if (MB_CUR_MAX > 1)
-        {
-          FETCH_WC (c, wctok, NULL);
-          if ((int) c == EOF)
-            goto normal_char;
-        }
-      else
-        FETCH (c, NULL);
+      FETCH_WC (c, wctok, NULL);
 
       switch (c)
         {
@@ -1225,7 +1263,7 @@ lex (void)
             goto normal_char;
           if (lexleft == 0)
             dfaerror (_("unfinished \\ escape"));
-          backslash = 1;
+          backslash = true;
           break;
 
         case '^':
@@ -1263,7 +1301,7 @@ lex (void)
         case '9':
           if (backslash && !(syntax_bits & RE_NO_BK_REFS))
             {
-              laststart = 0;
+              laststart = false;
               return lasttok = BACKREF;
             }
           goto normal_char;
@@ -1378,7 +1416,7 @@ lex (void)
             lexptr = p;
             lexleft = lim - p;
           }
-          laststart = 0;
+          laststart = false;
           return lasttok = REPMN;
 
         case '|':
@@ -1386,21 +1424,21 @@ lex (void)
             goto normal_char;
           if (backslash != ((syntax_bits & RE_NO_BK_VBAR) == 0))
             goto normal_char;
-          laststart = 1;
+          laststart = true;
           return lasttok = OR;
 
         case '\n':
           if (syntax_bits & RE_LIMITED_OPS
               || backslash || !(syntax_bits & RE_NEWLINE_ALT))
             goto normal_char;
-          laststart = 1;
+          laststart = true;
           return lasttok = OR;
 
         case '(':
           if (backslash != ((syntax_bits & RE_NO_BK_PARENS) == 0))
             goto normal_char;
           ++parens;
-          laststart = 1;
+          laststart = true;
           return lasttok = LPAREN;
 
         case ')':
@@ -1409,17 +1447,17 @@ lex (void)
           if (parens == 0 && syntax_bits & RE_UNMATCHED_RIGHT_PAREN_ORD)
             goto normal_char;
           --parens;
-          laststart = 0;
+          laststart = false;
           return lasttok = RPAREN;
 
         case '.':
           if (backslash)
             goto normal_char;
-          if (MB_CUR_MAX > 1)
+          if (dfa->multibyte)
             {
               /* In multibyte environment period must match with a single
                  character not a byte.  So we use ANYCHAR.  */
-              laststart = 0;
+              laststart = false;
               return lasttok = ANYCHAR;
             }
           zeroset (ccl);
@@ -1428,14 +1466,14 @@ lex (void)
             clrbit (eolbyte, ccl);
           if (syntax_bits & RE_DOT_NOT_NULL)
             clrbit ('\0', ccl);
-          laststart = 0;
+          laststart = false;
           return lasttok = CSET + charclass_index (ccl);
 
         case 's':
         case 'S':
           if (!backslash || (syntax_bits & RE_NO_GNU_OPS))
             goto normal_char;
-          if (MB_CUR_MAX == 1)
+          if (!dfa->multibyte)
             {
               zeroset (ccl);
               for (c2 = 0; c2 < NOTCHAR; ++c2)
@@ -1443,7 +1481,7 @@ lex (void)
                   setbit (c2, ccl);
               if (c == 'S')
                 notset (ccl);
-              laststart = 0;
+              laststart = false;
               return lasttok = CSET + charclass_index (ccl);
             }
 
@@ -1473,7 +1511,7 @@ lex (void)
 
           POP_LEX_STATE ();
 
-          laststart = 0;
+          laststart = false;
           return lasttok;
 
         case 'w':
@@ -1486,21 +1524,21 @@ lex (void)
               setbit (c2, ccl);
           if (c == 'W')
             notset (ccl);
-          laststart = 0;
+          laststart = false;
           return lasttok = CSET + charclass_index (ccl);
 
         case '[':
           if (backslash)
             goto normal_char;
-          laststart = 0;
+          laststart = false;
           return lasttok = parse_bracket_exp ();
 
         default:
         normal_char:
-          laststart = 0;
+          laststart = false;
           /* For multibyte character sets, folding is done in atom.  Always
              return WCHAR.  */
-          if (MB_CUR_MAX > 1)
+          if (dfa->multibyte)
             return lasttok = WCHAR;
 
           if (case_fold && isalpha (c))
@@ -1532,14 +1570,16 @@ static size_t depth;            /* Current depth of a hypothetical stack
 static void
 addtok_mb (token t, int mbprop)
 {
-  if (MB_CUR_MAX > 1)
+  if (dfa->talloc == dfa->tindex)
     {
-      REALLOC_IF_NECESSARY (dfa->multibyte_prop, dfa->nmultibyte_prop,
-                            dfa->tindex + 1);
-      dfa->multibyte_prop[dfa->tindex] = mbprop;
+      dfa->tokens = x2nrealloc (dfa->tokens, &dfa->talloc,
+                                sizeof *dfa->tokens);
+      if (dfa->multibyte)
+        dfa->multibyte_prop = xnrealloc (dfa->multibyte_prop, dfa->talloc,
+                                         sizeof *dfa->multibyte_prop);
     }
-
-  REALLOC_IF_NECESSARY (dfa->tokens, dfa->talloc, dfa->tindex + 1);
+  if (dfa->multibyte)
+    dfa->multibyte_prop[dfa->tindex] = mbprop;
   dfa->tokens[dfa->tindex++] = t;
 
   switch (t)
@@ -1554,8 +1594,12 @@ addtok_mb (token t, int mbprop)
       --depth;
       break;
 
+    case BACKREF:
+      dfa->fast = false;
+      /* fallthrough */
     default:
       ++dfa->nleaves;
+      /* fallthrough */
     case EMPTY:
       ++depth;
       break;
@@ -1571,7 +1615,7 @@ static void addtok_wc (wint_t wc);
 static void
 addtok (token t)
 {
-  if (MB_CUR_MAX > 1 && t == MBCSET)
+  if (dfa->multibyte && t == MBCSET)
     {
       bool need_or = false;
       struct mb_char_classes *work_mbc = &dfa->mbcsets[dfa->nmbcsets - 1];
@@ -1591,10 +1635,11 @@ addtok (token t)
           work_mbc->nchars = 0;
         }
 
-      /* UTF-8 allows treating a simple, non-inverted MBCSET like a CSET.  */
+      /* If the MBCSET is non-inverted and doesn't include neither
+         character classes including multibyte characters, range
+         expressions, equivalence classes nor collating elements,
+         it can be replaced to a simple CSET. */
       if (work_mbc->invert
-          || (!using_utf8 () && work_mbc->cset != -1)
-          || work_mbc->nchars != 0
           || work_mbc->nch_classes != 0
           || work_mbc->nranges != 0
           || work_mbc->nequivs != 0 || work_mbc->ncoll_elems != 0)
@@ -1609,7 +1654,6 @@ addtok (token t)
              that the mbcset is empty now.  Do nothing in that case.  */
           if (work_mbc->cset != -1)
             {
-              assert (using_utf8 ());
               addtok (CSET + work_mbc->cset);
               if (need_or)
                 addtok (OR);
@@ -1622,7 +1666,6 @@ addtok (token t)
     }
 }
 
-#if MBS_SUPPORT
 /* We treat a multibyte character as a single atom, so that DFA
    can treat a multibyte character as a single expression.
 
@@ -1633,16 +1676,19 @@ static void
 addtok_wc (wint_t wc)
 {
   unsigned char buf[MB_LEN_MAX];
-  mbstate_t s;
+  mbstate_t s = { 0 };
   int i;
-  memset (&s, 0, sizeof s);
-  cur_mb_len = wcrtomb ((char *) buf, wc, &s);
+  size_t stored_bytes = wcrtomb ((char *) buf, wc, &s);
 
-  /* This is merely stop-gap.  When cur_mb_len is 0 or negative,
-     buf[0] is undefined, yet skipping the addtok_mb call altogether
-     can result in heap corruption.  */
-  if (cur_mb_len <= 0)
-    buf[0] = 0;
+  if (stored_bytes != (size_t) -1)
+    cur_mb_len = stored_bytes;
+  else
+    {
+      /* This is merely stop-gap.  buf[0] is undefined, yet skipping
+         the addtok_mb call altogether can corrupt the heap.  */
+      cur_mb_len = 1;
+      buf[0] = 0;
+    }
 
   addtok_mb (buf[0], cur_mb_len == 1 ? 3 : 1);
   for (i = 1; i < cur_mb_len; i++)
@@ -1651,23 +1697,26 @@ addtok_wc (wint_t wc)
       addtok (CAT);
     }
 }
-#else
-static void
-addtok_wc (wint_t wc)
-{
-}
-#endif
 
 static void
 add_utf8_anychar (void)
 {
-#if MBS_SUPPORT
   static const charclass utf8_classes[5] = {
-    {0, 0, 0, 0, ~0, ~0, 0, 0},                /* 80-bf: non-leading bytes */
-    {~0, ~0, ~0, ~0, 0, 0, 0, 0},       /* 00-7f: 1-byte sequence */
-    {0, 0, 0, 0, 0, 0, ~3, 0},          /* c2-df: 2-byte sequence */
-    {0, 0, 0, 0, 0, 0, 0, 0xffff},      /* e0-ef: 3-byte sequence */
-    {0, 0, 0, 0, 0, 0, 0, 0xff0000}     /* f0-f7: 4-byte sequence */
+    /* 80-bf: non-leading bytes.  */
+    {0, 0, 0, 0, CHARCLASS_WORD_MASK, CHARCLASS_WORD_MASK, 0, 0},
+
+    /* 00-7f: 1-byte sequence.  */
+    {CHARCLASS_WORD_MASK, CHARCLASS_WORD_MASK, CHARCLASS_WORD_MASK,
+     CHARCLASS_WORD_MASK, 0, 0, 0, 0},
+
+    /* c2-df: 2-byte sequence.  */
+    {0, 0, 0, 0, 0, 0, ~3 & CHARCLASS_WORD_MASK, 0},
+
+    /* e0-ef: 3-byte sequence.  */
+    {0, 0, 0, 0, 0, 0, 0, 0xffff},
+
+    /* f0-f7: 4-byte sequence.  */
+    {0, 0, 0, 0, 0, 0, 0, 0xff0000}
   };
   const unsigned int n = sizeof (utf8_classes) / sizeof (utf8_classes[0]);
   unsigned int i;
@@ -1706,7 +1755,6 @@ add_utf8_anychar (void)
       addtok (CAT);
       addtok (OR);
     }
-#endif
 }
 
 /* The grammar understood by the parser is as follows.
@@ -1747,24 +1795,29 @@ add_utf8_anychar (void)
 static void
 atom (void)
 {
-  if (0)
+  if (tok == WCHAR)
     {
-      /* empty */
-    }
-  else if (MBS_SUPPORT && tok == WCHAR)
-    {
-      addtok_wc (case_fold ? towlower (wctok) : wctok);
-#ifndef GREP
-      if (case_fold && iswalpha (wctok))
+      if (wctok == WEOF)
+        addtok (BACKREF);
+      else
         {
-          addtok_wc (towupper (wctok));
-          addtok (OR);
+          addtok_wc (wctok);
+
+          if (case_fold)
+            {
+              wchar_t folded[CASE_FOLDED_BUFSIZE];
+              int i, n = case_folded_counterparts (wctok, folded);
+              for (i = 0; i < n; i++)
+                {
+                  addtok_wc (folded[i]);
+                  addtok (OR);
+                }
+            }
         }
-#endif
 
       tok = lex ();
     }
-  else if (MBS_SUPPORT && tok == ANYCHAR && using_utf8 ())
+  else if (tok == ANYCHAR && using_utf8 ())
     {
       /* For UTF-8 expand the period to a series of CSETs that define a valid
          UTF-8 character.  This avoids using the slow multibyte path.  I'm
@@ -1778,9 +1831,7 @@ atom (void)
     }
   else if ((tok >= 0 && tok < NOTCHAR) || tok >= CSET || tok == BACKREF
            || tok == BEGLINE || tok == ENDLINE || tok == BEGWORD
-#if MBS_SUPPORT
            || tok == ANYCHAR || tok == MBCSET
-#endif /* MBS_SUPPORT */
            || tok == ENDWORD || tok == LIMWORD || tok == NOTLIMWORD)
     {
       addtok (tok);
@@ -1825,7 +1876,7 @@ copytoks (size_t tindex, size_t ntokens)
 {
   size_t i;
 
-  if (MB_CUR_MAX > 1)
+  if (dfa->multibyte)
     for (i = 0; i < ntokens; ++i)
       addtok_mb (dfa->tokens[tindex + i], dfa->multibyte_prop[tindex + i]);
   else
@@ -1908,12 +1959,12 @@ dfaparse (char const *s, size_t len, struct dfa *d)
   lexptr = s;
   lexleft = len;
   lasttok = END;
-  laststart = 1;
+  laststart = true;
   parens = 0;
-  if (MB_CUR_MAX > 1)
+  if (dfa->multibyte)
     {
       cur_mb_len = 0;
-      memset (&mbs, 0, sizeof mbs);
+      memset (&d->mbs, 0, sizeof d->mbs);
     }
 
   if (!syntax_bits_set)
@@ -1938,19 +1989,24 @@ dfaparse (char const *s, size_t len, struct dfa *d)
 
 /* Some primitives for operating on sets of positions.  */
 
-/* Copy one set to another; the destination must be large enough.  */
+/* Copy one set to another.  */
 static void
 copy (position_set const *src, position_set * dst)
 {
-  REALLOC_IF_NECESSARY (dst->elems, dst->alloc, src->nelem);
-  memcpy (dst->elems, src->elems, sizeof (dst->elems[0]) * src->nelem);
+  if (dst->alloc < src->nelem)
+    {
+      free (dst->elems);
+      dst->alloc = src->nelem;
+      dst->elems = x2nrealloc (NULL, &dst->alloc, sizeof *dst->elems);
+    }
+  memcpy (dst->elems, src->elems, src->nelem * sizeof *dst->elems);
   dst->nelem = src->nelem;
 }
 
 static void
 alloc_position_set (position_set * s, size_t size)
 {
-  MALLOC (s->elems, size);
+  s->elems = xnmalloc (size, sizeof *s->elems);
   s->alloc = size;
   s->nelem = 0;
 }
@@ -1980,7 +2036,7 @@ insert (position p, position_set * s)
       return;
     }
 
-  REALLOC_IF_NECESSARY (s->elems, s->alloc, count + 1);
+  s->elems = maybe_realloc (s->elems, count, &s->alloc, sizeof *s->elems);
   for (i = count; i > lo; i--)
     s->elems[i] = s->elems[i - 1];
   s->elems[lo] = p;
@@ -1994,7 +2050,12 @@ merge (position_set const *s1, position_set const *s2, position_set * m)
 {
   size_t i = 0, j = 0;
 
-  REALLOC_IF_NECESSARY (m->elems, m->alloc, s1->nelem + s2->nelem);
+  if (m->alloc < s1->nelem + s2->nelem)
+    {
+      free (m->elems);
+      m->elems = maybe_realloc (NULL, s1->nelem + s2->nelem, &m->alloc,
+                                sizeof *m->elems);
+    }
   m->nelem = 0;
   while (i < s1->nelem && j < s2->nelem)
     if (s1->elems[i].index > s2->elems[j].index)
@@ -2055,19 +2116,19 @@ state_index (struct dfa *d, position_set const *s, int context)
     }
 
   /* We'll have to create a new state.  */
-  REALLOC_IF_NECESSARY (d->states, d->salloc, d->sindex + 1);
+  d->states = maybe_realloc (d->states, d->sindex, &d->salloc,
+                             sizeof *d->states);
   d->states[i].hash = hash;
   alloc_position_set (&d->states[i].elems, s->nelem);
   copy (s, &d->states[i].elems);
   d->states[i].context = context;
-  d->states[i].backref = 0;
+  d->states[i].has_backref = false;
+  d->states[i].has_mbcset = false;
   d->states[i].constraint = 0;
   d->states[i].first_end = 0;
-  if (MBS_SUPPORT)
-    {
-      d->states[i].mbps.nelem = 0;
-      d->states[i].mbps.elems = NULL;
-    }
+  d->states[i].mbps.nelem = 0;
+  d->states[i].mbps.elems = NULL;
+
   for (j = 0; j < s->nelem; ++j)
     if (d->tokens[s->elems[j].index] < 0)
       {
@@ -2080,7 +2141,7 @@ state_index (struct dfa *d, position_set const *s, int context)
     else if (d->tokens[s->elems[j].index] == BACKREF)
       {
         d->states[i].constraint = NO_CONSTRAINT;
-        d->states[i].backref = 1;
+        d->states[i].has_backref = true;
       }
 
   ++d->sindex;
@@ -2094,23 +2155,24 @@ state_index (struct dfa *d, position_set const *s, int context)
    constraint.  Repeat exhaustively until no funny positions are left.
    S->elems must be large enough to hold the result.  */
 static void
-epsclosure (position_set * s, struct dfa const *d)
+epsclosure (position_set *s, struct dfa const *d, char *visited)
 {
   size_t i, j;
-  char *visited;  /* Array of booleans, enough to use char, not int.  */
   position p, old;
-
-  CALLOC (visited, d->tindex);
+  bool initialized = false;
 
   for (i = 0; i < s->nelem; ++i)
     if (d->tokens[s->elems[i].index] >= NOTCHAR
         && d->tokens[s->elems[i].index] != BACKREF
-#if MBS_SUPPORT
         && d->tokens[s->elems[i].index] != ANYCHAR
         && d->tokens[s->elems[i].index] != MBCSET
-#endif
         && d->tokens[s->elems[i].index] < CSET)
       {
+        if (!initialized)
+          {
+            memset (visited, 0, d->tindex * sizeof (*visited));
+            initialized = true;
+          }
         old = s->elems[i];
         p.constraint = old.constraint;
         delete (s->elems[i], s);
@@ -2151,8 +2213,6 @@ epsclosure (position_set * s, struct dfa const *d)
         /* Force rescan to start at the beginning.  */
         i = -1;
       }
-
-  free (visited);
 }
 
 /* Returns the set of contexts for which there is at least one
@@ -2167,7 +2227,7 @@ charclass_context (charclass c)
   if (tstbit (eolbyte, c))
     context |= CTX_NEWLINE;
 
-  for (j = 0; j < CHARCLASS_INTS; ++j)
+  for (j = 0; j < CHARCLASS_WORDS; ++j)
     {
       if (c[j] & letters[j])
         context |= CTX_LETTER;
@@ -2257,19 +2317,29 @@ state_separate_contexts (position_set const *s)
 void
 dfaanalyze (struct dfa *d, int searchflag)
 {
-  int *nullable;                /* Nullable stack.  */
-  size_t *nfirstpos;            /* Element count stack for firstpos sets.  */
-  position *firstpos;           /* Array where firstpos elements are stored.  */
-  size_t *nlastpos;             /* Element count stack for lastpos sets.  */
-  position *lastpos;            /* Array where lastpos elements are stored.  */
+  /* Array allocated to hold position sets.  */
+  position *posalloc = xnmalloc (d->nleaves, 2 * sizeof *posalloc);
+  /* Firstpos and lastpos elements.  */
+  position *firstpos = posalloc + d->nleaves;
+  position *lastpos = firstpos + d->nleaves;
+
+  /* Stack for element counts and nullable flags.  */
+  struct
+  {
+    /* Whether the entry is nullable.  */
+    bool nullable;
+
+    /* Counts of firstpos and lastpos sets.  */
+    size_t nfirstpos;
+    size_t nlastpos;
+  } *stkalloc = xnmalloc (d->depth, sizeof *stkalloc), *stk = stkalloc;
+
   position_set tmp;             /* Temporary set for merging sets.  */
   position_set merged;          /* Result of merging sets.  */
   int separate_contexts;        /* Context wanted by some position.  */
-  int *o_nullable;
-  size_t *o_nfirst, *o_nlast;
-  position *o_firstpos, *o_lastpos;
   size_t i, j;
   position *pos;
+  char *visited = xnmalloc (d->tindex, sizeof *visited);
 
 #ifdef DEBUG
   fprintf (stderr, "dfaanalyze:\n");
@@ -2281,21 +2351,9 @@ dfaanalyze (struct dfa *d, int searchflag)
   putc ('\n', stderr);
 #endif
 
-  d->searchflag = searchflag;
-
-  MALLOC (nullable, d->depth);
-  o_nullable = nullable;
-  MALLOC (nfirstpos, d->depth);
-  o_nfirst = nfirstpos;
-  MALLOC (firstpos, d->nleaves);
-  o_firstpos = firstpos, firstpos += d->nleaves;
-  MALLOC (nlastpos, d->depth);
-  o_nlast = nlastpos;
-  MALLOC (lastpos, d->nleaves);
-  o_lastpos = lastpos, lastpos += d->nleaves;
+  d->searchflag = searchflag != 0;
   alloc_position_set (&merged, d->nleaves);
-
-  CALLOC (d->follows, d->tindex);
+  d->follows = xcalloc (d->tindex, sizeof *d->follows);
 
   for (i = 0; i < d->tindex; ++i)
     {
@@ -2303,38 +2361,40 @@ dfaanalyze (struct dfa *d, int searchflag)
         {
         case EMPTY:
           /* The empty set is nullable.  */
-          *nullable++ = 1;
+          stk->nullable = true;
 
           /* The firstpos and lastpos of the empty leaf are both empty.  */
-          *nfirstpos++ = *nlastpos++ = 0;
+          stk->nfirstpos = stk->nlastpos = 0;
+          stk++;
           break;
 
         case STAR:
         case PLUS:
           /* Every element in the firstpos of the argument is in the follow
              of every element in the lastpos.  */
-          tmp.nelem = nfirstpos[-1];
+          tmp.nelem = stk[-1].nfirstpos;
           tmp.elems = firstpos;
           pos = lastpos;
-          for (j = 0; j < nlastpos[-1]; ++j)
+          for (j = 0; j < stk[-1].nlastpos; ++j)
             {
               merge (&tmp, &d->follows[pos[j].index], &merged);
               copy (&merged, &d->follows[pos[j].index]);
             }
+          /* fallthrough */
 
         case QMARK:
           /* A QMARK or STAR node is automatically nullable.  */
           if (d->tokens[i] != PLUS)
-            nullable[-1] = 1;
+            stk[-1].nullable = true;
           break;
 
         case CAT:
           /* Every element in the firstpos of the second argument is in the
              follow of every element in the lastpos of the first argument.  */
-          tmp.nelem = nfirstpos[-1];
+          tmp.nelem = stk[-1].nfirstpos;
           tmp.elems = firstpos;
-          pos = lastpos + nlastpos[-1];
-          for (j = 0; j < nlastpos[-2]; ++j)
+          pos = lastpos + stk[-1].nlastpos;
+          for (j = 0; j < stk[-2].nlastpos; ++j)
             {
               merge (&tmp, &d->follows[pos[j].index], &merged);
               copy (&merged, &d->follows[pos[j].index]);
@@ -2342,43 +2402,39 @@ dfaanalyze (struct dfa *d, int searchflag)
 
           /* The firstpos of a CAT node is the firstpos of the first argument,
              union that of the second argument if the first is nullable.  */
-          if (nullable[-2])
-            nfirstpos[-2] += nfirstpos[-1];
+          if (stk[-2].nullable)
+            stk[-2].nfirstpos += stk[-1].nfirstpos;
           else
-            firstpos += nfirstpos[-1];
-          --nfirstpos;
+            firstpos += stk[-1].nfirstpos;
 
           /* The lastpos of a CAT node is the lastpos of the second argument,
              union that of the first argument if the second is nullable.  */
-          if (nullable[-1])
-            nlastpos[-2] += nlastpos[-1];
+          if (stk[-1].nullable)
+            stk[-2].nlastpos += stk[-1].nlastpos;
           else
             {
-              pos = lastpos + nlastpos[-2];
-              for (j = nlastpos[-1]; j-- > 0;)
+              pos = lastpos + stk[-2].nlastpos;
+              for (j = stk[-1].nlastpos; j-- > 0;)
                 pos[j] = lastpos[j];
-              lastpos += nlastpos[-2];
-              nlastpos[-2] = nlastpos[-1];
+              lastpos += stk[-2].nlastpos;
+              stk[-2].nlastpos = stk[-1].nlastpos;
             }
-          --nlastpos;
 
           /* A CAT node is nullable if both arguments are nullable.  */
-          nullable[-2] = nullable[-1] && nullable[-2];
-          --nullable;
+          stk[-2].nullable &= stk[-1].nullable;
+          stk--;
           break;
 
         case OR:
           /* The firstpos is the union of the firstpos of each argument.  */
-          nfirstpos[-2] += nfirstpos[-1];
-          --nfirstpos;
+          stk[-2].nfirstpos += stk[-1].nfirstpos;
 
           /* The lastpos is the union of the lastpos of each argument.  */
-          nlastpos[-2] += nlastpos[-1];
-          --nlastpos;
+          stk[-2].nlastpos += stk[-1].nlastpos;
 
           /* An OR node is nullable if either argument is nullable.  */
-          nullable[-2] = nullable[-1] || nullable[-2];
-          --nullable;
+          stk[-2].nullable |= stk[-1].nullable;
+          stk--;
           break;
 
         default:
@@ -2387,10 +2443,12 @@ dfaanalyze (struct dfa *d, int searchflag)
              an "epsilon closure" effectively makes them nullable later.
              Backreferences have to get a real position so we can detect
              transitions on them later.  But they are nullable.  */
-          *nullable++ = d->tokens[i] == BACKREF;
+          stk->nullable = d->tokens[i] == BACKREF;
 
           /* This position is in its own firstpos and lastpos.  */
-          *nfirstpos++ = *nlastpos++ = 1;
+          stk->nfirstpos = stk->nlastpos = 1;
+          stk++;
+
           --firstpos, --lastpos;
           firstpos->index = lastpos->index = i;
           firstpos->constraint = lastpos->constraint = NO_CONSTRAINT;
@@ -2404,15 +2462,16 @@ dfaanalyze (struct dfa *d, int searchflag)
       fprintf (stderr, "node %zd:", i);
       prtok (d->tokens[i]);
       putc ('\n', stderr);
-      fprintf (stderr, nullable[-1] ? " nullable: yes\n" : " nullable: no\n");
+      fprintf (stderr,
+               stk[-1].nullable ? " nullable: yes\n" : " nullable: no\n");
       fprintf (stderr, " firstpos:");
-      for (j = nfirstpos[-1]; j-- > 0;)
+      for (j = stk[-1].nfirstpos; j-- > 0;)
         {
           fprintf (stderr, " %zd:", firstpos[j].index);
           prtok (d->tokens[firstpos[j].index]);
         }
       fprintf (stderr, "\n lastpos:");
-      for (j = nlastpos[-1]; j-- > 0;)
+      for (j = stk[-1].nlastpos; j-- > 0;)
         {
           fprintf (stderr, " %zd:", lastpos[j].index);
           prtok (d->tokens[lastpos[j].index]);
@@ -2425,9 +2484,7 @@ dfaanalyze (struct dfa *d, int searchflag)
      it with its epsilon closure.  */
   for (i = 0; i < d->tindex; ++i)
     if (d->tokens[i] < NOTCHAR || d->tokens[i] == BACKREF
-#if MBS_SUPPORT
         || d->tokens[i] == ANYCHAR || d->tokens[i] == MBCSET
-#endif
         || d->tokens[i] >= CSET)
       {
 #ifdef DEBUG
@@ -2442,33 +2499,27 @@ dfaanalyze (struct dfa *d, int searchflag)
         putc ('\n', stderr);
 #endif
         copy (&d->follows[i], &merged);
-        epsclosure (&merged, d);
+        epsclosure (&merged, d, visited);
         copy (&merged, &d->follows[i]);
       }
 
   /* Get the epsilon closure of the firstpos of the regexp.  The result will
      be the set of positions of state 0.  */
   merged.nelem = 0;
-  for (i = 0; i < nfirstpos[-1]; ++i)
+  for (i = 0; i < stk[-1].nfirstpos; ++i)
     insert (firstpos[i], &merged);
-  epsclosure (&merged, d);
+  epsclosure (&merged, d, visited);
 
   /* Build the initial state.  */
-  d->salloc = 1;
-  d->sindex = 0;
-  MALLOC (d->states, d->salloc);
-
   separate_contexts = state_separate_contexts (&merged);
   state_index (d, &merged,
                (separate_contexts & CTX_NEWLINE
                 ? CTX_NEWLINE : separate_contexts ^ CTX_ANY));
 
-  free (o_nullable);
-  free (o_nfirst);
-  free (o_firstpos);
-  free (o_nlast);
-  free (o_lastpos);
+  free (posalloc);
+  free (stkalloc);
   free (merged.elems);
+  free (visited);
 }
 
 
@@ -2505,16 +2556,16 @@ dfaanalyze (struct dfa *d, int searchflag)
 void
 dfastate (state_num s, struct dfa *d, state_num trans[])
 {
-  leaf_set *grps;               /* As many as will ever be needed.  */
-  charclass *labels;            /* Labels corresponding to the groups.  */
+  leaf_set grps[NOTCHAR];       /* As many as will ever be needed.  */
+  charclass labels[NOTCHAR];    /* Labels corresponding to the groups.  */
   size_t ngrps = 0;             /* Number of groups actually used.  */
   position pos;                 /* Current position being considered.  */
   charclass matches;            /* Set of matching characters.  */
-  int matchesf;                 /* True if matches is nonempty.  */
+  charclass_word matchesf;     /* Nonzero if matches is nonempty.  */
   charclass intersect;          /* Intersection with some label set.  */
-  int intersectf;               /* True if intersect is nonempty.  */
+  charclass_word intersectf;   /* Nonzero if intersect is nonempty.  */
   charclass leftovers;          /* Stuff in the label that didn't match.  */
-  int leftoversf;               /* True if leftovers is nonempty.  */
+  charclass_word leftoversf;   /* Nonzero if leftovers is nonempty.  */
   position_set follows;         /* Union of the follows of some group.  */
   position_set tmp;             /* Temporary space for merging sets.  */
   int possible_contexts;        /* Contexts that this group can match.  */
@@ -2522,12 +2573,9 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
   state_num state;              /* New state.  */
   state_num state_newline;      /* New state on a newline transition.  */
   state_num state_letter;       /* New state on a letter transition.  */
-  int next_isnt_1st_byte = 0;   /* Flag if we can't add state0.  */
+  bool next_isnt_1st_byte = false; /* We can't add state0.  */
   size_t i, j, k;
 
-  MALLOC (grps, NOTCHAR);
-  MALLOC (labels, NOTCHAR);
-
   zeroset (matches);
 
   for (i = 0; i < d->states[s].elems.nelem; ++i)
@@ -2537,21 +2585,23 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
         setbit (d->tokens[pos.index], matches);
       else if (d->tokens[pos.index] >= CSET)
         copyset (d->charclasses[d->tokens[pos.index] - CSET], matches);
-      else if (MBS_SUPPORT
-               && (d->tokens[pos.index] == ANYCHAR
-                   || d->tokens[pos.index] == MBCSET))
-        /* MB_CUR_MAX > 1  */
+      else
         {
-          /* ANYCHAR and MBCSET must match with a single character, so we
-             must put it to d->states[s].mbps, which contains the positions
-             which can match with a single character not a byte.  */
-          if (d->states[s].mbps.nelem == 0)
-            alloc_position_set (&d->states[s].mbps, 1);
-          insert (pos, &(d->states[s].mbps));
+          if (d->tokens[pos.index] == MBCSET
+              || d->tokens[pos.index] == ANYCHAR)
+            {
+              /* MB_CUR_MAX > 1 */
+              if (d->tokens[pos.index] == MBCSET)
+                d->states[s].has_mbcset = true;
+              /* ANYCHAR and MBCSET must match with a single character, so we
+                 must put it to d->states[s].mbps, which contains the positions
+                 which can match with a single character not a byte.  */
+              if (d->states[s].mbps.nelem == 0)
+                alloc_position_set (&d->states[s].mbps, 1);
+              insert (pos, &(d->states[s].mbps));
+            }
           continue;
         }
-      else
-        continue;
 
       /* Some characters may need to be eliminated from matches because
          they fail in the current context.  */
@@ -2559,21 +2609,21 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
         {
           if (!SUCCEEDS_IN_CONTEXT (pos.constraint,
                                     d->states[s].context, CTX_NEWLINE))
-            for (j = 0; j < CHARCLASS_INTS; ++j)
+            for (j = 0; j < CHARCLASS_WORDS; ++j)
               matches[j] &= ~newline[j];
           if (!SUCCEEDS_IN_CONTEXT (pos.constraint,
                                     d->states[s].context, CTX_LETTER))
-            for (j = 0; j < CHARCLASS_INTS; ++j)
+            for (j = 0; j < CHARCLASS_WORDS; ++j)
               matches[j] &= ~letters[j];
           if (!SUCCEEDS_IN_CONTEXT (pos.constraint,
                                     d->states[s].context, CTX_NONE))
-            for (j = 0; j < CHARCLASS_INTS; ++j)
+            for (j = 0; j < CHARCLASS_WORDS; ++j)
               matches[j] &= letters[j] | newline[j];
 
           /* If there are no characters left, there's no point in going on.  */
-          for (j = 0; j < CHARCLASS_INTS && !matches[j]; ++j)
+          for (j = 0; j < CHARCLASS_WORDS && !matches[j]; ++j)
             continue;
-          if (j == CHARCLASS_INTS)
+          if (j == CHARCLASS_WORDS)
             continue;
         }
 
@@ -2589,20 +2639,20 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
           /* Check if this group's label has a nonempty intersection with
              matches.  */
           intersectf = 0;
-          for (k = 0; k < CHARCLASS_INTS; ++k)
-            (intersect[k] = matches[k] & labels[j][k]) ? (intersectf = 1) : 0;
+          for (k = 0; k < CHARCLASS_WORDS; ++k)
+            intersectf |= intersect[k] = matches[k] & labels[j][k];
           if (!intersectf)
             continue;
 
           /* It does; now find the set differences both ways.  */
           leftoversf = matchesf = 0;
-          for (k = 0; k < CHARCLASS_INTS; ++k)
+          for (k = 0; k < CHARCLASS_WORDS; ++k)
             {
               /* Even an optimizing compiler can't know this for sure.  */
-              int match = matches[k], label = labels[j][k];
+              charclass_word match = matches[k], label = labels[j][k];
 
-              (leftovers[k] = ~match & label) ? (leftoversf = 1) : 0;
-              (matches[k] = match & ~label) ? (matchesf = 1) : 0;
+              leftoversf |= leftovers[k] = ~match & label;
+              matchesf |= matches[k] = match & ~label;
             }
 
           /* If there were leftovers, create a new group labeled with them.  */
@@ -2610,7 +2660,8 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
             {
               copyset (leftovers, labels[ngrps]);
               copyset (intersect, labels[j]);
-              MALLOC (grps[ngrps].elems, d->nleaves);
+              grps[ngrps].elems = xnmalloc (d->nleaves,
+                                            sizeof *grps[ngrps].elems);
               memcpy (grps[ngrps].elems, grps[j].elems,
                       sizeof (grps[j].elems[0]) * grps[j].nelem);
               grps[ngrps].nelem = grps[j].nelem;
@@ -2633,7 +2684,7 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
         {
           copyset (matches, labels[ngrps]);
           zeroset (matches);
-          MALLOC (grps[ngrps].elems, d->nleaves);
+          grps[ngrps].elems = xnmalloc (d->nleaves, sizeof *grps[ngrps].elems);
           grps[ngrps].nelem = 1;
           grps[ngrps].elems[0] = pos.index;
           ++ngrps;
@@ -2679,7 +2730,7 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
         for (k = 0; k < d->follows[grps[i].elems[j]].nelem; ++k)
           insert (d->follows[grps[i].elems[j]].elems[k], &follows);
 
-      if (d->mb_cur_max > 1)
+      if (d->multibyte)
         {
           /* If a token in follows.elems is not 1st byte of a multibyte
              character, or the states of follows must accept the bytes
@@ -2699,12 +2750,12 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
              codepoint of <sb a>, it must not be <sb a> but 2nd byte of
              <mb A>, so we cannot add state[0].  */
 
-          next_isnt_1st_byte = 0;
+          next_isnt_1st_byte = false;
           for (j = 0; j < follows.nelem; ++j)
             {
               if (!(d->multibyte_prop[follows.elems[j].index] & 1))
                 {
-                  next_isnt_1st_byte = 1;
+                  next_isnt_1st_byte = true;
                   break;
                 }
             }
@@ -2712,10 +2763,11 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
 
       /* If we are building a searching matcher, throw in the positions
          of state 0 as well.  */
-      if (d->searchflag
-          && (!MBS_SUPPORT || (d->mb_cur_max == 1 || !next_isnt_1st_byte)))
-        for (j = 0; j < d->states[0].elems.nelem; ++j)
-          insert (d->states[0].elems.elems[j], &follows);
+      if (d->searchflag && (!d->multibyte || !next_isnt_1st_byte))
+        {
+          merge (&d->states[0].elems, &follows, &tmp);
+          copy (&tmp, &follows);
+        }
 
       /* Find out if the new state will want any context information.  */
       possible_contexts = charclass_context (labels[i]);
@@ -2736,11 +2788,11 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
         state_letter = state;
 
       /* Set the transitions for each character in the current label.  */
-      for (j = 0; j < CHARCLASS_INTS; ++j)
-        for (k = 0; k < INTBITS; ++k)
-          if (labels[i][j] & 1U << k)
+      for (j = 0; j < CHARCLASS_WORDS; ++j)
+        for (k = 0; k < CHARCLASS_WORD_BITS; ++k)
+          if (labels[i][j] >> k & 1)
             {
-              int c = j * INTBITS + k;
+              int c = j * CHARCLASS_WORD_BITS + k;
 
               if (c == eolbyte)
                 trans[c] = state_newline;
@@ -2755,8 +2807,31 @@ dfastate (state_num s, struct dfa *d, state_num trans[])
     free (grps[i].elems);
   free (follows.elems);
   free (tmp.elems);
-  free (grps);
-  free (labels);
+}
+
+/* Make sure D's state arrays are large enough to hold NEW_STATE.  */
+static void
+realloc_trans_if_necessary (struct dfa *d, state_num new_state)
+{
+  state_num oldalloc = d->tralloc;
+  if (oldalloc <= new_state)
+    {
+      state_num **realtrans = d->trans ? d->trans - 1 : NULL;
+      size_t newalloc, newalloc1;
+      newalloc1 = new_state + 1;
+      realtrans = x2nrealloc (realtrans, &newalloc1, sizeof *realtrans);
+      realtrans[0] = NULL;
+      d->trans = realtrans + 1;
+      d->tralloc = newalloc = newalloc1 - 1;
+      d->fails = xnrealloc (d->fails, newalloc, sizeof *d->fails);
+      d->success = xnrealloc (d->success, newalloc, sizeof *d->success);
+      d->newlines = xnrealloc (d->newlines, newalloc, sizeof *d->newlines);
+      for (; oldalloc < newalloc; oldalloc++)
+        {
+          d->trans[oldalloc] = NULL;
+          d->fails[oldalloc] = NULL;
+        }
+    }
 }
 
 /* Some routines for manipulating a compiled dfa's transition tables.
@@ -2770,7 +2845,7 @@ static void
 build_state (state_num s, struct dfa *d)
 {
   state_num *trans;             /* The new transition table.  */
-  state_num i;
+  state_num i, maxstate;
 
   /* Set an upper limit on the number of transition tables that will ever
      exist at once.  1024 is arbitrary.  The idea is that the frequently
@@ -2798,30 +2873,17 @@ build_state (state_num s, struct dfa *d)
   if (ACCEPTS_IN_CONTEXT (d->states[s].context, CTX_NONE, s, *d))
     d->success[s] |= CTX_NONE;
 
-  MALLOC (trans, NOTCHAR);
+  trans = xmalloc (NOTCHAR * sizeof *trans);
   dfastate (s, d, trans);
 
   /* Now go through the new transition table, and make sure that the trans
      and fail arrays are allocated large enough to hold a pointer for the
      largest state mentioned in the table.  */
+  maxstate = -1;
   for (i = 0; i < NOTCHAR; ++i)
-    if (trans[i] >= d->tralloc)
-      {
-        state_num oldalloc = d->tralloc;
-
-        while (trans[i] >= d->tralloc)
-          d->tralloc *= 2;
-        REALLOC (d->realtrans, d->tralloc + 1);
-        d->trans = d->realtrans + 1;
-        REALLOC (d->fails, d->tralloc);
-        REALLOC (d->success, d->tralloc);
-        REALLOC (d->newlines, d->tralloc);
-        while (oldalloc < d->tralloc)
-          {
-            d->trans[oldalloc] = NULL;
-            d->fails[oldalloc++] = NULL;
-          }
-      }
+    if (maxstate < trans[i])
+      maxstate = trans[i];
+  realloc_trans_if_necessary (d, maxstate);
 
   /* Keep the newline transition in a special place so we can use it as
      a sentinel.  */
@@ -2837,65 +2899,21 @@ build_state (state_num s, struct dfa *d)
 static void
 build_state_zero (struct dfa *d)
 {
-  d->tralloc = 1;
+  /* Initial size of the transition tables; must be positive.  */
+  int initial_tab_size = 1;
+
+  d->tralloc = 0;
   d->trcount = 0;
-  CALLOC (d->realtrans, d->tralloc + 1);
-  d->trans = d->realtrans + 1;
-  CALLOC (d->fails, d->tralloc);
-  MALLOC (d->success, d->tralloc);
-  MALLOC (d->newlines, d->tralloc);
+  d->trans = NULL;
+  d->fails = NULL;
+  d->success = NULL;
+  d->newlines = NULL;
+  realloc_trans_if_necessary (d, initial_tab_size);
   build_state (0, d);
 }
 
 /* Multibyte character handling sub-routines for dfaexec.  */
 
-/* The initial state may encounter a byte which is not a single byte character
-   nor the first byte of a multibyte character.  But it is incorrect for the
-   initial state to accept such a byte.  For example, in Shift JIS the regular
-   expression "\\" accepts the codepoint 0x5c, but should not accept the second
-   byte of the codepoint 0x815c.  Then the initial state must skip the bytes
-   that are not a single byte character nor the first byte of a multibyte
-   character.  */
-#define SKIP_REMAINS_MB_IF_INITIAL_STATE(s, p)         \
-  if (s == 0)                                          \
-    {                                                  \
-      while (inputwcs[p - buf_begin] == 0              \
-            && mblen_buf[p - buf_begin] > 0            \
-            && (unsigned char const *) p < buf_end)    \
-        ++p;                                           \
-      if ((char *) p >= end)                           \
-        {                                              \
-          free (mblen_buf);                            \
-          free (inputwcs);                             \
-          *end = saved_end;                            \
-          return NULL;                                 \
-        }                                              \
-    }
-
-static void
-realloc_trans_if_necessary (struct dfa *d, state_num new_state)
-{
-  /* Make sure that the trans and fail arrays are allocated large enough
-     to hold a pointer for the new state.  */
-  if (new_state >= d->tralloc)
-    {
-      state_num oldalloc = d->tralloc;
-
-      while (new_state >= d->tralloc)
-        d->tralloc *= 2;
-      REALLOC (d->realtrans, d->tralloc + 1);
-      d->trans = d->realtrans + 1;
-      REALLOC (d->fails, d->tralloc);
-      REALLOC (d->success, d->tralloc);
-      REALLOC (d->newlines, d->tralloc);
-      while (oldalloc < d->tralloc)
-        {
-          d->trans[oldalloc] = NULL;
-          d->fails[oldalloc++] = NULL;
-        }
-    }
-}
-
 /* Return values of transit_state_singlebyte, and
    transit_state_consume_1char.  */
 typedef enum
@@ -2928,14 +2946,7 @@ transit_state_singlebyte (struct dfa *d, state_num s, unsigned char const *p,
             works = 0;
         }
       else if (works < 0)
-        {
-          if (p == buf_end)
-            {
-              /* At the moment, it must not happen.  */
-              abort ();
-            }
-          works = 0;
-        }
+        works = 0;
       else if (d->fails[works])
         {
           works = d->fails[works][*p];
@@ -2950,18 +2961,13 @@ transit_state_singlebyte (struct dfa *d, state_num s, unsigned char const *p,
   return rval;
 }
 
-/* Match a "." against the current context.  buf_begin[IDX] is the
-   current position.  Return the length of the match, in bytes.
-   POS is the position of the ".".  */
+/* Match a "." against the current context.  Return the length of the
+   match, in bytes.  POS is the position of the ".".  */
 static int
-match_anychar (struct dfa *d, state_num s, position pos, size_t idx)
+match_anychar (struct dfa *d, state_num s, position pos,
+               wint_t wc, size_t mbclen)
 {
   int context;
-  wchar_t wc;
-  int mbclen;
-
-  wc = inputwcs[idx];
-  mbclen = (mblen_buf[idx] == 0) ? 1 : mblen_buf[idx];
 
   /* Check syntax bits.  */
   if (wc == (wchar_t) eolbyte)
@@ -2974,6 +2980,8 @@ match_anychar (struct dfa *d, state_num s, position pos, size_t idx)
       if (syntax_bits & RE_DOT_NOT_NULL)
         return 0;
     }
+  else if (wc == WEOF)
+    return 0;
 
   context = wchar_context (wc);
   if (!SUCCEEDS_IN_CONTEXT (pos.constraint, d->states[s].context, context))
@@ -2983,16 +2991,14 @@ match_anychar (struct dfa *d, state_num s, position pos, size_t idx)
 }
 
 /* Match a bracket expression against the current context.
-   buf_begin[IDX] is the current position.
    Return the length of the match, in bytes.
    POS is the position of the bracket expression.  */
 static int
-match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
+match_mb_charset (struct dfa *d, state_num s, position pos,
+                  char const *p, wint_t wc, size_t match_len)
 {
   size_t i;
-  int match;               /* Matching succeeded.  */
-  int match_len;           /* Length of the character (or collating element)
-                              with which this operator matches.  */
+  bool match;              /* Matching succeeded.  */
   int op_len;              /* Length of the operator.  */
   char buffer[128];
 
@@ -3000,9 +3006,6 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
   struct mb_char_classes *work_mbc;
 
   int context;
-  wchar_t wc;                   /* Current referring character.  */
-
-  wc = inputwcs[idx];
 
   /* Check syntax bits.  */
   if (wc == (wchar_t) eolbyte)
@@ -3015,6 +3018,8 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
       if (syntax_bits & RE_DOT_NOT_NULL)
         return 0;
     }
+  else if (wc == WEOF)
+    return 0;
 
   context = wchar_context (wc);
   if (!SUCCEEDS_IN_CONTEXT (pos.constraint, d->states[s].context, context))
@@ -3023,11 +3028,10 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
   /* Assign the current referring operator to work_mbc.  */
   work_mbc = &(d->mbcsets[(d->multibyte_prop[pos.index]) >> 2]);
   match = !work_mbc->invert;
-  match_len = (mblen_buf[idx] == 0) ? 1 : mblen_buf[idx];
 
   /* Match in range 0-255?  */
   if (wc < NOTCHAR && work_mbc->cset != -1
-      && tstbit ((unsigned char) wc, d->charclasses[work_mbc->cset]))
+      && tstbit (to_uchar (wc), d->charclasses[work_mbc->cset]))
     goto charset_matched;
 
   /* match with a character class?  */
@@ -3037,14 +3041,14 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
         goto charset_matched;
     }
 
-  strncpy (buffer, (char const *) buf_begin + idx, match_len);
+  strncpy (buffer, p, match_len);
   buffer[match_len] = '\0';
 
   /* match with an equivalence class?  */
   for (i = 0; i < work_mbc->nequivs; i++)
     {
       op_len = strlen (work_mbc->equivs[i]);
-      strncpy (buffer, (char const *) buf_begin + idx, op_len);
+      strncpy (buffer, p, op_len);
       buffer[op_len] = '\0';
       if (strcoll (work_mbc->equivs[i], buffer) == 0)
         {
@@ -3057,7 +3061,7 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
   for (i = 0; i < work_mbc->ncoll_elems; i++)
     {
       op_len = strlen (work_mbc->coll_elems[i]);
-      strncpy (buffer, (char const *) buf_begin + idx, op_len);
+      strncpy (buffer, p, op_len);
       buffer[op_len] = '\0';
 
       if (strcoll (work_mbc->coll_elems[i], buffer) == 0)
@@ -3070,7 +3074,7 @@ match_mb_charset (struct dfa *d, state_num s, position pos, size_t idx)
   /* match with a range?  */
   for (i = 0; i < work_mbc->nranges; i++)
     {
-      if (work_mbc->range_sts[i] <= wc && wc <= work_mbc->range_ends[i])
+      if (work_mbc->ranges[i].beg <= wc && wc <= work_mbc->ranges[i].end)
         goto charset_matched;
     }
 
@@ -3091,27 +3095,25 @@ charset_matched:
    array which corresponds to 'd->states[s].mbps.elem'; each element of the
    array contains the number of bytes with which the element can match.
 
-   'idx' is the index from buf_begin, and it is the current position
-   in the buffer.
-
    The caller MUST free the array which this function return.  */
 static int *
-check_matching_with_multibyte_ops (struct dfa *d, state_num s, size_t idx)
+check_matching_with_multibyte_ops (struct dfa *d, state_num s,
+                                   char const *p, wint_t wc, size_t mbclen)
 {
   size_t i;
   int *rarray;
 
-  MALLOC (rarray, d->states[s].mbps.nelem);
+  rarray = d->mb_match_lens;
   for (i = 0; i < d->states[s].mbps.nelem; ++i)
     {
       position pos = d->states[s].mbps.elems[i];
       switch (d->tokens[pos.index])
         {
         case ANYCHAR:
-          rarray[i] = match_anychar (d, s, pos, idx);
+          rarray[i] = match_anychar (d, s, pos, wc, mbclen);
           break;
         case MBCSET:
-          rarray[i] = match_mb_charset (d, s, pos, idx);
+          rarray[i] = match_mb_charset (d, s, pos, p, wc, mbclen);
           break;
         default:
           break;                /* cannot happen.  */
@@ -3131,48 +3133,39 @@ check_matching_with_multibyte_ops (struct dfa *d, state_num s, size_t idx)
 static status_transit_state
 transit_state_consume_1char (struct dfa *d, state_num s,
                              unsigned char const **pp,
-                             int *match_lens, int *mbclen, position_set * pps)
+                             wint_t wc, size_t mbclen,
+                             int *match_lens)
 {
   size_t i, j;
   int k;
   state_num s1, s2;
-  int *work_mbls;
   status_transit_state rs = TRANSIT_STATE_DONE;
 
-  /* Calculate the length of the (single/multi byte) character
-     to which p points.  */
-  *mbclen = (mblen_buf[*pp - buf_begin] == 0) ? 1 : mblen_buf[*pp - buf_begin];
+  if (! match_lens && d->states[s].mbps.nelem != 0)
+    match_lens = check_matching_with_multibyte_ops (d, s, (char const *) *pp,
+                                                    wc, mbclen);
 
   /* Calculate the state which can be reached from the state 's' by
-     consuming '*mbclen' single bytes from the buffer.  */
+     consuming 'mbclen' single bytes from the buffer.  */
   s1 = s;
-  for (k = 0; k < *mbclen; k++)
+  for (k = 0; k < mbclen; k++)
     {
       s2 = s1;
       rs = transit_state_singlebyte (d, s2, (*pp)++, &s1);
     }
-  /* Copy the positions contained by 's1' to the set 'pps'.  */
-  copy (&(d->states[s1].elems), pps);
-
-  /* Check (input) match_lens, and initialize if it is NULL.  */
-  if (match_lens == NULL && d->states[s].mbps.nelem != 0)
-    work_mbls = check_matching_with_multibyte_ops (d, s, *pp - buf_begin);
-  else
-    work_mbls = match_lens;
+  copy (&d->states[s1].elems, &d->mb_follows);
 
   /* Add all of the positions which can be reached from 's' by consuming
      a single character.  */
   for (i = 0; i < d->states[s].mbps.nelem; i++)
     {
-      if (work_mbls[i] == *mbclen)
+      if (match_lens[i] == mbclen)
         for (j = 0; j < d->follows[d->states[s].mbps.elems[i].index].nelem;
              j++)
-          insert (d->follows[d->states[s].mbps.elems[i].index].elems[j], pps);
+          insert (d->follows[d->states[s].mbps.elems[i].index].elems[j],
+                  &d->mb_follows);
     }
 
-  if (match_lens == NULL && work_mbls != NULL)
-    free (work_mbls);
-
   /* FIXME: this return value is always ignored.  */
   return rs;
 }
@@ -3181,7 +3174,8 @@ transit_state_consume_1char (struct dfa *d, state_num s,
    buffer.  This function is for some operator which can match with a multi-
    byte character or a collating element (which may be multi characters).  */
 static state_num
-transit_state (struct dfa *d, state_num s, unsigned char const **pp)
+transit_state (struct dfa *d, state_num s, unsigned char const **pp,
+               unsigned char const *end)
 {
   state_num s1;
   int mbclen;  /* The length of current input multibyte character.  */
@@ -3189,16 +3183,17 @@ transit_state (struct dfa *d, state_num s, unsigned char const **pp)
   size_t i, j;
   int *match_lens = NULL;
   size_t nelem = d->states[s].mbps.nelem;       /* Just a alias.  */
-  position_set follows;
   unsigned char const *p1 = *pp;
-  wchar_t wc;
+  wint_t wc;
 
   if (nelem > 0)
     /* This state has (a) multibyte operator(s).
        We check whether each of them can match or not.  */
     {
       /* Note: caller must free the return value of this function.  */
-      match_lens = check_matching_with_multibyte_ops (d, s, *pp - buf_begin);
+      mbclen = mbs_to_wchar (&wc, (char const *) *pp, end - *pp, d);
+      match_lens = check_matching_with_multibyte_ops (d, s, (char const *) *pp,
+                                                      wc, mbclen);
 
       for (i = 0; i < nelem; i++)
         /* Search the operator which match the longest string,
@@ -3220,26 +3215,25 @@ transit_state (struct dfa *d, state_num s, unsigned char const **pp)
       if (rs == TRANSIT_STATE_DONE)
         ++*pp;
 
-      free (match_lens);
       return s1;
     }
 
   /* This state has some operators which can match a multibyte character.  */
-  alloc_position_set (&follows, d->nleaves);
+  d->mb_follows.nelem = 0;
 
   /* 'maxlen' may be longer than the length of a character, because it may
      not be a character but a (multi character) collating element.
      We enumerate all of the positions which 's' can reach by consuming
      'maxlen' bytes.  */
-  transit_state_consume_1char (d, s, pp, match_lens, &mbclen, &follows);
+  transit_state_consume_1char (d, s, pp, wc, mbclen, match_lens);
 
-  wc = inputwcs[*pp - mbclen - buf_begin];
-  s1 = state_index (d, &follows, wchar_context (wc));
+  s1 = state_index (d, &d->mb_follows, wchar_context (wc));
   realloc_trans_if_necessary (d, s1);
 
   while (*pp - p1 < maxlen)
     {
-      transit_state_consume_1char (d, s1, pp, NULL, &mbclen, &follows);
+      mbclen = mbs_to_wchar (&wc, (char const *) *pp, end - *pp, d);
+      transit_state_consume_1char (d, s1, pp, wc, mbclen, NULL);
 
       for (i = 0; i < nelem; i++)
         {
@@ -3247,68 +3241,15 @@ transit_state (struct dfa *d, state_num s, unsigned char const **pp)
             for (j = 0;
                  j < d->follows[d->states[s1].mbps.elems[i].index].nelem; j++)
               insert (d->follows[d->states[s1].mbps.elems[i].index].elems[j],
-                      &follows);
+                      &d->mb_follows);
         }
 
-      wc = inputwcs[*pp - mbclen - buf_begin];
-      s1 = state_index (d, &follows, wchar_context (wc));
+      s1 = state_index (d, &d->mb_follows, wchar_context (wc));
       realloc_trans_if_necessary (d, s1);
     }
-  free (match_lens);
-  free (follows.elems);
   return s1;
 }
 
-
-/* Initialize mblen_buf and inputwcs with data from the next line.  */
-
-static void
-prepare_wc_buf (const char *begin, const char *end)
-{
-#if MBS_SUPPORT
-  unsigned char eol = eolbyte;
-  size_t remain_bytes, i;
-
-  buf_begin = (unsigned char *) begin;
-
-  remain_bytes = 0;
-  for (i = 0; i < end - begin + 1; i++)
-    {
-      if (remain_bytes == 0)
-        {
-          remain_bytes
-            = mbrtowc (inputwcs + i, begin + i, end - begin - i + 1, &mbs);
-          if (remain_bytes < 1
-              || remain_bytes == (size_t) -1
-              || remain_bytes == (size_t) -2
-              || (remain_bytes == 1 && inputwcs[i] == (wchar_t) begin[i]))
-            {
-              remain_bytes = 0;
-              inputwcs[i] = (wchar_t) begin[i];
-              mblen_buf[i] = 0;
-              if (begin[i] == eol)
-                break;
-            }
-          else
-            {
-              mblen_buf[i] = remain_bytes;
-              remain_bytes--;
-            }
-        }
-      else
-        {
-          mblen_buf[i] = remain_bytes;
-          inputwcs[i] = 0;
-          remain_bytes--;
-        }
-    }
-
-  buf_end = (unsigned char *) (begin + i);
-  mblen_buf[i] = 0;
-  inputwcs[i] = 0;              /* sentinel */
-#endif /* MBS_SUPPORT */
-}
-
 /* Search through a buffer looking for a match to the given struct dfa.
    Find the first occurrence of a string matching the regexp in the
    buffer, and the shortest possible version thereof.  Return a pointer to
@@ -3326,39 +3267,64 @@ dfaexec (struct dfa *d, char const *begin, char *end,
          int allow_nl, size_t *count, int *backref)
 {
   state_num s, s1;              /* Current state.  */
-  unsigned char const *p;       /* Current input character.  */
+  unsigned char const *p, *mbp; /* Current input character.  */
   state_num **trans, *t;        /* Copy of d->trans so it can be optimized
                                    into a register.  */
   unsigned char eol = eolbyte;  /* Likewise for eolbyte.  */
   unsigned char saved_end;
+  size_t nlcount = 0;
 
   if (!d->tralloc)
     build_state_zero (d);
 
   s = s1 = 0;
-  p = (unsigned char const *) begin;
+  p = mbp = (unsigned char const *) begin;
   trans = d->trans;
   saved_end = *(unsigned char *) end;
   *end = eol;
 
-  if (d->mb_cur_max > 1)
+  if (d->multibyte)
     {
-      MALLOC (mblen_buf, end - begin + 2);
-      MALLOC (inputwcs, end - begin + 2);
-      memset (&mbs, 0, sizeof (mbstate_t));
-      prepare_wc_buf ((const char *) p, end);
+      memset (&d->mbs, 0, sizeof d->mbs);
+      if (! d->mb_match_lens)
+        {
+          d->mb_match_lens = xnmalloc (d->nleaves, sizeof *d->mb_match_lens);
+          alloc_position_set (&d->mb_follows, d->nleaves);
+        }
     }
 
   for (;;)
     {
-      if (d->mb_cur_max > 1)
+      if (d->multibyte)
         {
           while ((t = trans[s]) != NULL)
             {
-              if (p > buf_end)
-                break;
               s1 = s;
-              SKIP_REMAINS_MB_IF_INITIAL_STATE (s, p);
+
+              if (s == 0)
+                {
+                  /* The initial state may encounter a byte which is not
+                     a single byte character nor the first byte of a
+                     multibyte character.  But it is incorrect for the
+                     initial state to accept such a byte.  For example,
+                     in Shift JIS the regular expression "\\" accepts
+                     the codepoint 0x5c, but should not accept the second
+                     byte of the codepoint 0x815c.  Then the initial
+                     state must skip the bytes that are not a single
+                     byte character nor the first byte of a multibyte
+                     character.  */
+                  wint_t wc;
+                  while (mbp < p)
+                    mbp += mbs_to_wchar (&wc, (char const *) mbp,
+                                         end - (char const *) mbp, d);
+                  p = mbp;
+
+                  if ((char *) p > end)
+                    {
+                      p = NULL;
+                      goto done;
+                    }
+                }
 
               if (d->states[s].mbps.nelem == 0)
                 {
@@ -3370,18 +3336,16 @@ dfaexec (struct dfa *d, char const *begin, char *end,
                  better performance (up to 25% better on [a-z], for
                  example) and enables support for collating symbols and
                  equivalence classes.  */
-              if (backref)
+              if (d->states[s].has_mbcset && backref)
                 {
                   *backref = 1;
-                  free (mblen_buf);
-                  free (inputwcs);
-                  *end = saved_end;
-                  return (char *) p;
+                  goto done;
                 }
 
               /* Can match with a multibyte character (and multi character
                  collating element).  Transition table might be updated.  */
-              s = transit_state (d, s, &p);
+              s = transit_state (d, s, &p, (unsigned char *) end);
+              mbp = p;
               trans = d->trans;
             }
         }
@@ -3401,27 +3365,28 @@ dfaexec (struct dfa *d, char const *begin, char *end,
             }
         }
 
-      if (s >= 0 && (char *) p <= end && d->fails[s])
+      if ((char *) p > end)
+        {
+          p = NULL;
+          goto done;
+        }
+
+      if (s >= 0 && d->fails[s])
         {
           if (d->success[s] & sbit[*p])
             {
               if (backref)
-                *backref = (d->states[s].backref != 0);
-              if (d->mb_cur_max > 1)
-                {
-                  free (mblen_buf);
-                  free (inputwcs);
-                }
-              *end = saved_end;
-              return (char *) p;
+                *backref = d->states[s].has_backref;
+              goto done;
             }
 
           s1 = s;
-          if (d->mb_cur_max > 1)
+          if (d->multibyte)
             {
               /* Can match with a multibyte character (and multicharacter
                  collating element).  Transition table might be updated.  */
-              s = transit_state (d, s, &p);
+              s = transit_state (d, s, &p, (unsigned char *) end);
+              mbp = p;
               trans = d->trans;
             }
           else
@@ -3429,31 +3394,18 @@ dfaexec (struct dfa *d, char const *begin, char *end,
           continue;
         }
 
-      /* If the previous character was a newline, count it.  */
-      if ((char *) p <= end && p[-1] == eol)
+      /* If the previous character was a newline, count it, and skip
+         checking of multibyte character boundary until here.  */
+      if (p[-1] == eol && (char *) p != begin)
         {
-          if (count)
-            ++*count;
-
-          if (d->mb_cur_max > 1)
-            prepare_wc_buf ((const char *) p, end);
-        }
-
-      /* Check if we've run off the end of the buffer.  */
-      if ((char *) p > end)
-        {
-          if (d->mb_cur_max > 1)
-            {
-              free (mblen_buf);
-              free (inputwcs);
-            }
-          *end = saved_end;
-          return NULL;
+          nlcount++;
+          mbp = p;
         }
 
       if (s >= 0)
         {
-          build_state (s, d);
+          if (!d->trans[s])
+            build_state (s, d);
           trans = d->trans;
           continue;
         }
@@ -3466,6 +3418,24 @@ dfaexec (struct dfa *d, char const *begin, char *end,
 
       s = 0;
     }
+
+ done:
+  if (count)
+    *count += nlcount;
+  *end = saved_end;
+  return (char *) p;
+}
+
+struct dfa *
+dfasuperset (struct dfa const *d)
+{
+  return d->superset;
+}
+
+bool
+dfaisfast (struct dfa const *d)
+{
+  return d->fast;
 }
 
 static void
@@ -3474,7 +3444,6 @@ free_mbdata (struct dfa *d)
   size_t i;
 
   free (d->multibyte_prop);
-  d->multibyte_prop = NULL;
 
   for (i = 0; i < d->nmbcsets; ++i)
     {
@@ -3482,8 +3451,7 @@ free_mbdata (struct dfa *d)
       struct mb_char_classes *p = &(d->mbcsets[i]);
       free (p->chars);
       free (p->ch_classes);
-      free (p->range_sts);
-      free (p->range_ends);
+      free (p->ranges);
 
       for (j = 0; j < p->nequivs; ++j)
         free (p->equivs[j]);
@@ -3495,8 +3463,9 @@ free_mbdata (struct dfa *d)
     }
 
   free (d->mbcsets);
-  d->mbcsets = NULL;
-  d->nmbcsets = 0;
+  free (d->mb_follows.elems);
+  free (d->mb_match_lens);
+  d->mb_match_lens = NULL;
 }
 
 /* Initialize the components of a dfa that the other routines don't
@@ -3505,30 +3474,17 @@ void
 dfainit (struct dfa *d)
 {
   memset (d, 0, sizeof *d);
-
-  d->calloc = 1;
-  MALLOC (d->charclasses, d->calloc);
-
-  d->talloc = 1;
-  MALLOC (d->tokens, d->talloc);
-
-  d->mb_cur_max = MB_CUR_MAX;
-
-  if (d->mb_cur_max > 1)
-    {
-      d->nmultibyte_prop = 1;
-      MALLOC (d->multibyte_prop, d->nmultibyte_prop);
-      d->mbcsets_alloc = 1;
-      MALLOC (d->mbcsets, d->mbcsets_alloc);
-    }
+  d->multibyte = MB_CUR_MAX > 1;
+  d->fast = !d->multibyte;
 }
 
 static void
 dfaoptimize (struct dfa *d)
 {
   size_t i;
+  bool have_backref = false;
 
-  if (!MBS_SUPPORT || !using_utf8 ())
+  if (!using_utf8 ())
     return;
 
   for (i = 0; i < d->tindex; ++i)
@@ -3538,6 +3494,9 @@ dfaoptimize (struct dfa *d)
         case ANYCHAR:
           /* Lowered.  */
           abort ();
+        case BACKREF:
+          have_backref = true;
+          break;
         case MBCSET:
           /* Requires multi-byte algorithm.  */
           return;
@@ -3546,8 +3505,95 @@ dfaoptimize (struct dfa *d)
         }
     }
 
+  if (!have_backref && d->superset)
+    {
+      /* The superset DFA is not likely to be much faster, so remove it.  */
+      dfafree (d->superset);
+      free (d->superset);
+      d->superset = NULL;
+    }
+
   free_mbdata (d);
-  d->mb_cur_max = 1;
+  d->multibyte = false;
+}
+
+static void
+dfassbuild (struct dfa *d)
+{
+  size_t i, j;
+  charclass ccl;
+  bool have_achar = false;
+  bool have_nchar = false;
+  struct dfa *sup = dfaalloc ();
+
+  *sup = *d;
+  sup->multibyte = false;
+  sup->multibyte_prop = NULL;
+  sup->mbcsets = NULL;
+  sup->superset = NULL;
+  sup->states = NULL;
+  sup->sindex = 0;
+  sup->follows = NULL;
+  sup->tralloc = 0;
+  sup->trans = NULL;
+  sup->fails = NULL;
+  sup->success = NULL;
+  sup->newlines = NULL;
+  sup->musts = NULL;
+
+  sup->charclasses = xnmalloc (sup->calloc, sizeof *sup->charclasses);
+  memcpy (sup->charclasses, d->charclasses,
+          d->cindex * sizeof *sup->charclasses);
+
+  sup->tokens = xnmalloc (d->tindex, 2 * sizeof *sup->tokens);
+  sup->talloc = d->tindex * 2;
+
+  for (i = j = 0; i < d->tindex; i++)
+    {
+      switch (d->tokens[i])
+        {
+        case ANYCHAR:
+        case MBCSET:
+        case BACKREF:
+          zeroset (ccl);
+          notset (ccl);
+          sup->tokens[j++] = CSET + dfa_charclass_index (sup, ccl);
+          sup->tokens[j++] = STAR;
+          if (d->tokens[i + 1] == QMARK || d->tokens[i + 1] == STAR
+              || d->tokens[i + 1] == PLUS)
+            i++;
+          have_achar = true;
+          break;
+        case BEGWORD:
+        case ENDWORD:
+        case LIMWORD:
+        case NOTLIMWORD:
+          if (d->multibyte)
+            {
+              /* These constraints aren't supported in a multibyte locale.
+                 Ignore them in the superset DFA, and treat them as
+                 backreferences in the main DFA.  */
+              sup->tokens[j++] = EMPTY;
+              d->tokens[i] = BACKREF;
+              break;
+            }
+        default:
+          sup->tokens[j++] = d->tokens[i];
+          if ((0 <= d->tokens[i] && d->tokens[i] < NOTCHAR)
+              || d->tokens[i] >= CSET)
+            have_nchar = true;
+          break;
+        }
+    }
+  sup->tindex = j;
+
+  if (have_nchar && (have_achar || d->multibyte))
+    d->superset = sup;
+  else
+    {
+      dfafree (sup);
+      free (sup);
+    }
 }
 
 /* Parse and analyze a single string of the given length.  */
@@ -3555,10 +3601,17 @@ void
 dfacomp (char const *s, size_t len, struct dfa *d, int searchflag)
 {
   dfainit (d);
+  dfambcache (d);
   dfaparse (s, len, d);
   dfamust (d);
+  dfassbuild (d);
   dfaoptimize (d);
   dfaanalyze (d, searchflag);
+  if (d->superset)
+    {
+      d->fast = true;
+      dfaanalyze (d->superset, searchflag);
+    }
 }
 
 /* Free the storage held by the components of a dfa.  */
@@ -3571,34 +3624,46 @@ dfafree (struct dfa *d)
   free (d->charclasses);
   free (d->tokens);
 
-  if (d->mb_cur_max > 1)
+  if (d->multibyte)
     free_mbdata (d);
 
   for (i = 0; i < d->sindex; ++i)
     {
       free (d->states[i].elems.elems);
-      if (MBS_SUPPORT)
-        free (d->states[i].mbps.elems);
+      free (d->states[i].mbps.elems);
     }
   free (d->states);
-  for (i = 0; i < d->tindex; ++i)
-    free (d->follows[i].elems);
-  free (d->follows);
-  for (i = 0; i < d->tralloc; ++i)
+
+  if (d->follows)
     {
-      free (d->trans[i]);
-      free (d->fails[i]);
+      for (i = 0; i < d->tindex; ++i)
+        free (d->follows[i].elems);
+      free (d->follows);
     }
-  free (d->realtrans);
-  free (d->fails);
-  free (d->newlines);
-  free (d->success);
+
+  if (d->trans)
+    {
+      for (i = 0; i < d->tralloc; ++i)
+        {
+          free (d->trans[i]);
+          free (d->fails[i]);
+        }
+
+      free (d->trans - 1);
+      free (d->fails);
+      free (d->newlines);
+      free (d->success);
+    }
+
   for (dm = d->musts; dm; dm = ndm)
     {
       ndm = dm->next;
       free (dm->must);
       free (dm);
     }
+
+  if (d->superset)
+    dfafree (d->superset);
 }
 
 /* Having found the postfix representation of the regular expression,
@@ -3689,21 +3754,16 @@ static char *
 icatalloc (char *old, char const *new)
 {
   char *result;
-  size_t oldsize = old == NULL ? 0 : strlen (old);
-  size_t newsize = new == NULL ? 0 : strlen (new);
+  size_t oldsize;
+  size_t newsize = strlen (new);
   if (newsize == 0)
     return old;
+  oldsize = strlen (old);
   result = xrealloc (old, oldsize + newsize + 1);
   memcpy (result + oldsize, new, newsize + 1);
   return result;
 }
 
-static char *
-icpyalloc (char const *string)
-{
-  return icatalloc (NULL, string);
-}
-
 static char *_GL_ATTRIBUTE_PURE
 istrstr (char const *lookin, char const *lookfor)
 {
@@ -3720,29 +3780,15 @@ istrstr (char const *lookin, char const *lookfor)
 static void
 freelist (char **cpp)
 {
-  size_t i;
-
-  if (cpp == NULL)
-    return;
-  for (i = 0; cpp[i] != NULL; ++i)
-    {
-      free (cpp[i]);
-      cpp[i] = NULL;
-    }
+  while (*cpp)
+    free (*cpp++);
 }
 
 static char **
 enlist (char **cpp, char *new, size_t len)
 {
   size_t i, j;
-
-  if (cpp == NULL)
-    return NULL;
-  if ((new = icpyalloc (new)) == NULL)
-    {
-      freelist (cpp);
-      return NULL;
-    }
+  new = memcpy (xmalloc (len + 1), new, len);
   new[len] = '\0';
   /* Is there already something in the list that's new (or longer)?  */
   for (i = 0; cpp[i] != NULL; ++i)
@@ -3765,53 +3811,35 @@ enlist (char **cpp, char *new, size_t len)
         cpp[i] = NULL;
       }
   /* Add the new string.  */
-  REALLOC (cpp, i + 2);
+  cpp = xnrealloc (cpp, i + 2, sizeof *cpp);
   cpp[i] = new;
   cpp[i + 1] = NULL;
   return cpp;
 }
 
 /* Given pointers to two strings, return a pointer to an allocated
-   list of their distinct common substrings.  Return NULL if something
-   seems wild.  */
+   list of their distinct common substrings.  */
 static char **
 comsubs (char *left, char const *right)
 {
-  char **cpp;
+  char **cpp = xzalloc (sizeof *cpp);
   char *lcp;
-  char *rcp;
-  size_t i, len;
-
-  if (left == NULL || right == NULL)
-    return NULL;
-  cpp = malloc (sizeof *cpp);
-  if (cpp == NULL)
-    return NULL;
-  cpp[0] = NULL;
+
   for (lcp = left; *lcp != '\0'; ++lcp)
     {
-      len = 0;
-      rcp = strchr (right, *lcp);
+      size_t len = 0;
+      char *rcp = strchr (right, *lcp);
       while (rcp != NULL)
         {
+          size_t i;
           for (i = 1; lcp[i] != '\0' && lcp[i] == rcp[i]; ++i)
             continue;
           if (i > len)
             len = i;
           rcp = strchr (rcp + 1, *lcp);
         }
-      if (len == 0)
-        continue;
-      {
-        char **p = enlist (cpp, lcp, len);
-        if (p == NULL)
-          {
-            freelist (cpp);
-            cpp = NULL;
-            break;
-          }
-        cpp = p;
-      }
+      if (len != 0)
+        cpp = enlist (cpp, lcp, len);
     }
   return cpp;
 }
@@ -3819,16 +3847,8 @@ comsubs (char *left, char const *right)
 static char **
 addlists (char **old, char **new)
 {
-  size_t i;
-
-  if (old == NULL || new == NULL)
-    return NULL;
-  for (i = 0; new[i] != NULL; ++i)
-    {
-      old = enlist (old, new[i], strlen (new[i]));
-      if (old == NULL)
-        break;
-    }
+  for (; *new; new++)
+    old = enlist (old, *new, strlen (*new));
   return old;
 }
 
@@ -3837,125 +3857,127 @@ addlists (char **old, char **new)
 static char **
 inboth (char **left, char **right)
 {
-  char **both;
-  char **temp;
+  char **both = xzalloc (sizeof *both);
   size_t lnum, rnum;
 
-  if (left == NULL || right == NULL)
-    return NULL;
-  both = malloc (sizeof *both);
-  if (both == NULL)
-    return NULL;
-  both[0] = NULL;
   for (lnum = 0; left[lnum] != NULL; ++lnum)
     {
       for (rnum = 0; right[rnum] != NULL; ++rnum)
         {
-          temp = comsubs (left[lnum], right[rnum]);
-          if (temp == NULL)
-            {
-              freelist (both);
-              return NULL;
-            }
+          char **temp = comsubs (left[lnum], right[rnum]);
           both = addlists (both, temp);
           freelist (temp);
           free (temp);
-          if (both == NULL)
-            return NULL;
         }
     }
   return both;
 }
 
-typedef struct
+typedef struct must must;
+
+struct must
 {
   char **in;
   char *left;
   char *right;
   char *is;
-} must;
+  bool begline;
+  bool endline;
+  must *prev;
+};
+
+static must *
+allocmust (must *mp)
+{
+  must *new_mp = xmalloc (sizeof *new_mp);
+  new_mp->in = xzalloc (sizeof *new_mp->in);
+  new_mp->left = xzalloc (2);
+  new_mp->right = xzalloc (2);
+  new_mp->is = xzalloc (2);
+  new_mp->begline = false;
+  new_mp->endline = false;
+  new_mp->prev = mp;
+  return new_mp;
+}
 
 static void
-resetmust (must * mp)
+resetmust (must *mp)
 {
+  freelist (mp->in);
+  mp->in[0] = NULL;
   mp->left[0] = mp->right[0] = mp->is[0] = '\0';
+  mp->begline = false;
+  mp->endline = false;
+}
+
+static void
+freemust (must *mp)
+{
   freelist (mp->in);
+  free (mp->in);
+  free (mp->left);
+  free (mp->right);
+  free (mp->is);
+  free (mp);
 }
 
 static void
 dfamust (struct dfa *d)
 {
-  must *musts;
-  must *mp;
-  char *result;
+  must *mp = NULL;
+  char const *result = "";
   size_t ri;
   size_t i;
-  int exact;
-  token t;
-  static must must0;
+  bool exact = false;
+  bool begline = false;
+  bool endline = false;
   struct dfamust *dm;
-  static char empty_string[] = "";
-
-  result = empty_string;
-  exact = 0;
-  MALLOC (musts, d->tindex + 1);
-  mp = musts;
-  for (i = 0; i <= d->tindex; ++i)
-    mp[i] = must0;
-  for (i = 0; i <= d->tindex; ++i)
-    {
-      mp[i].in = xmalloc (sizeof *mp[i].in);
-      mp[i].left = xmalloc (2);
-      mp[i].right = xmalloc (2);
-      mp[i].is = xmalloc (2);
-      mp[i].left[0] = mp[i].right[0] = mp[i].is[0] = '\0';
-      mp[i].in[0] = NULL;
-    }
-#ifdef DEBUG
-  fprintf (stderr, "dfamust:\n");
-  for (i = 0; i < d->tindex; ++i)
-    {
-      fprintf (stderr, " %zd:", i);
-      prtok (d->tokens[i]);
-    }
-  putc ('\n', stderr);
-#endif
+
   for (ri = 0; ri < d->tindex; ++ri)
     {
-      switch (t = d->tokens[ri])
+      token t = d->tokens[ri];
+      switch (t)
         {
+        case BEGLINE:
+          mp = allocmust (mp);
+          mp->begline = true;
+          break;
+        case ENDLINE:
+          mp = allocmust (mp);
+          mp->endline = true;
+          break;
         case LPAREN:
         case RPAREN:
           assert (!"neither LPAREN nor RPAREN may appear here");
+
         case EMPTY:
-        case BEGLINE:
-        case ENDLINE:
         case BEGWORD:
         case ENDWORD:
         case LIMWORD:
         case NOTLIMWORD:
         case BACKREF:
-          resetmust (mp);
+        case ANYCHAR:
+        case MBCSET:
+          mp = allocmust (mp);
           break;
+
         case STAR:
         case QMARK:
-          assert (musts < mp);
-          --mp;
           resetmust (mp);
           break;
+
         case OR:
-          assert (&musts[2] <= mp);
           {
             char **new;
-            must *lmp;
-            must *rmp;
+            must *rmp = mp;
+            must *lmp = mp = mp->prev;
             size_t j, ln, rn, n;
 
-            rmp = --mp;
-            lmp = --mp;
             /* Guaranteed to be.  Unlikely, but ...  */
             if (!STREQ (lmp->is, rmp->is))
               lmp->is[0] = '\0';
+            lmp->begline &= rmp->begline;
+            lmp->endline &= rmp->endline;
             /* Left side--easy */
             i = 0;
             while (lmp->left[i] != '\0' && lmp->left[i] == rmp->left[i])
@@ -3974,133 +3996,126 @@ dfamust (struct dfa *d)
               lmp->right[j] = lmp->right[(ln - i) + j];
             lmp->right[j] = '\0';
             new = inboth (lmp->in, rmp->in);
-            if (new == NULL)
-              goto done;
             freelist (lmp->in);
             free (lmp->in);
             lmp->in = new;
+            freemust (rmp);
           }
           break;
+
         case PLUS:
-          assert (musts < mp);
-          --mp;
           mp->is[0] = '\0';
           break;
+
         case END:
-          assert (mp == &musts[1]);
-          for (i = 0; musts[0].in[i] != NULL; ++i)
-            if (strlen (musts[0].in[i]) > strlen (result))
-              result = musts[0].in[i];
-          if (STREQ (result, musts[0].is))
-            exact = 1;
+          assert (!mp->prev);
+          for (i = 0; mp->in[i] != NULL; ++i)
+            if (strlen (mp->in[i]) > strlen (result))
+              result = mp->in[i];
+          if (STREQ (result, mp->is))
+            {
+              exact = true;
+              begline = mp->begline;
+              endline = mp->endline;
+            }
           goto done;
+
         case CAT:
-          assert (&musts[2] <= mp);
           {
-            must *lmp;
-            must *rmp;
+            must *rmp = mp;
+            must *lmp = mp = mp->prev;
 
-            rmp = --mp;
-            lmp = --mp;
             /* In.  Everything in left, plus everything in
                right, plus concatenation of
                left's right and right's left.  */
             lmp->in = addlists (lmp->in, rmp->in);
-            if (lmp->in == NULL)
-              goto done;
             if (lmp->right[0] != '\0' && rmp->left[0] != '\0')
               {
-                char *tp;
-
-                tp = icpyalloc (lmp->right);
-                tp = icatalloc (tp, rmp->left);
-                lmp->in = enlist (lmp->in, tp, strlen (tp));
+                size_t lrlen = strlen (lmp->right);
+                size_t rllen = strlen (rmp->left);
+                char *tp = xmalloc (lrlen + rllen);
+                memcpy (tp, lmp->right, lrlen);
+                memcpy (tp + lrlen, rmp->left, rllen);
+                lmp->in = enlist (lmp->in, tp, lrlen + rllen);
                 free (tp);
-                if (lmp->in == NULL)
-                  goto done;
               }
             /* Left-hand */
             if (lmp->is[0] != '\0')
-              {
-                lmp->left = icatalloc (lmp->left, rmp->left);
-                if (lmp->left == NULL)
-                  goto done;
-              }
+              lmp->left = icatalloc (lmp->left, rmp->left);
             /* Right-hand */
             if (rmp->is[0] == '\0')
               lmp->right[0] = '\0';
             lmp->right = icatalloc (lmp->right, rmp->right);
-            if (lmp->right == NULL)
-              goto done;
             /* Guaranteed to be */
-            if (lmp->is[0] != '\0' && rmp->is[0] != '\0')
+            if ((lmp->is[0] != '\0' || lmp->begline)
+                && (rmp->is[0] != '\0' || rmp->endline))
               {
                 lmp->is = icatalloc (lmp->is, rmp->is);
-                if (lmp->is == NULL)
-                  goto done;
+                lmp->endline = rmp->endline;
               }
             else
-              lmp->is[0] = '\0';
+              {
+                lmp->is[0] = '\0';
+                lmp->begline = false;
+                lmp->endline = false;
+              }
+            freemust (rmp);
           }
           break;
+
+        case '\0':
+          /* Not on *my* shift.  */
+          goto done;
+
         default:
-          if (t < END)
-            {
-              assert (!"oops! t >= END");
-            }
-          else if (t == '\0')
+          mp = allocmust (mp);
+          if (CSET <= t)
             {
-              /* not on *my* shift */
-              goto done;
-            }
-          else if (t >= CSET || !MBS_SUPPORT || t == ANYCHAR || t == MBCSET)
-            {
-              /* easy enough */
-              resetmust (mp);
-            }
-          else
-            {
-              /* plain character */
-              resetmust (mp);
-              mp->is[0] = mp->left[0] = mp->right[0] = t;
-              mp->is[1] = mp->left[1] = mp->right[1] = '\0';
-              mp->in = enlist (mp->in, mp->is, (size_t) 1);
-              if (mp->in == NULL)
-                goto done;
+              /* If T is a singleton, or if case-folding in a unibyte
+                 locale and T's members all case-fold to the same char,
+                 convert T to one of its members.  Otherwise, do
+                 nothing further with T.  */
+              charclass *ccl = &d->charclasses[t - CSET];
+              int j;
+              for (j = 0; j < NOTCHAR; j++)
+                if (tstbit (j, *ccl))
+                  break;
+              if (! (j < NOTCHAR))
+                break;
+              t = j;
+              while (++j < NOTCHAR)
+                if (tstbit (j, *ccl)
+                    && ! (case_fold && !d->multibyte
+                          && toupper (j) == toupper (t)))
+                  break;
+              if (j < NOTCHAR)
+                break;
             }
+          mp->is[0] = mp->left[0] = mp->right[0]
+            = case_fold && !d->multibyte ? toupper (t) : t;
+          mp->is[1] = mp->left[1] = mp->right[1] = '\0';
+          mp->in = enlist (mp->in, mp->is, 1);
           break;
         }
-#ifdef DEBUG
-      fprintf (stderr, " node: %zd:", ri);
-      prtok (d->tokens[ri]);
-      fprintf (stderr, "\n  in:");
-      for (i = 0; mp->in[i]; ++i)
-        fprintf (stderr, " \"%s\"", mp->in[i]);
-      fprintf (stderr, "\n  is: \"%s\"\n", mp->is);
-      fprintf (stderr, "  left: \"%s\"\n", mp->left);
-      fprintf (stderr, "  right: \"%s\"\n", mp->right);
-#endif
-      ++mp;
     }
 done:
-  if (strlen (result))
+  if (*result)
     {
-      MALLOC (dm, 1);
+      dm = xmalloc (sizeof *dm);
       dm->exact = exact;
-      dm->must = xmemdup (result, strlen (result) + 1);
+      dm->begline = begline;
+      dm->endline = endline;
+      dm->must = xstrdup (result);
       dm->next = d->musts;
       d->musts = dm;
     }
-  mp = musts;
-  for (i = 0; i <= d->tindex; ++i)
+
+  while (mp)
     {
-      freelist (mp[i].in);
-      free (mp[i].in);
-      free (mp[i].left);
-      free (mp[i].right);
-      free (mp[i].is);
+      must *prev = mp->prev;
+      freemust (mp);
+      mp = prev;
     }
-  free (mp);
 }
 
 struct dfa *
index bacd489..f30c3cb 100644 (file)
--- a/src/dfa.h
+++ b/src/dfa.h
 /* Written June, 1988 by Mike Haertel */
 
 #include <regex.h>
+#include <stdbool.h>
 #include <stddef.h>
 
 /* Element of a list of strings, at least one of which is known to
    appear in any R.E. matching the DFA. */
 struct dfamust
 {
-  int exact;
+  bool exact;
+  bool begline;
+  bool endline;
   char *must;
   struct dfamust *next;
 };
@@ -68,6 +71,15 @@ extern void dfacomp (char const *, size_t, struct dfa *, int);
 extern char *dfaexec (struct dfa *d, char const *begin, char *end,
                       int newline, size_t *count, int *backref);
 
+/* Return a superset for D.  The superset matches everything that D
+   matches, along with some other strings (though the latter should be
+   rare, for efficiency reasons).  Return a null pointer if no useful
+   superset is available.  */
+extern struct dfa *dfasuperset (struct dfa const *d) _GL_ATTRIBUTE_PURE;
+
+/* The DFA is likely to be fast.  */
+extern bool dfaisfast (struct dfa const *) _GL_ATTRIBUTE_PURE;
+
 /* Free the storage held by the components of a struct dfa. */
 extern void dfafree (struct dfa *);
 
@@ -99,3 +111,5 @@ extern void dfawarn (const char *);
    takes a single argument, a NUL-terminated string describing the error.
    The user must supply a dfaerror.  */
 extern _Noreturn void dfaerror (const char *);
+
+extern int using_utf8 (void);
index 46581ff..77b4e3e 100644 (file)
 #include <config.h>
 #include "intprops.h"
 #include "search.h"
-#include "dfa.h"
 
-/* For -w, we also consider _ to be word constituent.  */
-#define WCHAR(C) (isalnum (C) || (C) == '_')
+/* Whether -w considers WC to be a word constituent.  */
+static bool
+wordchar (wint_t wc)
+{
+  return wc == L'_' || iswalnum (wc);
+}
 
 /* KWset compiled pattern.  For Ecompile and Gcompile, we compile
    a list of strings, at least one of which is known to occur in
@@ -46,6 +49,13 @@ static struct patterns
 static struct patterns *patterns;
 static size_t pcount;
 
+/* Number of compiled fixed strings known to exactly match the regexp.
+   If kwsexec returns < kwset_exact_matches, then we don't need to
+   call the regexp matcher at all. */
+static size_t kwset_exact_matches;
+
+static bool begline;
+
 void
 dfaerror (char const *mesg)
 {
@@ -69,22 +79,6 @@ dfawarn (char const *mesg)
     dfaerror (mesg);
 }
 
-/* Number of compiled fixed strings known to exactly match the regexp.
-   If kwsexec returns < kwset_exact_matches, then we don't need to
-   call the regexp matcher at all. */
-static size_t kwset_exact_matches;
-
-static char const *
-kwsincr_case (const char *must)
-{
-  size_t n = strlen (must);
-  mb_len_map_t *map = NULL;
-  const char *buf = (match_icase && MB_CUR_MAX > 1
-                     ? mbtolower (must, &n, &map)
-                     : must);
-  return kwsincr (kwset, buf, n);
-}
-
 /* If the DFA turns out to have some set of fixed strings one of
    which must occur in the match, then we build a kwset matcher
    to find those strings, and thus quickly filter out impossible
@@ -92,10 +86,7 @@ kwsincr_case (const char *must)
 static void
 kwsmusts (void)
 {
-  struct dfamust const *dm;
-  char const *err;
-
-  dm = dfamusts (dfa);
+  struct dfamust const *dm = dfamusts (dfa);
   if (dm)
     {
       kwsinit (&kwset);
@@ -107,8 +98,18 @@ kwsmusts (void)
           if (!dm->exact)
             continue;
           ++kwset_exact_matches;
-          if ((err = kwsincr_case (dm->must)) != NULL)
-            error (EXIT_TROUBLE, 0, "%s", err);
+          size_t old_len = strlen (dm->must);
+          size_t new_len = old_len + dm->begline + dm->endline;
+          char *must = xmalloc (new_len);
+          char *mp = must;
+          *mp = eolbyte;
+          mp += dm->begline;
+          begline |= dm->begline;
+          memcpy (mp, dm->must, old_len);
+          if (dm->endline)
+            mp[old_len] = eolbyte;
+          kwsincr (kwset, must, new_len);
+          free (must);
         }
       /* Now, we compile the substrings that will require
          the use of the regexp matcher.  */
@@ -116,19 +117,15 @@ kwsmusts (void)
         {
           if (dm->exact)
             continue;
-          if ((err = kwsincr_case (dm->must)) != NULL)
-            error (EXIT_TROUBLE, 0, "%s", err);
+          kwsincr (kwset, dm->must, strlen (dm->must));
         }
-      if ((err = kwsprep (kwset)) != NULL)
-        error (EXIT_TROUBLE, 0, "%s", err);
+      kwsprep (kwset);
     }
 }
 
 void
 GEAcompile (char const *pattern, size_t size, reg_syntax_t syntax_bits)
 {
-  const char *err;
-  const char *p, *sep;
   size_t total = size;
   char *motif;
 
@@ -137,15 +134,15 @@ GEAcompile (char const *pattern, size_t size, reg_syntax_t syntax_bits)
   re_set_syntax (syntax_bits);
   dfasyntax (syntax_bits, match_icase, eolbyte);
 
-  /* For GNU regex compiler we have to pass the patterns separately to detect
-     errors like "[\nallo\n]\n".  The patterns here are "[", "allo" and "]"
-     GNU regex should have raise a syntax error.  The same for backref, where
-     the backref should have been local to each pattern.  */
-  p = pattern;
+  /* For GNU regex, pass the patterns separately to detect errors like
+     "[\nallo\n]\n", where the patterns are "[", "allo" and "]", and
+     this should be a syntax error.  The same for backref, where the
+     backref should be local to each pattern.  */
+  char const *p = pattern;
   do
     {
       size_t len;
-      sep = memchr (p, '\n', total);
+      char const *sep = memchr (p, '\n', total);
       if (sep)
         {
           len = sep - p;
@@ -161,13 +158,14 @@ GEAcompile (char const *pattern, size_t size, reg_syntax_t syntax_bits)
       patterns = xnrealloc (patterns, pcount + 1, sizeof *patterns);
       patterns[pcount] = patterns0;
 
-      if ((err = re_compile_pattern (p, len,
-                                    &(patterns[pcount].regexbuf))) != NULL)
+      char const *err = re_compile_pattern (p, len,
+                                            &(patterns[pcount].regexbuf));
+      if (err)
         error (EXIT_TROUBLE, 0, "%s", err);
       pcount++;
-
       p = sep;
-    } while (sep && total != 0);
+    }
+  while (p);
 
   /* In the match_words and match_lines cases, we use a different pattern
      for the DFA matcher that will quickly throw out cases that won't work.
@@ -211,128 +209,162 @@ size_t
 EGexecute (char const *buf, size_t size, size_t *match_size,
            char const *start_ptr)
 {
-  char const *buflim, *beg, *end, *match, *best_match, *mb_start;
+  char const *buflim, *beg, *end, *ptr, *match, *best_match, *mb_start;
   char eol = eolbyte;
   int backref;
   regoff_t start;
   size_t len, best_len;
   struct kwsmatch kwsm;
-  size_t i, ret_val;
-  mb_len_map_t *map = NULL;
-
-  if (MB_CUR_MAX > 1)
-    {
-      if (match_icase)
-        {
-          /* mbtolower adds a NUL byte at the end.  That will provide
-             space for the sentinel byte dfaexec may add.  */
-          char *case_buf = mbtolower (buf, &size, &map);
-          if (start_ptr)
-            start_ptr = case_buf + (start_ptr - buf);
-          buf = case_buf;
-        }
-    }
+  size_t i;
+  struct dfa *superset = dfasuperset (dfa);
+  bool dfafast = dfaisfast (dfa);
 
   mb_start = buf;
   buflim = buf + size;
 
   for (beg = end = buf; end < buflim; beg = end)
     {
+      end = buflim;
+
       if (!start_ptr)
         {
-          /* We don't care about an exact match.  */
+          char const *next_beg, *dfa_beg = beg;
+          size_t count = 0;
+          bool exact_kwset_match = false;
+
+          /* Try matching with KWset, if it's defined.  */
           if (kwset)
             {
-              /* Find a possible match using the KWset matcher. */
-              size_t offset = kwsexec (kwset, beg, buflim - beg, &kwsm);
+              char const *prev_beg;
+
+              /* Find a possible match using the KWset matcher.  */
+              size_t offset = kwsexec (kwset, beg - begline,
+                                       buflim - beg + begline, &kwsm);
               if (offset == (size_t) -1)
                 goto failure;
-              beg += offset;
-              /* Narrow down to the line containing the candidate, and
-                 run it through DFA. */
-              if ((end = memchr(beg, eol, buflim - beg)) != NULL)
-                end++;
-              else
-                end = buflim;
-              match = beg;
-              while (beg > buf && beg[-1] != eol)
-                --beg;
-              if (kwsm.index < kwset_exact_matches)
+              match = beg + offset;
+              prev_beg = beg;
+
+              /* Narrow down to the line containing the possible match.  */
+              beg = memrchr (buf, eol, match - buf);
+              beg = beg ? beg + 1 : buf;
+              dfa_beg = beg;
+
+              /* Determine the end pointer to give the DFA next.  Typically
+                 this is after the first newline after MATCH; but if the KWset
+                 match is not exact, the DFA is fast, and the offset from
+                 PREV_BEG is less than 64 or (MATCH - PREV_BEG), this is the
+                 greater of the latter two values; this temporarily prefers
+                 the DFA to KWset.  */
+              exact_kwset_match = kwsm.index < kwset_exact_matches;
+              end = ((exact_kwset_match || !dfafast
+                      || MAX (16, match - beg) < (match - prev_beg) >> 2)
+                     ? match
+                     : MAX (16, match - beg) < (buflim - prev_beg) >> 2
+                     ? prev_beg + 4 * MAX (16, match - beg)
+                     : buflim);
+              end = memchr (end, eol, buflim - end);
+              end = end ? end + 1 : buflim;
+
+              if (exact_kwset_match)
                 {
-                  if (!MBS_SUPPORT)
+                  if (MB_CUR_MAX == 1 || using_utf8 ())
                     goto success;
-
                   if (mb_start < beg)
                     mb_start = beg;
-                  if (MB_CUR_MAX == 1
-                      || !is_mb_middle (&mb_start, match, buflim,
-                                        kwsm.size[0]))
+                  if (mb_goback (&mb_start, match, buflim) == 0)
                     goto success;
+                  /* The matched line starts in the middle of a multibyte
+                     character.  Perform the DFA search starting from the
+                     beginning of the next character.  */
+                  dfa_beg = mb_start;
+                }
+            }
+
+          /* Try matching with the superset of DFA, if it's defined.  */
+          if (superset && !exact_kwset_match)
+            {
+              /* Keep using the superset while it reports multiline
+                 potential matches; this is more likely to be fast
+                 than falling back to KWset would be.  */
+              while ((next_beg = dfaexec (superset, dfa_beg, (char *) end, 1,
+                                          &count, NULL))
+                     && next_beg != end
+                     && count != 0)
+                {
+                  /* Try to match in just one line.  */
+                  count = 0;
+                  beg = memrchr (buf, eol, next_beg - buf);
+                  beg++;
+                  dfa_beg = beg;
                 }
-              if (dfaexec (dfa, beg, (char *) end, 0, NULL, &backref) == NULL)
+              if (next_beg == NULL || next_beg == end)
                 continue;
+
+              /* Narrow down to the line we've found.  */
+              end = memchr (next_beg, eol, buflim - next_beg);
+              end = end ? end + 1 : buflim;
             }
-          else
+
+          /* Try matching with DFA.  */
+          next_beg = dfaexec (dfa, dfa_beg, (char *) end, 0, &count, &backref);
+
+          /* If there's no match, or if we've matched the sentinel,
+             we're done.  */
+          if (next_beg == NULL || next_beg == end)
+            continue;
+
+          /* Narrow down to the line we've found.  */
+          if (count != 0)
             {
-              /* No good fixed strings; start with DFA. */
-              char const *next_beg = dfaexec (dfa, beg, (char *) buflim,
-                                              0, NULL, &backref);
-              /* If there's no match, or if we've matched the sentinel,
-                 we're done.  */
-              if (next_beg == NULL || next_beg == buflim)
-                break;
-              /* Narrow down to the line we've found. */
-              beg = next_beg;
-              if ((end = memchr(beg, eol, buflim - beg)) != NULL)
-                end++;
-              else
-                end = buflim;
-              while (beg > buf && beg[-1] != eol)
-                --beg;
+              beg = memrchr (buf, eol, next_beg - buf);
+              beg++;
             }
+          end = memchr (next_beg, eol, buflim - next_beg);
+          end = end ? end + 1 : buflim;
+
           /* Successful, no backreferences encountered! */
           if (!backref)
             goto success;
+          ptr = beg;
         }
       else
         {
           /* We are looking for the leftmost (then longest) exact match.
              We will go through the outer loop only once.  */
-          beg = start_ptr;
-          end = buflim;
+          ptr = start_ptr;
         }
 
       /* If the "line" is longer than the maximum regexp offset,
          die as if we've run out of memory.  */
-      if (TYPE_MAXIMUM (regoff_t) < end - buf - 1)
+      if (TYPE_MAXIMUM (regoff_t) < end - beg - 1)
         xalloc_die ();
 
-      /* If we've made it to this point, this means DFA has seen
-         a probable match, and we need to run it through Regex. */
+      /* Run the possible match through Regex.  */
       best_match = end;
       best_len = 0;
       for (i = 0; i < pcount; i++)
         {
           patterns[i].regexbuf.not_eol = 0;
           start = re_search (&(patterns[i].regexbuf),
-                             buf, end - buf - 1,
-                             beg - buf, end - beg - 1,
+                             beg, end - beg - 1,
+                             ptr - beg, end - ptr - 1,
                              &(patterns[i].regs));
           if (start < -1)
             xalloc_die ();
           else if (0 <= start)
             {
               len = patterns[i].regs.end[0] - start;
-              match = buf + start;
+              match = beg + start;
               if (match > best_match)
                 continue;
               if (start_ptr && !match_words)
                 goto assess_pattern_match;
               if ((!match_lines && !match_words)
-                  || (match_lines && len == end - beg - 1))
+                  || (match_lines && len == end - ptr - 1))
                 {
-                  match = beg;
-                  len = end - beg;
+                  match = ptr;
+                  len = end - ptr;
                   goto assess_pattern_match;
                 }
               /* If -w, check if the match aligns with word boundaries.
@@ -346,9 +378,8 @@ EGexecute (char const *buf, size_t size, size_t *match_size,
                 while (match <= best_match)
                   {
                     regoff_t shorter_len = 0;
-                    if ((match == buf || !WCHAR ((unsigned char) match[-1]))
-                        && (start + len == end - buf - 1
-                            || !WCHAR ((unsigned char) match[len])))
+                    if (!wordchar (mb_prev_wc (beg, match, end - 1))
+                        && !wordchar (mb_next_wc (match + len, end - 1)))
                       goto assess_pattern_match;
                     if (len > 0)
                       {
@@ -356,8 +387,8 @@ EGexecute (char const *buf, size_t size, size_t *match_size,
                         --len;
                         patterns[i].regexbuf.not_eol = 1;
                         shorter_len = re_match (&(patterns[i].regexbuf),
-                                                buf, match + len - beg,
-                                                match - buf,
+                                                beg, match + len - ptr,
+                                                match - beg,
                                                 &(patterns[i].regs));
                         if (shorter_len < -1)
                           xalloc_die ();
@@ -372,8 +403,8 @@ EGexecute (char const *buf, size_t size, size_t *match_size,
                         match++;
                         patterns[i].regexbuf.not_eol = 0;
                         start = re_search (&(patterns[i].regexbuf),
-                                           buf, end - buf - 1,
-                                           match - buf, end - match - 1,
+                                           beg, end - beg - 1,
+                                           match - beg, end - match - 1,
                                            &(patterns[i].regs));
                         if (start < 0)
                           {
@@ -382,7 +413,7 @@ EGexecute (char const *buf, size_t size, size_t *match_size,
                             break;
                           }
                         len = patterns[i].regs.end[0] - start;
-                        match = buf + start;
+                        match = beg + start;
                       }
                   } /* while (match <= best_match) */
               continue;
@@ -418,8 +449,6 @@ EGexecute (char const *buf, size_t size, size_t *match_size,
   len = end - beg;
  success_in_len:;
   size_t off = beg - buf;
-  mb_case_map_apply (map, &off, &len);
   *match_size = len;
-  ret_val = off;
-  return ret_val;
+  return off;
 }
index d7db81d..9ac2d13 100644 (file)
@@ -49,8 +49,24 @@ static int       dos_pos_map_size  = 0;
 static int       dos_pos_map_used  = 0;
 static int       inp_map_idx = 0, out_map_idx = 1;
 
+/* Set default DOS file type to binary.  */
+static void
+dos_binary (void)
+{
+  if (O_BINARY)
+    dos_use_file_type = DOS_BINARY;
+}
+
+/* Tell DOS routines to report Unix offset.  */
+static void
+dos_unix_byte_offsets (void)
+{
+  if (O_BINARY)
+    dos_report_unix_offset = 1;
+}
+
 /* Guess DOS file type by looking at its contents.  */
-static inline File_type
+static File_type
 guess_type (char *buf, size_t buflen)
 {
   int crlf_seen = 0;
@@ -76,9 +92,12 @@ guess_type (char *buf, size_t buflen)
 /* Convert external DOS file representation to internal.
    Return the count of characters left in the buffer.
    Build table to map character positions when reporting byte counts.  */
-static inline int
+static int
 undossify_input (char *buf, size_t buflen)
 {
+  if (! O_BINARY)
+    return buflen;
+
   int chars_left = 0;
 
   if (totalcc == 0)
@@ -164,9 +183,12 @@ undossify_input (char *buf, size_t buflen)
 }
 
 /* Convert internal byte count into external.  */
-static inline off_t
+static off_t
 dossified_pos (off_t byteno)
 {
+  if (! O_BINARY)
+    return byteno;
+
   off_t pos_lo;
   off_t pos_hi;
 
diff --git a/src/egrep.c b/src/egrep.c
deleted file mode 100644 (file)
index 7dfff09..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-#include <config.h>
-#include "search.h"
-
-static void
-Ecompile (char const *pattern, size_t size)
-{
-  GEAcompile (pattern, size, RE_SYNTAX_POSIX_EGREP | RE_NO_EMPTY_RANGES);
-}
-
-struct matcher const matchers[] = {
-  { "egrep", Ecompile, EGexecute },
-  { NULL, NULL, NULL },
-};
-
-const char before_options[] =
-N_("PATTERN is an extended regular expression (ERE).\n");
-const char after_options[] =
-N_("Invocation as 'egrep' is deprecated; use 'grep -E' instead.\n");
diff --git a/src/egrep.sh b/src/egrep.sh
new file mode 100644 (file)
index 0000000..1a03d2a
--- /dev/null
@@ -0,0 +1,11 @@
+#!@SHELL@
+grep=grep
+case $0 in
+  */*)
+    dir=${0%/*}
+    if test -x "$dir/@grep@"; then
+      PATH=$dir:$PATH
+      grep=@grep@
+    fi;;
+esac
+exec $grep @option@ "$@"
diff --git a/src/fgrep.c b/src/fgrep.c
deleted file mode 100644 (file)
index a0940cc..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-#include <config.h>
-#include "search.h"
-
-struct matcher const matchers[] = {
-  { "fgrep", Fcompile, Fexecute },
-  { NULL, NULL, NULL },
-};
-
-const char before_options[] =
-N_("PATTERN is a set of newline-separated fixed strings.\n");
-const char after_options[] =
-N_("Invocation as 'fgrep' is deprecated; use 'grep -F' instead.\n");
index 1b2198f..ec955d8 100644 (file)
+/* grep.c - main driver file for grep.
+   Copyright (C) 1992, 1997-2002, 2004-2014 Free Software Foundation, Inc.
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 3, or (at your option)
+   any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program; if not, write to the Free Software
+   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
+   02110-1301, USA.  */
+
+/* Written July 1992 by Mike Haertel.  */
+
 #include <config.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <wchar.h>
+#include <wctype.h>
+#include <fcntl.h>
+#include <inttypes.h>
+#include <stdio.h>
+#include "system.h"
+
+#include "argmatch.h"
+#include "c-ctype.h"
+#include "closeout.h"
+#include "colorize.h"
+#include "error.h"
+#include "exclude.h"
+#include "exitfail.h"
+#include "fcntl-safer.h"
+#include "fts_.h"
+#include "getopt.h"
+#include "grep.h"
+#include "intprops.h"
+#include "progname.h"
+#include "propername.h"
+#include "quote.h"
+#include "safe-read.h"
 #include "search.h"
+#include "version-etc.h"
+#include "xalloc.h"
+#include "xstrtol.h"
+
+#define SEP_CHAR_SELECTED ':'
+#define SEP_CHAR_REJECTED '-'
+#define SEP_STR_GROUP    "--"
+
+#define AUTHORS \
+  proper_name ("Mike Haertel"), \
+  _("others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>")
+
+/* When stdout is connected to a regular file, save its stat
+   information here, so that we can automatically skip it, thus
+   avoiding a potential (racy) infinite loop.  */
+static struct stat out_stat;
+
+/* if non-zero, display usage information and exit */
+static int show_help;
+
+/* If non-zero, print the version on standard output and exit.  */
+static int show_version;
+
+/* If nonzero, suppress diagnostics for nonexistent or unreadable files.  */
+static int suppress_errors;
+
+/* If nonzero, use color markers.  */
+static int color_option;
+
+/* If nonzero, show only the part of a line matching the expression. */
+static int only_matching;
+
+/* If nonzero, make sure first content char in a line is on a tab stop. */
+static int align_tabs;
+
+/* The group separator used when context is requested. */
+static const char *group_separator = SEP_STR_GROUP;
+
+/* The context and logic for choosing default --color screen attributes
+   (foreground and background colors, etc.) are the following.
+      -- There are eight basic colors available, each with its own
+         nominal luminosity to the human eye and foreground/background
+         codes (black [0 %, 30/40], blue [11 %, 34/44], red [30 %, 31/41],
+         magenta [41 %, 35/45], green [59 %, 32/42], cyan [70 %, 36/46],
+         yellow [89 %, 33/43], and white [100 %, 37/47]).
+      -- Sometimes, white as a background is actually implemented using
+         a shade of light gray, so that a foreground white can be visible
+         on top of it (but most often not).
+      -- Sometimes, black as a foreground is actually implemented using
+         a shade of dark gray, so that it can be visible on top of a
+         background black (but most often not).
+      -- Sometimes, more colors are available, as extensions.
+      -- Other attributes can be selected/deselected (bold [1/22],
+         underline [4/24], standout/inverse [7/27], blink [5/25], and
+         invisible/hidden [8/28]).  They are sometimes implemented by
+         using colors instead of what their names imply; e.g., bold is
+         often achieved by using brighter colors.  In practice, only bold
+         is really available to us, underline sometimes being mapped by
+         the terminal to some strange color choice, and standout best
+         being left for use by downstream programs such as less(1).
+      -- We cannot assume that any of the extensions or special features
+         are available for the purpose of choosing defaults for everyone.
+      -- The most prevalent default terminal backgrounds are pure black
+         and pure white, and are not necessarily the same shades of
+         those as if they were selected explicitly with SGR sequences.
+         Some terminals use dark or light pictures as default background,
+         but those are covered over by an explicit selection of background
+         color with an SGR sequence; their users will appreciate their
+         background pictures not be covered like this, if possible.
+      -- Some uses of colors attributes is to make some output items
+         more understated (e.g., context lines); this cannot be achieved
+         by changing the background color.
+      -- For these reasons, the grep color defaults should strive not
+         to change the background color from its default, unless it's
+         for a short item that should be highlighted, not understated.
+      -- The grep foreground color defaults (without an explicitly set
+         background) should provide enough contrast to be readable on any
+         terminal with either a black (dark) or white (light) background.
+         This only leaves red, magenta, green, and cyan (and their bold
+         counterparts) and possibly bold blue.  */
+/* The color strings used for matched text.
+   The user can overwrite them using the deprecated
+   environment variable GREP_COLOR or the new GREP_COLORS.  */
+static const char *selected_match_color = "01;31";     /* bold red */
+static const char *context_match_color  = "01;31";     /* bold red */
+
+/* Other colors.  Defaults look damn good.  */
+static const char *filename_color = "35";      /* magenta */
+static const char *line_num_color = "32";      /* green */
+static const char *byte_num_color = "32";      /* green */
+static const char *sep_color      = "36";      /* cyan */
+static const char *selected_line_color = "";   /* default color pair */
+static const char *context_line_color  = "";   /* default color pair */
+
+/* Select Graphic Rendition (SGR, "\33[...m") strings.  */
+/* Also Erase in Line (EL) to Right ("\33[K") by default.  */
+/*    Why have EL to Right after SGR?
+         -- The behavior of line-wrapping when at the bottom of the
+            terminal screen and at the end of the current line is often
+            such that a new line is introduced, entirely cleared with
+            the current background color which may be different from the
+            default one (see the boolean back_color_erase terminfo(5)
+            capability), thus scrolling the display by one line.
+            The end of this new line will stay in this background color
+            even after reverting to the default background color with
+            "\33[m', unless it is explicitly cleared again with "\33[K"
+            (which is the behavior the user would instinctively expect
+            from the whole thing).  There may be some unavoidable
+            background-color flicker at the end of this new line because
+            of this (when timing with the monitor's redraw is just right).
+         -- The behavior of HT (tab, "\t") is usually the same as that of
+            Cursor Forward Tabulation (CHT) with a default parameter
+            of 1 ("\33[I"), i.e., it performs pure movement to the next
+            tab stop, without any clearing of either content or screen
+            attributes (including background color); try
+               printf 'asdfqwerzxcv\rASDF\tZXCV\n'
+            in a bash(1) shell to demonstrate this.  This is not what the
+            user would instinctively expect of HT (but is ok for CHT).
+            The instinctive behavior would include clearing the terminal
+            cells that are skipped over by HT with blank cells in the
+            current screen attributes, including background color;
+            the boolean dest_tabs_magic_smso terminfo(5) capability
+            indicates this saner behavior for HT, but only some rare
+            terminals have it (although it also indicates a special
+            glitch with standout mode in the Teleray terminal for which
+            it was initially introduced).  The remedy is to add "\33K"
+            after each SGR sequence, be it START (to fix the behavior
+            of any HT after that before another SGR) or END (to fix the
+            behavior of an HT in default background color that would
+            follow a line-wrapping at the bottom of the screen in another
+            background color, and to complement doing it after START).
+            Piping grep's output through a pager such as less(1) avoids
+            any HT problems since the pager performs tab expansion.
+
+      Generic disadvantages of this remedy are:
+         -- Some very rare terminals might support SGR but not EL (nobody
+            will use "grep --color" on a terminal that does not support
+            SGR in the first place).
+         -- Having these extra control sequences might somewhat complicate
+            the task of any program trying to parse "grep --color"
+            output in order to extract structuring information from it.
+      A specific disadvantage to doing it after SGR START is:
+         -- Even more possible background color flicker (when timing
+            with the monitor's redraw is just right), even when not at the
+            bottom of the screen.
+      There are no additional disadvantages specific to doing it after
+      SGR END.
+
+      It would be impractical for GNU grep to become a full-fledged
+      terminal program linked against ncurses or the like, so it will
+      not detect terminfo(5) capabilities.  */
+static const char *sgr_start = "\33[%sm\33[K";
+static const char *sgr_end   = "\33[m\33[K";
+
+/* SGR utility functions.  */
+static void
+pr_sgr_start (char const *s)
+{
+  if (*s)
+    print_start_colorize (sgr_start, s);
+}
+static void
+pr_sgr_end (char const *s)
+{
+  if (*s)
+    print_end_colorize (sgr_end);
+}
+static void
+pr_sgr_start_if (char const *s)
+{
+  if (color_option)
+    pr_sgr_start (s);
+}
+static void
+pr_sgr_end_if (char const *s)
+{
+  if (color_option)
+    pr_sgr_end (s);
+}
+
+struct color_cap
+  {
+    const char *name;
+    const char **var;
+    void (*fct) (void);
+  };
+
+static void
+color_cap_mt_fct (void)
+{
+  /* Our caller just set selected_match_color.  */
+  context_match_color = selected_match_color;
+}
+
+static void
+color_cap_rv_fct (void)
+{
+  /* By this point, it was 1 (or already -1).  */
+  color_option = -1;  /* That's still != 0.  */
+}
+
+static void
+color_cap_ne_fct (void)
+{
+  sgr_start = "\33[%sm";
+  sgr_end   = "\33[m";
+}
+
+/* For GREP_COLORS.  */
+static const struct color_cap color_dict[] =
+  {
+    { "mt", &selected_match_color, color_cap_mt_fct }, /* both ms/mc */
+    { "ms", &selected_match_color, NULL }, /* selected matched text */
+    { "mc", &context_match_color,  NULL }, /* context matched text */
+    { "fn", &filename_color,       NULL }, /* filename */
+    { "ln", &line_num_color,       NULL }, /* line number */
+    { "bn", &byte_num_color,       NULL }, /* byte (sic) offset */
+    { "se", &sep_color,            NULL }, /* separator */
+    { "sl", &selected_line_color,  NULL }, /* selected lines */
+    { "cx", &context_line_color,   NULL }, /* context lines */
+    { "rv", NULL,                  color_cap_rv_fct }, /* -v reverses sl/cx */
+    { "ne", NULL,                  color_cap_ne_fct }, /* no EL on SGR_* */
+    { NULL, NULL,                  NULL }
+  };
+
+static struct exclude *excluded_patterns;
+static struct exclude *excluded_directory_patterns;
+/* Short options.  */
+static char const short_options[] =
+"0123456789A:B:C:D:EFGHIPTUVX:abcd:e:f:hiLlm:noqRrsuvwxyZz";
+
+/* Non-boolean long options that have no corresponding short equivalents.  */
+enum
+{
+  BINARY_FILES_OPTION = CHAR_MAX + 1,
+  COLOR_OPTION,
+  INCLUDE_OPTION,
+  EXCLUDE_OPTION,
+  EXCLUDE_FROM_OPTION,
+  LINE_BUFFERED_OPTION,
+  LABEL_OPTION,
+  EXCLUDE_DIRECTORY_OPTION,
+  GROUP_SEPARATOR_OPTION
+};
+
+/* Long options equivalences. */
+static struct option const long_options[] =
+{
+  {"basic-regexp",    no_argument, NULL, 'G'},
+  {"extended-regexp", no_argument, NULL, 'E'},
+  {"fixed-regexp",    no_argument, NULL, 'F'},
+  {"fixed-strings",   no_argument, NULL, 'F'},
+  {"perl-regexp",     no_argument, NULL, 'P'},
+  {"after-context", required_argument, NULL, 'A'},
+  {"before-context", required_argument, NULL, 'B'},
+  {"binary-files", required_argument, NULL, BINARY_FILES_OPTION},
+  {"byte-offset", no_argument, NULL, 'b'},
+  {"context", required_argument, NULL, 'C'},
+  {"color", optional_argument, NULL, COLOR_OPTION},
+  {"colour", optional_argument, NULL, COLOR_OPTION},
+  {"count", no_argument, NULL, 'c'},
+  {"devices", required_argument, NULL, 'D'},
+  {"directories", required_argument, NULL, 'd'},
+  {"exclude", required_argument, NULL, EXCLUDE_OPTION},
+  {"exclude-from", required_argument, NULL, EXCLUDE_FROM_OPTION},
+  {"exclude-dir", required_argument, NULL, EXCLUDE_DIRECTORY_OPTION},
+  {"file", required_argument, NULL, 'f'},
+  {"files-with-matches", no_argument, NULL, 'l'},
+  {"files-without-match", no_argument, NULL, 'L'},
+  {"group-separator", required_argument, NULL, GROUP_SEPARATOR_OPTION},
+  {"help", no_argument, &show_help, 1},
+  {"include", required_argument, NULL, INCLUDE_OPTION},
+  {"ignore-case", no_argument, NULL, 'i'},
+  {"initial-tab", no_argument, NULL, 'T'},
+  {"label", required_argument, NULL, LABEL_OPTION},
+  {"line-buffered", no_argument, NULL, LINE_BUFFERED_OPTION},
+  {"line-number", no_argument, NULL, 'n'},
+  {"line-regexp", no_argument, NULL, 'x'},
+  {"max-count", required_argument, NULL, 'm'},
+
+  {"no-filename", no_argument, NULL, 'h'},
+  {"no-group-separator", no_argument, NULL, GROUP_SEPARATOR_OPTION},
+  {"no-messages", no_argument, NULL, 's'},
+  {"null", no_argument, NULL, 'Z'},
+  {"null-data", no_argument, NULL, 'z'},
+  {"only-matching", no_argument, NULL, 'o'},
+  {"quiet", no_argument, NULL, 'q'},
+  {"recursive", no_argument, NULL, 'r'},
+  {"dereference-recursive", no_argument, NULL, 'R'},
+  {"regexp", required_argument, NULL, 'e'},
+  {"invert-match", no_argument, NULL, 'v'},
+  {"silent", no_argument, NULL, 'q'},
+  {"text", no_argument, NULL, 'a'},
+  {"binary", no_argument, NULL, 'U'},
+  {"unix-byte-offsets", no_argument, NULL, 'u'},
+  {"version", no_argument, NULL, 'V'},
+  {"with-filename", no_argument, NULL, 'H'},
+  {"word-regexp", no_argument, NULL, 'w'},
+  {0, 0, 0, 0}
+};
+
+/* Define flags declared in grep.h. */
+int match_icase;
+int match_words;
+int match_lines;
+unsigned char eolbyte;
+
+static char const *matcher;
+
+/* For error messages. */
+/* The input file name, or (if standard input) "-" or a --label argument.  */
+static char const *filename;
+static size_t filename_prefix_len;
+static int errseen;
+static int write_error_seen;
+
+enum directories_type
+  {
+    READ_DIRECTORIES = 2,
+    RECURSE_DIRECTORIES,
+    SKIP_DIRECTORIES
+  };
+
+/* How to handle directories.  */
+static char const *const directories_args[] =
+{
+  "read", "recurse", "skip", NULL
+};
+static enum directories_type const directories_types[] =
+{
+  READ_DIRECTORIES, RECURSE_DIRECTORIES, SKIP_DIRECTORIES
+};
+ARGMATCH_VERIFY (directories_args, directories_types);
+
+static enum directories_type directories = READ_DIRECTORIES;
+
+enum { basic_fts_options = FTS_CWDFD | FTS_NOSTAT | FTS_TIGHT_CYCLE_CHECK };
+static int fts_options = basic_fts_options | FTS_COMFOLLOW | FTS_PHYSICAL;
+
+/* How to handle devices. */
+static enum
+  {
+    READ_COMMAND_LINE_DEVICES,
+    READ_DEVICES,
+    SKIP_DEVICES
+  } devices = READ_COMMAND_LINE_DEVICES;
+
+static int grepfile (int, char const *, int, int);
+static int grepdesc (int, int);
+
+static void dos_binary (void);
+static void dos_unix_byte_offsets (void);
+static int undossify_input (char *, size_t);
+
+static int
+is_device_mode (mode_t m)
+{
+  return S_ISCHR (m) || S_ISBLK (m) || S_ISSOCK (m) || S_ISFIFO (m);
+}
+
+/* Return nonzero if ST->st_size is defined.  Assume the file is not a
+   symbolic link.  */
+static int
+usable_st_size (struct stat const *st)
+{
+  return S_ISREG (st->st_mode) || S_TYPEISSHM (st) || S_TYPEISTMO (st);
+}
+
+/* Functions we'll use to search. */
+typedef void (*compile_fp_t) (char const *, size_t);
+typedef size_t (*execute_fp_t) (char const *, size_t, size_t *, char const *);
+static compile_fp_t compile;
+static execute_fp_t execute;
+
+/* Like error, but suppress the diagnostic if requested.  */
+static void
+suppressible_error (char const *mesg, int errnum)
+{
+  if (! suppress_errors)
+    error (0, errnum, "%s", mesg);
+  errseen = 1;
+}
+
+/* If there has already been a write error, don't bother closing
+   standard output, as that might elicit a duplicate diagnostic.  */
+static void
+clean_up_stdout (void)
+{
+  if (! write_error_seen)
+    close_stdout ();
+}
+
+/* Return 1 if a file is known to be binary for the purpose of 'grep'.
+   BUF, of size BUFSIZE, is the initial buffer read from the file with
+   descriptor FD and status ST.  */
+static int
+file_is_binary (char const *buf, size_t bufsize, int fd, struct stat const *st)
+{
+  #ifndef SEEK_HOLE
+  enum { SEEK_HOLE = SEEK_END };
+  #endif
+
+  /* If -z, test only whether the initial buffer contains '\200';
+     knowing about holes won't help.  */
+  if (! eolbyte)
+    return memchr (buf, '\200', bufsize) != 0;
+
+  /* If the initial buffer contains a null byte, guess that the file
+     is binary.  */
+  if (memchr (buf, '\0', bufsize))
+    return 1;
+
+  /* If the file has holes, it must contain a null byte somewhere.  */
+  if (SEEK_HOLE != SEEK_END && usable_st_size (st))
+    {
+      off_t cur = bufsize;
+      if (O_BINARY || fd == STDIN_FILENO)
+        {
+          cur = lseek (fd, 0, SEEK_CUR);
+          if (cur < 0)
+            return 0;
+        }
+
+      /* Look for a hole after the current location.  */
+      off_t hole_start = lseek (fd, cur, SEEK_HOLE);
+      if (0 <= hole_start)
+        {
+          if (lseek (fd, cur, SEEK_SET) < 0)
+            suppressible_error (filename, errno);
+          if (hole_start < st->st_size)
+            return 1;
+        }
+    }
+
+  /* Guess that the file does not contain binary data.  */
+  return 0;
+}
+
+/* Convert STR to a nonnegative integer, storing the result in *OUT.
+   STR must be a valid context length argument; report an error if it
+   isn't.  Silently ceiling *OUT at the maximum value, as that is
+   practically equivalent to infinity for grep's purposes.  */
+static void
+context_length_arg (char const *str, intmax_t *out)
+{
+  switch (xstrtoimax (str, 0, 10, out, ""))
+    {
+    case LONGINT_OK:
+    case LONGINT_OVERFLOW:
+      if (0 <= *out)
+        break;
+      /* Fall through.  */
+    default:
+      error (EXIT_TROUBLE, 0, "%s: %s", str,
+             _("invalid context length argument"));
+    }
+}
+
+/* Return nonzero if the file with NAME should be skipped.
+   If COMMAND_LINE is nonzero, it is a command-line argument.
+   If IS_DIR is nonzero, it is a directory.  */
+static int
+skipped_file (char const *name, int command_line, int is_dir)
+{
+  return (is_dir
+          ? (directories == SKIP_DIRECTORIES
+             || (! (command_line && filename_prefix_len != 0)
+                 && excluded_directory_patterns
+                 && excluded_file_name (excluded_directory_patterns, name)))
+          : (excluded_patterns
+             && excluded_file_name (excluded_patterns, name)));
+}
+
+/* Hairy buffering mechanism for grep.  The intent is to keep
+   all reads aligned on a page boundary and multiples of the
+   page size, unless a read yields a partial page.  */
+
+static char *buffer;           /* Base of buffer. */
+static size_t bufalloc;                /* Allocated buffer size, counting slop. */
+#define INITIAL_BUFSIZE 32768  /* Initial buffer size, not counting slop. */
+static int bufdesc;            /* File descriptor. */
+static char *bufbeg;           /* Beginning of user-visible stuff. */
+static char *buflim;           /* Limit of user-visible stuff. */
+static size_t pagesize;                /* alignment of memory pages */
+static off_t bufoffset;                /* Read offset; defined on regular files.  */
+static off_t after_last_match; /* Pointer after last matching line that
+                                   would have been output if we were
+                                   outputting characters. */
+
+/* Return VAL aligned to the next multiple of ALIGNMENT.  VAL can be
+   an integer or a pointer.  Both args must be free of side effects.  */
+#define ALIGN_TO(val, alignment) \
+  ((size_t) (val) % (alignment) == 0 \
+   ? (val) \
+   : (val) + ((alignment) - (size_t) (val) % (alignment)))
+
+/* Reset the buffer for a new file, returning zero if we should skip it.
+   Initialize on the first time through. */
+static int
+reset (int fd, struct stat const *st)
+{
+  if (! pagesize)
+    {
+      pagesize = getpagesize ();
+      if (pagesize == 0 || 2 * pagesize + 1 <= pagesize)
+        abort ();
+      bufalloc = ALIGN_TO (INITIAL_BUFSIZE, pagesize) + pagesize + 1;
+      buffer = xmalloc (bufalloc);
+    }
+
+  bufbeg = buflim = ALIGN_TO (buffer + 1, pagesize);
+  bufbeg[-1] = eolbyte;
+  bufdesc = fd;
+
+  if (S_ISREG (st->st_mode))
+    {
+      if (fd != STDIN_FILENO)
+        bufoffset = 0;
+      else
+        {
+          bufoffset = lseek (fd, 0, SEEK_CUR);
+          if (bufoffset < 0)
+            {
+              suppressible_error (_("lseek failed"), errno);
+              return 0;
+            }
+        }
+    }
+  return 1;
+}
+
+/* Read new stuff into the buffer, saving the specified
+   amount of old stuff.  When we're done, 'bufbeg' points
+   to the beginning of the buffer contents, and 'buflim'
+   points just after the end.  Return zero if there's an error.  */
+static int
+fillbuf (size_t save, struct stat const *st)
+{
+  ssize_t fillsize;
+  int cc = 1;
+  char *readbuf;
+  size_t readsize;
+
+  /* Offset from start of buffer to start of old stuff
+     that we want to save.  */
+  size_t saved_offset = buflim - save - buffer;
+
+  if (pagesize <= buffer + bufalloc - buflim)
+    {
+      readbuf = buflim;
+      bufbeg = buflim - save;
+    }
+  else
+    {
+      size_t minsize = save + pagesize;
+      size_t newsize;
+      size_t newalloc;
+      char *newbuf;
+
+      /* Grow newsize until it is at least as great as minsize.  */
+      for (newsize = bufalloc - pagesize - 1; newsize < minsize; newsize *= 2)
+        if (newsize * 2 < newsize || newsize * 2 + pagesize + 1 < newsize * 2)
+          xalloc_die ();
+
+      /* Try not to allocate more memory than the file size indicates,
+         as that might cause unnecessary memory exhaustion if the file
+         is large.  However, do not use the original file size as a
+         heuristic if we've already read past the file end, as most
+         likely the file is growing.  */
+      if (usable_st_size (st))
+        {
+          off_t to_be_read = st->st_size - bufoffset;
+          off_t maxsize_off = save + to_be_read;
+          if (0 <= to_be_read && to_be_read <= maxsize_off
+              && maxsize_off == (size_t) maxsize_off
+              && minsize <= (size_t) maxsize_off
+              && (size_t) maxsize_off < newsize)
+            newsize = maxsize_off;
+        }
+
+      /* Add enough room so that the buffer is aligned and has room
+         for byte sentinels fore and aft.  */
+      newalloc = newsize + pagesize + 1;
+
+      newbuf = bufalloc < newalloc ? xmalloc (bufalloc = newalloc) : buffer;
+      readbuf = ALIGN_TO (newbuf + 1 + save, pagesize);
+      bufbeg = readbuf - save;
+      memmove (bufbeg, buffer + saved_offset, save);
+      bufbeg[-1] = eolbyte;
+      if (newbuf != buffer)
+        {
+          free (buffer);
+          buffer = newbuf;
+        }
+    }
+
+  readsize = buffer + bufalloc - readbuf;
+  readsize -= readsize % pagesize;
+
+  fillsize = safe_read (bufdesc, readbuf, readsize);
+  if (fillsize < 0)
+    fillsize = cc = 0;
+  bufoffset += fillsize;
+  fillsize = undossify_input (readbuf, fillsize);
+  buflim = readbuf + fillsize;
+  return cc;
+}
+
+/* Flags controlling the style of output. */
+static enum
+{
+  BINARY_BINARY_FILES,
+  TEXT_BINARY_FILES,
+  WITHOUT_MATCH_BINARY_FILES
+} binary_files;                /* How to handle binary files.  */
+
+static int filename_mask;      /* If zero, output nulls after filenames.  */
+static int out_quiet;          /* Suppress all normal output. */
+static bool out_invert;                /* Print nonmatching stuff. */
+static int out_file;           /* Print filenames. */
+static int out_line;           /* Print line numbers. */
+static int out_byte;           /* Print byte offsets. */
+static intmax_t out_before;    /* Lines of leading context. */
+static intmax_t out_after;     /* Lines of trailing context. */
+static int count_matches;      /* Count matching lines.  */
+static int list_files;         /* List matching files.  */
+static int no_filenames;       /* Suppress file names.  */
+static intmax_t max_count;     /* Stop after outputting this many
+                                   lines from an input file.  */
+static int line_buffered;       /* If nonzero, use line buffering, i.e.
+                                   fflush everyline out.  */
+static char *label = NULL;      /* Fake filename for stdin */
+
+
+/* Internal variables to keep track of byte count, context, etc. */
+static uintmax_t totalcc;      /* Total character count before bufbeg. */
+static char const *lastnl;     /* Pointer after last newline counted. */
+static char const *lastout;    /* Pointer after last character output;
+                                   NULL if no character has been output
+                                   or if it's conceptually before bufbeg. */
+static uintmax_t totalnl;      /* Total newline count before lastnl. */
+static intmax_t outleft;       /* Maximum number of lines to be output.  */
+static intmax_t pending;       /* Pending lines of output.
+                                   Always kept 0 if out_quiet is true.  */
+static int done_on_match;      /* Stop scanning file on first match.  */
+static int exit_on_match;      /* Exit on first match.  */
+
+#include "dosbuf.c"
+
+/* Add two numbers that count input bytes or lines, and report an
+   error if the addition overflows.  */
+static uintmax_t
+add_count (uintmax_t a, uintmax_t b)
+{
+  uintmax_t sum = a + b;
+  if (sum < a)
+    error (EXIT_TROUBLE, 0, _("input is too large to count"));
+  return sum;
+}
+
+static void
+nlscan (char const *lim)
+{
+  size_t newlines = 0;
+  char const *beg;
+  for (beg = lastnl; beg < lim; beg++)
+    {
+      beg = memchr (beg, eolbyte, lim - beg);
+      if (!beg)
+        break;
+      newlines++;
+    }
+  totalnl = add_count (totalnl, newlines);
+  lastnl = lim;
+}
+
+/* Print the current filename.  */
+static void
+print_filename (void)
+{
+  pr_sgr_start_if (filename_color);
+  fputs (filename, stdout);
+  pr_sgr_end_if (filename_color);
+}
+
+/* Print a character separator.  */
+static void
+print_sep (char sep)
+{
+  pr_sgr_start_if (sep_color);
+  fputc (sep, stdout);
+  pr_sgr_end_if (sep_color);
+}
+
+/* Print a line number or a byte offset.  */
+static void
+print_offset (uintmax_t pos, int min_width, const char *color)
+{
+  /* Do not rely on printf to print pos, since uintmax_t may be longer
+     than long, and long long is not portable.  */
+
+  char buf[sizeof pos * CHAR_BIT];
+  char *p = buf + sizeof buf;
+
+  do
+    {
+      *--p = '0' + pos % 10;
+      --min_width;
+    }
+  while ((pos /= 10) != 0);
+
+  /* Do this to maximize the probability of alignment across lines.  */
+  if (align_tabs)
+    while (--min_width >= 0)
+      *--p = ' ';
+
+  pr_sgr_start_if (color);
+  fwrite (p, 1, buf + sizeof buf - p, stdout);
+  pr_sgr_end_if (color);
+}
+
+/* Print a whole line head (filename, line, byte).  */
+static void
+print_line_head (char const *beg, char const *lim, int sep)
+{
+  int pending_sep = 0;
+
+  if (out_file)
+    {
+      print_filename ();
+      if (filename_mask)
+        pending_sep = 1;
+      else
+        fputc (0, stdout);
+    }
+
+  if (out_line)
+    {
+      if (lastnl < lim)
+        {
+          nlscan (beg);
+          totalnl = add_count (totalnl, 1);
+          lastnl = lim;
+        }
+      if (pending_sep)
+        print_sep (sep);
+      print_offset (totalnl, 4, line_num_color);
+      pending_sep = 1;
+    }
+
+  if (out_byte)
+    {
+      uintmax_t pos = add_count (totalcc, beg - bufbeg);
+      pos = dossified_pos (pos);
+      if (pending_sep)
+        print_sep (sep);
+      print_offset (pos, 6, byte_num_color);
+      pending_sep = 1;
+    }
+
+  if (pending_sep)
+    {
+      /* This assumes sep is one column wide.
+         Try doing this any other way with Unicode
+         (and its combining and wide characters)
+         filenames and you're wasting your efforts.  */
+      if (align_tabs)
+        fputs ("\t\b", stdout);
+
+      print_sep (sep);
+    }
+}
+
+static const char *
+print_line_middle (const char *beg, const char *lim,
+                   const char *line_color, const char *match_color)
+{
+  size_t match_size;
+  size_t match_offset;
+  const char *cur = beg;
+  const char *mid = NULL;
+
+  while (cur < lim
+         && ((match_offset = execute (beg, lim - beg, &match_size,
+                                      beg + (cur - beg))) != (size_t) -1))
+    {
+      char const *b = beg + match_offset;
+
+      /* Avoid matching the empty line at the end of the buffer. */
+      if (b == lim)
+        break;
+
+      /* Avoid hanging on grep --color "" foo */
+      if (match_size == 0)
+        {
+          /* Make minimal progress; there may be further non-empty matches.  */
+          /* XXX - Could really advance by one whole multi-octet character.  */
+          match_size = 1;
+          if (!mid)
+            mid = cur;
+        }
+      else
+        {
+          /* This function is called on a matching line only,
+             but is it selected or rejected/context?  */
+          if (only_matching)
+            print_line_head (b, lim, (out_invert ? SEP_CHAR_REJECTED
+                                      : SEP_CHAR_SELECTED));
+          else
+            {
+              pr_sgr_start (line_color);
+              if (mid)
+                {
+                  cur = mid;
+                  mid = NULL;
+                }
+              fwrite (cur, sizeof (char), b - cur, stdout);
+            }
+
+          pr_sgr_start_if (match_color);
+          fwrite (b, sizeof (char), match_size, stdout);
+          pr_sgr_end_if (match_color);
+          if (only_matching)
+            fputs ("\n", stdout);
+        }
+      cur = b + match_size;
+    }
+
+  if (only_matching)
+    cur = lim;
+  else if (mid)
+    cur = mid;
+
+  return cur;
+}
+
+static const char *
+print_line_tail (const char *beg, const char *lim, const char *line_color)
+{
+  size_t eol_size;
+  size_t tail_size;
+
+  eol_size   = (lim > beg && lim[-1] == eolbyte);
+  eol_size  += (lim - eol_size > beg && lim[-(1 + eol_size)] == '\r');
+  tail_size  =  lim - eol_size - beg;
+
+  if (tail_size > 0)
+    {
+      pr_sgr_start (line_color);
+      fwrite (beg, 1, tail_size, stdout);
+      beg += tail_size;
+      pr_sgr_end (line_color);
+    }
+
+  return beg;
+}
+
+static void
+prline (char const *beg, char const *lim, int sep)
+{
+  int matching;
+  const char *line_color;
+  const char *match_color;
+
+  if (!only_matching)
+    print_line_head (beg, lim, sep);
+
+  matching = (sep == SEP_CHAR_SELECTED) ^ out_invert;
+
+  if (color_option)
+    {
+      line_color = (((sep == SEP_CHAR_SELECTED)
+                     ^ (out_invert && (color_option < 0)))
+                    ? selected_line_color  : context_line_color);
+      match_color = (sep == SEP_CHAR_SELECTED
+                     ? selected_match_color : context_match_color);
+    }
+  else
+    line_color = match_color = NULL; /* Shouldn't be used.  */
+
+  if ((only_matching && matching)
+      || (color_option && (*line_color || *match_color)))
+    {
+      /* We already know that non-matching lines have no match (to colorize). */
+      if (matching && (only_matching || *match_color))
+        beg = print_line_middle (beg, lim, line_color, match_color);
+
+      if (!only_matching && *line_color)
+        {
+          /* This code is exercised at least when grep is invoked like this:
+             echo k| GREP_COLORS='sl=01;32' src/grep k --color=always  */
+          beg = print_line_tail (beg, lim, line_color);
+        }
+    }
+
+  if (!only_matching && lim > beg)
+    fwrite (beg, 1, lim - beg, stdout);
+
+  if (ferror (stdout))
+    {
+      write_error_seen = 1;
+      error (EXIT_TROUBLE, 0, _("write error"));
+    }
+
+  lastout = lim;
+
+  if (line_buffered)
+    fflush (stdout);
+}
+
+/* Print pending lines of trailing context prior to LIM. Trailing context ends
+   at the next matching line when OUTLEFT is 0.  */
+static void
+prpending (char const *lim)
+{
+  if (!lastout)
+    lastout = bufbeg;
+  while (pending > 0 && lastout < lim)
+    {
+      char const *nl = memchr (lastout, eolbyte, lim - lastout);
+      size_t match_size;
+      --pending;
+      if (outleft
+          || ((execute (lastout, nl + 1 - lastout,
+                        &match_size, NULL) == (size_t) -1)
+              == !out_invert))
+        prline (lastout, nl + 1, SEP_CHAR_REJECTED);
+      else
+        pending = 0;
+    }
+}
+
+/* Output the lines between BEG and LIM.  Deal with context.  */
+static void
+prtext (char const *beg, char const *lim)
+{
+  static bool used;    /* Avoid printing SEP_STR_GROUP before any output.  */
+  char eol = eolbyte;
+
+  if (!out_quiet && pending > 0)
+    prpending (beg);
+
+  char const *p = beg;
+
+  if (!out_quiet)
+    {
+      /* Deal with leading context.  */
+      char const *bp = lastout ? lastout : bufbeg;
+      intmax_t i;
+      for (i = 0; i < out_before; ++i)
+        if (p > bp)
+          do
+            --p;
+          while (p[-1] != eol);
+
+      /* Print the group separator unless the output is adjacent to
+         the previous output in the file.  */
+      if ((0 <= out_before || 0 <= out_after) && used
+          && p != lastout && group_separator)
+        {
+          pr_sgr_start_if (sep_color);
+          fputs (group_separator, stdout);
+          pr_sgr_end_if (sep_color);
+          fputc ('\n', stdout);
+        }
+
+      while (p < beg)
+        {
+          char const *nl = memchr (p, eol, beg - p);
+          nl++;
+          prline (p, nl, SEP_CHAR_REJECTED);
+          p = nl;
+        }
+    }
+
+  intmax_t n;
+  if (out_invert)
+    {
+      /* One or more lines are output.  */
+      for (n = 0; p < lim && n < outleft; n++)
+        {
+          char const *nl = memchr (p, eol, lim - p);
+          nl++;
+          if (!out_quiet)
+            prline (p, nl, SEP_CHAR_SELECTED);
+          p = nl;
+        }
+    }
+  else
+    {
+      /* Just one line is output.  */
+      if (!out_quiet)
+        prline (beg, lim, SEP_CHAR_SELECTED);
+      n = 1;
+      p = lim;
+    }
+
+  after_last_match = bufoffset - (buflim - p);
+  pending = out_quiet ? 0 : out_after;
+  used = true;
+  outleft -= n;
+}
+
+/* Invoke the matcher, EXECUTE, on buffer BUF of SIZE bytes.  If there
+   is no match, return (size_t) -1.  Otherwise, set *MATCH_SIZE to the
+   length of the match and return the offset of the start of the match.  */
+static size_t
+do_execute (char const *buf, size_t size, size_t *match_size,
+            char const *start_ptr)
+{
+  size_t result;
+  const char *line_next;
+
+  /* With the current implementation, using --ignore-case with a multi-byte
+     character set is very inefficient when applied to a large buffer
+     containing many matches.  We can avoid much of the wasted effort
+     by matching line-by-line.
+
+     FIXME: this is just an ugly workaround, and it doesn't really
+     belong here.  Also, PCRE is always using this same per-line
+     matching algorithm.  Either we fix -i, or we should refactor
+     this code---for example, we could add another function pointer
+     to struct matcher to split the buffer passed to execute.  It would
+     perform the memchr if line-by-line matching is necessary, or just
+     return buf + size otherwise.  */
+  if (! (execute == Fexecute || execute == Pexecute)
+      || MB_CUR_MAX == 1 || !match_icase)
+    return execute (buf, size, match_size, start_ptr);
+
+  for (line_next = buf; line_next < buf + size; )
+    {
+      const char *line_buf = line_next;
+      const char *line_end = memchr (line_buf, eolbyte,
+                                     (buf + size) - line_buf);
+      if (line_end == NULL)
+        line_next = line_end = buf + size;
+      else
+        line_next = line_end + 1;
+
+      if (start_ptr && start_ptr >= line_end)
+        continue;
+
+      result = execute (line_buf, line_next - line_buf, match_size, start_ptr);
+      if (result != (size_t) -1)
+        return (line_buf - buf) + result;
+    }
+
+  return (size_t) -1;
+}
+
+/* Scan the specified portion of the buffer, matching lines (or
+   between matching lines if OUT_INVERT is true).  Return a count of
+   lines printed. */
+static intmax_t
+grepbuf (char const *beg, char const *lim)
+{
+  intmax_t outleft0 = outleft;
+  char const *p;
+  char const *endp;
+
+  for (p = beg; p < lim; p = endp)
+    {
+      size_t match_size;
+      size_t match_offset = do_execute (p, lim - p, &match_size, NULL);
+      if (match_offset == (size_t) -1)
+        {
+          if (!out_invert)
+            break;
+          match_offset = lim - p;
+          match_size = 0;
+        }
+      char const *b = p + match_offset;
+      endp = b + match_size;
+      /* Avoid matching the empty line at the end of the buffer. */
+      if (!out_invert && b == lim)
+        break;
+      if (!out_invert || p < b)
+        {
+          char const *prbeg = out_invert ? p : b;
+          char const *prend = out_invert ? b : endp;
+          prtext (prbeg, prend);
+          if (!outleft || done_on_match)
+            {
+              if (exit_on_match)
+                exit (EXIT_SUCCESS);
+              break;
+            }
+        }
+    }
+
+  return outleft0 - outleft;
+}
+
+/* Search a given file.  Normally, return a count of lines printed;
+   but if the file is a directory and we search it recursively, then
+   return -2 if there was a match, and -1 otherwise.  */
+static intmax_t
+grep (int fd, struct stat const *st)
+{
+  intmax_t nlines, i;
+  int not_text;
+  size_t residue, save;
+  char oldc;
+  char *beg;
+  char *lim;
+  char eol = eolbyte;
+
+  if (! reset (fd, st))
+    return 0;
+
+  totalcc = 0;
+  lastout = 0;
+  totalnl = 0;
+  outleft = max_count;
+  after_last_match = 0;
+  pending = 0;
+
+  nlines = 0;
+  residue = 0;
+  save = 0;
+
+  if (! fillbuf (save, st))
+    {
+      suppressible_error (filename, errno);
+      return 0;
+    }
+
+  not_text = (((binary_files == BINARY_BINARY_FILES && !out_quiet)
+               || binary_files == WITHOUT_MATCH_BINARY_FILES)
+              && file_is_binary (bufbeg, buflim - bufbeg, fd, st));
+  if (not_text && binary_files == WITHOUT_MATCH_BINARY_FILES)
+    return 0;
+  done_on_match += not_text;
+  out_quiet += not_text;
+
+  for (;;)
+    {
+      lastnl = bufbeg;
+      if (lastout)
+        lastout = bufbeg;
+
+      beg = bufbeg + save;
+
+      /* no more data to scan (eof) except for maybe a residue -> break */
+      if (beg == buflim)
+        break;
+
+      /* Determine new residue (the length of an incomplete line at the end of
+         the buffer, 0 means there is no incomplete last line).  */
+      oldc = beg[-1];
+      beg[-1] = eol;
+      /* FIXME: use rawmemrchr if/when it exists, since we have ensured
+         that this use of memrchr is guaranteed never to return NULL.  */
+      lim = memrchr (beg - 1, eol, buflim - beg + 1);
+      ++lim;
+      beg[-1] = oldc;
+      if (lim == beg)
+        lim = beg - residue;
+      beg -= residue;
+      residue = buflim - lim;
+
+      if (beg < lim)
+        {
+          if (outleft)
+            nlines += grepbuf (beg, lim);
+          if (pending)
+            prpending (lim);
+          if ((!outleft && !pending) || (nlines && done_on_match))
+            goto finish_grep;
+        }
+
+      /* The last OUT_BEFORE lines at the end of the buffer will be needed as
+         leading context if there is a matching line at the begin of the
+         next data. Make beg point to their begin.  */
+      i = 0;
+      beg = lim;
+      while (i < out_before && beg > bufbeg && beg != lastout)
+        {
+          ++i;
+          do
+            --beg;
+          while (beg[-1] != eol);
+        }
+
+      /* Detect whether leading context is adjacent to previous output.  */
+      if (beg != lastout)
+        lastout = 0;
+
+      /* Handle some details and read more data to scan.  */
+      save = residue + lim - beg;
+      if (out_byte)
+        totalcc = add_count (totalcc, buflim - bufbeg - save);
+      if (out_line)
+        nlscan (beg);
+      if (! fillbuf (save, st))
+        {
+          suppressible_error (filename, errno);
+          goto finish_grep;
+        }
+    }
+  if (residue)
+    {
+      *buflim++ = eol;
+      if (outleft)
+        nlines += grepbuf (bufbeg + save - residue, buflim);
+      if (pending)
+        prpending (buflim);
+    }
+
+ finish_grep:
+  done_on_match -= not_text;
+  out_quiet -= not_text;
+  if ((not_text & ~out_quiet) && nlines != 0)
+    printf (_("Binary file %s matches\n"), filename);
+  return nlines;
+}
+
+static int
+grepdirent (FTS *fts, FTSENT *ent, int command_line)
+{
+  int follow, dirdesc;
+  struct stat *st = ent->fts_statp;
+  command_line &= ent->fts_level == FTS_ROOTLEVEL;
+
+  if (ent->fts_info == FTS_DP)
+    {
+      if (directories == RECURSE_DIRECTORIES && command_line)
+        out_file &= ~ (2 * !no_filenames);
+      return 1;
+    }
+
+  if (skipped_file (ent->fts_name, command_line,
+                    (ent->fts_info == FTS_D || ent->fts_info == FTS_DC
+                     || ent->fts_info == FTS_DNR)))
+    {
+      fts_set (fts, ent, FTS_SKIP);
+      return 1;
+    }
+
+  filename = ent->fts_path + filename_prefix_len;
+  follow = (fts->fts_options & FTS_LOGICAL
+            || (fts->fts_options & FTS_COMFOLLOW && command_line));
+
+  switch (ent->fts_info)
+    {
+    case FTS_D:
+      if (directories == RECURSE_DIRECTORIES)
+        {
+          out_file |= 2 * !no_filenames;
+          return 1;
+        }
+      fts_set (fts, ent, FTS_SKIP);
+      break;
+
+    case FTS_DC:
+      if (!suppress_errors)
+        error (0, 0, _("warning: %s: %s"), filename,
+               _("recursive directory loop"));
+      return 1;
+
+    case FTS_DNR:
+    case FTS_ERR:
+    case FTS_NS:
+      suppressible_error (filename, ent->fts_errno);
+      return 1;
+
+    case FTS_DEFAULT:
+    case FTS_NSOK:
+      if (devices == SKIP_DEVICES
+          || (devices == READ_COMMAND_LINE_DEVICES && !command_line))
+        {
+          struct stat st1;
+          if (! st->st_mode)
+            {
+              /* The file type is not already known.  Get the file status
+                 before opening, since opening might have side effects
+                 on a device.  */
+              int flag = follow ? 0 : AT_SYMLINK_NOFOLLOW;
+              if (fstatat (fts->fts_cwd_fd, ent->fts_accpath, &st1, flag) != 0)
+                {
+                  suppressible_error (filename, errno);
+                  return 1;
+                }
+              st = &st1;
+            }
+          if (is_device_mode (st->st_mode))
+            return 1;
+        }
+      break;
+
+    case FTS_F:
+    case FTS_SLNONE:
+      break;
+
+    case FTS_SL:
+    case FTS_W:
+      return 1;
+
+    default:
+      abort ();
+    }
+
+  dirdesc = ((fts->fts_options & (FTS_NOCHDIR | FTS_CWDFD)) == FTS_CWDFD
+             ? fts->fts_cwd_fd
+             : AT_FDCWD);
+  return grepfile (dirdesc, ent->fts_accpath, follow, command_line);
+}
+
+static int
+grepfile (int dirdesc, char const *name, int follow, int command_line)
+{
+  int desc = openat_safer (dirdesc, name, O_RDONLY | (follow ? 0 : O_NOFOLLOW));
+  if (desc < 0)
+    {
+      if (follow || (errno != ELOOP && errno != EMLINK))
+        suppressible_error (filename, errno);
+      return 1;
+    }
+  return grepdesc (desc, command_line);
+}
+
+static int
+grepdesc (int desc, int command_line)
+{
+  intmax_t count;
+  int status = 1;
+  struct stat st;
+
+  /* Get the file status, possibly for the second time.  This catches
+     a race condition if the directory entry changes after the
+     directory entry is read and before the file is opened.  For
+     example, normally DESC is a directory only at the top level, but
+     there is an exception if some other process substitutes a
+     directory for a non-directory while 'grep' is running.  */
+  if (fstat (desc, &st) != 0)
+    {
+      suppressible_error (filename, errno);
+      goto closeout;
+    }
+
+  if (desc != STDIN_FILENO && command_line
+      && skipped_file (filename, 1, S_ISDIR (st.st_mode)))
+    goto closeout;
+
+  if (desc != STDIN_FILENO
+      && directories == RECURSE_DIRECTORIES && S_ISDIR (st.st_mode))
+    {
+      /* Traverse the directory starting with its full name, because
+         unfortunately fts provides no way to traverse the directory
+         starting from its file descriptor.  */
+
+      FTS *fts;
+      FTSENT *ent;
+      int opts = fts_options & ~(command_line ? 0 : FTS_COMFOLLOW);
+      char *fts_arg[2];
+
+      /* Close DESC now, to conserve file descriptors if the race
+         condition occurs many times in a deep recursion.  */
+      if (close (desc) != 0)
+        suppressible_error (filename, errno);
+
+      fts_arg[0] = (char *) filename;
+      fts_arg[1] = NULL;
+      fts = fts_open (fts_arg, opts, NULL);
+
+      if (!fts)
+        xalloc_die ();
+      while ((ent = fts_read (fts)))
+        status &= grepdirent (fts, ent, command_line);
+      if (errno)
+        suppressible_error (filename, errno);
+      if (fts_close (fts) != 0)
+        suppressible_error (filename, errno);
+      return status;
+    }
+  if (desc != STDIN_FILENO
+      && ((directories == SKIP_DIRECTORIES && S_ISDIR (st.st_mode))
+          || ((devices == SKIP_DEVICES
+               || (devices == READ_COMMAND_LINE_DEVICES && !command_line))
+              && is_device_mode (st.st_mode))))
+    goto closeout;
+
+  /* If there is a regular file on stdout and the current file refers
+     to the same i-node, we have to report the problem and skip it.
+     Otherwise when matching lines from some other input reach the
+     disk before we open this file, we can end up reading and matching
+     those lines and appending them to the file from which we're reading.
+     Then we'd have what appears to be an infinite loop that'd terminate
+     only upon filling the output file system or reaching a quota.
+     However, there is no risk of an infinite loop if grep is generating
+     no output, i.e., with --silent, --quiet, -q.
+     Similarly, with any of these:
+       --max-count=N (-m) (for N >= 2)
+       --files-with-matches (-l)
+       --files-without-match (-L)
+     there is no risk of trouble.
+     For --max-count=1, grep stops after printing the first match,
+     so there is no risk of malfunction.  But even --max-count=2, with
+     input==output, while there is no risk of infloop, there is a race
+     condition that could result in "alternate" output.  */
+  if (!out_quiet && list_files == 0 && 1 < max_count
+      && S_ISREG (out_stat.st_mode) && out_stat.st_ino
+      && SAME_INODE (st, out_stat))
+    {
+      if (! suppress_errors)
+        error (0, 0, _("input file %s is also the output"), quote (filename));
+      errseen = 1;
+      goto closeout;
+    }
+
+#if defined SET_BINARY
+  /* Set input to binary mode.  Pipes are simulated with files
+     on DOS, so this includes the case of "foo | grep bar".  */
+  if (!isatty (desc))
+    SET_BINARY (desc);
+#endif
+
+  count = grep (desc, &st);
+  if (count < 0)
+    status = count + 2;
+  else
+    {
+      if (count_matches)
+        {
+          if (out_file)
+            {
+              print_filename ();
+              if (filename_mask)
+                print_sep (SEP_CHAR_SELECTED);
+              else
+                fputc (0, stdout);
+            }
+          printf ("%" PRIdMAX "\n", count);
+        }
+
+      status = !count;
+      if (list_files == 1 - 2 * status)
+        {
+          print_filename ();
+          fputc ('\n' & filename_mask, stdout);
+        }
+
+      if (desc == STDIN_FILENO)
+        {
+          off_t required_offset = outleft ? bufoffset : after_last_match;
+          if (required_offset != bufoffset
+              && lseek (desc, required_offset, SEEK_SET) < 0
+              && S_ISREG (st.st_mode))
+            suppressible_error (filename, errno);
+        }
+    }
+
+ closeout:
+  if (desc != STDIN_FILENO && close (desc) != 0)
+    suppressible_error (filename, errno);
+  return status;
+}
+
+static int
+grep_command_line_arg (char const *arg)
+{
+  if (STREQ (arg, "-"))
+    {
+      filename = label ? label : _("(standard input)");
+      return grepdesc (STDIN_FILENO, 1);
+    }
+  else
+    {
+      filename = arg;
+      return grepfile (AT_FDCWD, arg, 1, 1);
+    }
+}
+
+_Noreturn void usage (int);
+void
+usage (int status)
+{
+  if (status != 0)
+    {
+      fprintf (stderr, _("Usage: %s [OPTION]... PATTERN [FILE]...\n"),
+               program_name);
+      fprintf (stderr, _("Try '%s --help' for more information.\n"),
+               program_name);
+    }
+  else
+    {
+      printf (_("Usage: %s [OPTION]... PATTERN [FILE]...\n"), program_name);
+      printf (_("Search for PATTERN in each FILE or standard input.\n"));
+      printf (_("PATTERN is, by default, a basic regular expression (BRE).\n"));
+      printf (_("\
+Example: %s -i 'hello world' menu.h main.c\n\
+\n\
+Regexp selection and interpretation:\n"), program_name);
+      printf (_("\
+  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n\
+  -F, --fixed-strings       PATTERN is a set of newline-separated fixed strings\n\
+  -G, --basic-regexp        PATTERN is a basic regular expression (BRE)\n\
+  -P, --perl-regexp         PATTERN is a Perl regular expression\n"));
+  /* -X is undocumented on purpose. */
+      printf (_("\
+  -e, --regexp=PATTERN      use PATTERN for matching\n\
+  -f, --file=FILE           obtain PATTERN from FILE\n\
+  -i, --ignore-case         ignore case distinctions\n\
+  -w, --word-regexp         force PATTERN to match only whole words\n\
+  -x, --line-regexp         force PATTERN to match only whole lines\n\
+  -z, --null-data           a data line ends in 0 byte, not newline\n"));
+      printf (_("\
+\n\
+Miscellaneous:\n\
+  -s, --no-messages         suppress error messages\n\
+  -v, --invert-match        select non-matching lines\n\
+  -V, --version             display version information and exit\n\
+      --help                display this help text and exit\n"));
+      printf (_("\
+\n\
+Output control:\n\
+  -m, --max-count=NUM       stop after NUM matches\n\
+  -b, --byte-offset         print the byte offset with output lines\n\
+  -n, --line-number         print line number with output lines\n\
+      --line-buffered       flush output on every line\n\
+  -H, --with-filename       print the file name for each match\n\
+  -h, --no-filename         suppress the file name prefix on output\n\
+      --label=LABEL         use LABEL as the standard input file name prefix\n\
+"));
+      printf (_("\
+  -o, --only-matching       show only the part of a line matching PATTERN\n\
+  -q, --quiet, --silent     suppress all normal output\n\
+      --binary-files=TYPE   assume that binary files are TYPE;\n\
+                            TYPE is 'binary', 'text', or 'without-match'\n\
+  -a, --text                equivalent to --binary-files=text\n\
+"));
+      printf (_("\
+  -I                        equivalent to --binary-files=without-match\n\
+  -d, --directories=ACTION  how to handle directories;\n\
+                            ACTION is 'read', 'recurse', or 'skip'\n\
+  -D, --devices=ACTION      how to handle devices, FIFOs and sockets;\n\
+                            ACTION is 'read' or 'skip'\n\
+  -r, --recursive           like --directories=recurse\n\
+  -R, --dereference-recursive  likewise, but follow all symlinks\n\
+"));
+      printf (_("\
+      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n\
+      --exclude=FILE_PATTERN  skip files and directories matching FILE_PATTERN\n\
+      --exclude-from=FILE   skip files matching any file pattern from FILE\n\
+      --exclude-dir=PATTERN  directories that match PATTERN will be skipped.\n\
+"));
+      printf (_("\
+  -L, --files-without-match  print only names of FILEs containing no match\n\
+  -l, --files-with-matches  print only names of FILEs containing matches\n\
+  -c, --count               print only a count of matching lines per FILE\n\
+  -T, --initial-tab         make tabs line up (if needed)\n\
+  -Z, --null                print 0 byte after FILE name\n"));
+      printf (_("\
+\n\
+Context control:\n\
+  -B, --before-context=NUM  print NUM lines of leading context\n\
+  -A, --after-context=NUM   print NUM lines of trailing context\n\
+  -C, --context=NUM         print NUM lines of output context\n\
+"));
+      printf (_("\
+  -NUM                      same as --context=NUM\n\
+      --color[=WHEN],\n\
+      --colour[=WHEN]       use markers to highlight the matching strings;\n\
+                            WHEN is 'always', 'never', or 'auto'\n\
+  -U, --binary              do not strip CR characters at EOL (MSDOS/Windows)\n\
+  -u, --unix-byte-offsets   report offsets as if CRs were not there\n\
+                            (MSDOS/Windows)\n\
+\n"));
+      printf (_("\
+'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n\
+Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n"));
+      printf (_("\
+When FILE is -, read standard input.  With no FILE, read . if a command-line\n\
+-r is given, - otherwise.  If fewer than two FILEs are given, assume -h.\n\
+Exit status is 0 if any line is selected, 1 otherwise;\n\
+if any error occurs and -q is not given, the exit status is 2.\n"));
+      printf (_("\nReport bugs to: %s\n"), PACKAGE_BUGREPORT);
+      printf (_("GNU Grep home page: <%s>\n"),
+              "http://www.gnu.org/software/grep/");
+      fputs (_("General help using GNU software: <http://www.gnu.org/gethelp/>\n"),
+             stdout);
+
+    }
+  exit (status);
+}
+
+/* Pattern compilers and matchers.  */
 
 static void
 Gcompile (char const *pattern, size_t size)
@@ -19,17 +1651,736 @@ Acompile (char const *pattern, size_t size)
   GEAcompile (pattern, size, RE_SYNTAX_AWK);
 }
 
-struct matcher const matchers[] = {
-  { "grep",    Gcompile, EGexecute },
-  { "egrep",   Ecompile, EGexecute },
-  { "awk",     Acompile, EGexecute },
-  { "fgrep",   Fcompile, Fexecute },
-  { "perl",    Pcompile, Pexecute },
-  { NULL, NULL, NULL },
+static void
+GAcompile (char const *pattern, size_t size)
+{
+  GEAcompile (pattern, size, RE_SYNTAX_GNU_AWK);
+}
+
+static void
+PAcompile (char const *pattern, size_t size)
+{
+  GEAcompile (pattern, size, RE_SYNTAX_POSIX_AWK);
+}
+
+struct matcher
+{
+  char const name[16];
+  compile_fp_t compile;
+  execute_fp_t execute;
+};
+static struct matcher const matchers[] = {
+  { "grep",      Gcompile, EGexecute },
+  { "egrep",     Ecompile, EGexecute },
+  { "fgrep",     Fcompile,  Fexecute },
+  { "awk",       Acompile, EGexecute },
+  { "gawk",     GAcompile, EGexecute },
+  { "posixawk", PAcompile, EGexecute },
+  { "perl",      Pcompile,  Pexecute },
+  { "", NULL, NULL },
 };
 
-const char before_options[] =
-N_("PATTERN is, by default, a basic regular expression (BRE).\n");
-const char after_options[] =
-N_("'egrep' means 'grep -E'.  'fgrep' means 'grep -F'.\n\
-Direct invocation as either 'egrep' or 'fgrep' is deprecated.\n");
+/* Set the matcher to M if available.  Exit in case of conflicts or if
+   M is not available.  */
+static void
+setmatcher (char const *m)
+{
+  struct matcher const *p;
+
+  if (matcher && !STREQ (matcher, m))
+    error (EXIT_TROUBLE, 0, _("conflicting matchers specified"));
+
+  for (p = matchers; p->compile; p++)
+    if (STREQ (m, p->name))
+      {
+        matcher = p->name;
+        compile = p->compile;
+        execute = p->execute;
+        return;
+      }
+
+  error (EXIT_TROUBLE, 0, _("invalid matcher %s"), m);
+}
+
+/* Find the white-space-separated options specified by OPTIONS, and
+   using BUF to store copies of these options, set ARGV[0], ARGV[1],
+   etc. to the option copies.  Return the number N of options found.
+   Do not set ARGV[N] to NULL.  If ARGV is NULL, do not store ARGV[0]
+   etc.  Backslash can be used to escape whitespace (and backslashes).  */
+static size_t
+prepend_args (char const *options, char *buf, char **argv)
+{
+  char const *o = options;
+  char *b = buf;
+  size_t n = 0;
+
+  for (;;)
+    {
+      while (c_isspace (to_uchar (*o)))
+        o++;
+      if (!*o)
+        return n;
+      if (argv)
+        argv[n] = b;
+      n++;
+
+      do
+        if ((*b++ = *o++) == '\\' && *o)
+          b[-1] = *o++;
+      while (*o && ! c_isspace (to_uchar (*o)));
+
+      *b++ = '\0';
+    }
+}
+
+/* Prepend the whitespace-separated options in OPTIONS to the argument
+   vector of a main program with argument count *PARGC and argument
+   vector *PARGV.  Return the number of options prepended.  */
+static int
+prepend_default_options (char const *options, int *pargc, char ***pargv)
+{
+  if (options && *options)
+    {
+      char *buf = xmalloc (strlen (options) + 1);
+      size_t prepended = prepend_args (options, buf, NULL);
+      int argc = *pargc;
+      char *const *argv = *pargv;
+      char **pp;
+      enum { MAX_ARGS = MIN (INT_MAX, SIZE_MAX / sizeof *pp - 1) };
+      if (MAX_ARGS - argc < prepended)
+        xalloc_die ();
+      pp = xmalloc ((prepended + argc + 1) * sizeof *pp);
+      *pargc = prepended + argc;
+      *pargv = pp;
+      *pp++ = *argv++;
+      pp += prepend_args (options, buf, pp);
+      while ((*pp++ = *argv++))
+        continue;
+      return prepended;
+    }
+
+  return 0;
+}
+
+/* Get the next non-digit option from ARGC and ARGV.
+   Return -1 if there are no more options.
+   Process any digit options that were encountered on the way,
+   and store the resulting integer into *DEFAULT_CONTEXT.  */
+static int
+get_nondigit_option (int argc, char *const *argv, intmax_t *default_context)
+{
+  static int prev_digit_optind = -1;
+  int this_digit_optind, was_digit;
+  char buf[INT_BUFSIZE_BOUND (intmax_t) + 4];
+  char *p = buf;
+  int opt;
+
+  was_digit = 0;
+  this_digit_optind = optind;
+  while (1)
+    {
+      opt = getopt_long (argc, (char **) argv, short_options,
+                         long_options, NULL);
+      if ( ! ('0' <= opt && opt <= '9'))
+        break;
+
+      if (prev_digit_optind != this_digit_optind || !was_digit)
+        {
+          /* Reset to start another context length argument.  */
+          p = buf;
+        }
+      else
+        {
+          /* Suppress trivial leading zeros, to avoid incorrect
+             diagnostic on strings like 00000000000.  */
+          p -= buf[0] == '0';
+        }
+
+      if (p == buf + sizeof buf - 4)
+        {
+          /* Too many digits.  Append "..." to make context_length_arg
+             complain about "X...", where X contains the digits seen
+             so far.  */
+          strcpy (p, "...");
+          p += 3;
+          break;
+        }
+      *p++ = opt;
+
+      was_digit = 1;
+      prev_digit_optind = this_digit_optind;
+      this_digit_optind = optind;
+    }
+  if (p != buf)
+    {
+      *p = '\0';
+      context_length_arg (buf, default_context);
+    }
+
+  return opt;
+}
+
+/* Parse GREP_COLORS.  The default would look like:
+     GREP_COLORS='ms=01;31:mc=01;31:sl=:cx=:fn=35:ln=32:bn=32:se=36'
+   with boolean capabilities (ne and rv) unset (i.e., omitted).
+   No character escaping is needed or supported.  */
+static void
+parse_grep_colors (void)
+{
+  const char *p;
+  char *q;
+  char *name;
+  char *val;
+
+  p = getenv ("GREP_COLORS"); /* Plural! */
+  if (p == NULL || *p == '\0')
+    return;
+
+  /* Work off a writable copy.  */
+  q = xstrdup (p);
+
+  name = q;
+  val = NULL;
+  /* From now on, be well-formed or you're gone.  */
+  for (;;)
+    if (*q == ':' || *q == '\0')
+      {
+        char c = *q;
+        struct color_cap const *cap;
+
+        *q++ = '\0'; /* Terminate name or val.  */
+        /* Empty name without val (empty cap)
+         * won't match and will be ignored.  */
+        for (cap = color_dict; cap->name; cap++)
+          if (STREQ (cap->name, name))
+            break;
+        /* If name unknown, go on for forward compatibility.  */
+        if (cap->var && val)
+          *(cap->var) = val;
+        if (cap->fct)
+          cap->fct ();
+        if (c == '\0')
+          return;
+        name = q;
+        val = NULL;
+      }
+    else if (*q == '=')
+      {
+        if (q == name || val)
+          return;
+        *q++ = '\0'; /* Terminate name.  */
+        val = q; /* Can be the empty string.  */
+      }
+    else if (val == NULL)
+      q++; /* Accumulate name.  */
+    else if (*q == ';' || (*q >= '0' && *q <= '9'))
+      q++; /* Accumulate val.  Protect the terminal from being sent crap.  */
+    else
+      return;
+}
+
+/* Return true if PAT (of length PATLEN) contains an encoding error.  */
+static bool
+contains_encoding_error (char const *pat, size_t patlen)
+{
+  mbstate_t mbs = { 0 };
+  size_t i, charlen;
+
+  for (i = 0; i < patlen; i += charlen + (charlen == 0))
+    {
+      charlen = mbrlen (pat + i, patlen - i, &mbs);
+      if ((size_t) -2 <= charlen)
+        return true;
+    }
+  return false;
+}
+
+/* Change a pattern for fgrep into grep.  */
+static void
+fgrep_to_grep_pattern (size_t len, char const *keys,
+                       size_t *new_len, char **new_keys)
+{
+  char *p = *new_keys = xnmalloc (len + 1, 2);
+  mbstate_t mb_state = { 0 };
+  size_t n;
+
+  for (; len; keys += n, len -= n)
+    {
+      wchar_t wc;
+      n = mbrtowc (&wc, keys, len, &mb_state);
+      switch (n)
+        {
+        case (size_t) -2:
+          n = len;
+          /* Fall through.  */
+        default:
+          p = mempcpy (p, keys, n);
+          break;
+
+        case (size_t) -1:
+          memset (&mb_state, 0, sizeof mb_state);
+          /* Fall through.  */
+        case 1:
+          *p = '\\';
+          p += strchr ("$*.[\\^", *keys) != NULL;
+          /* Fall through.  */
+        case 0:
+          *p++ = *keys;
+          n = 1;
+          break;
+        }
+    }
+
+  *new_len = p - *new_keys;
+}
+
+int
+main (int argc, char **argv)
+{
+  char *keys;
+  size_t keycc, oldcc, keyalloc;
+  int with_filenames;
+  size_t cc;
+  int opt, status, prepended;
+  int prev_optind, last_recursive;
+  int fread_errno;
+  intmax_t default_context;
+  FILE *fp;
+  exit_failure = EXIT_TROUBLE;
+  initialize_main (&argc, &argv);
+  set_program_name (argv[0]);
+  program_name = argv[0];
+
+  keys = NULL;
+  keycc = 0;
+  with_filenames = 0;
+  eolbyte = '\n';
+  filename_mask = ~0;
+
+  max_count = INTMAX_MAX;
+
+  /* The value -1 means to use DEFAULT_CONTEXT. */
+  out_after = out_before = -1;
+  /* Default before/after context: changed by -C/-NUM options */
+  default_context = -1;
+  /* Changed by -o option */
+  only_matching = 0;
+
+  /* Internationalization. */
+#if defined HAVE_SETLOCALE
+  setlocale (LC_ALL, "");
+#endif
+#if defined ENABLE_NLS
+  bindtextdomain (PACKAGE, LOCALEDIR);
+  textdomain (PACKAGE);
+#endif
+
+  exit_failure = EXIT_TROUBLE;
+  atexit (clean_up_stdout);
+
+  last_recursive = 0;
+  prepended = prepend_default_options (getenv ("GREP_OPTIONS"), &argc, &argv);
+  compile = matchers[0].compile;
+  execute = matchers[0].execute;
+
+  while (prev_optind = optind,
+         (opt = get_nondigit_option (argc, argv, &default_context)) != -1)
+    switch (opt)
+      {
+      case 'A':
+        context_length_arg (optarg, &out_after);
+        break;
+
+      case 'B':
+        context_length_arg (optarg, &out_before);
+        break;
+
+      case 'C':
+        /* Set output match context, but let any explicit leading or
+           trailing amount specified with -A or -B stand. */
+        context_length_arg (optarg, &default_context);
+        break;
+
+      case 'D':
+        if (STREQ (optarg, "read"))
+          devices = READ_DEVICES;
+        else if (STREQ (optarg, "skip"))
+          devices = SKIP_DEVICES;
+        else
+          error (EXIT_TROUBLE, 0, _("unknown devices method"));
+        break;
+
+      case 'E':
+        setmatcher ("egrep");
+        break;
+
+      case 'F':
+        setmatcher ("fgrep");
+        break;
+
+      case 'P':
+        setmatcher ("perl");
+        break;
+
+      case 'G':
+        setmatcher ("grep");
+        break;
+
+      case 'X': /* undocumented on purpose */
+        setmatcher (optarg);
+        break;
+
+      case 'H':
+        with_filenames = 1;
+        no_filenames = 0;
+        break;
+
+      case 'I':
+        binary_files = WITHOUT_MATCH_BINARY_FILES;
+        break;
+
+      case 'T':
+        align_tabs = 1;
+        break;
+
+      case 'U':
+        dos_binary ();
+        break;
+
+      case 'u':
+        dos_unix_byte_offsets ();
+        break;
+
+      case 'V':
+        show_version = 1;
+        break;
+
+      case 'a':
+        binary_files = TEXT_BINARY_FILES;
+        break;
+
+      case 'b':
+        out_byte = 1;
+        break;
+
+      case 'c':
+        count_matches = 1;
+        break;
+
+      case 'd':
+        directories = XARGMATCH ("--directories", optarg,
+                                 directories_args, directories_types);
+        if (directories == RECURSE_DIRECTORIES)
+          last_recursive = prev_optind;
+        break;
+
+      case 'e':
+        cc = strlen (optarg);
+        keys = xrealloc (keys, keycc + cc + 1);
+        strcpy (&keys[keycc], optarg);
+        keycc += cc;
+        keys[keycc++] = '\n';
+        break;
+
+      case 'f':
+        fp = STREQ (optarg, "-") ? stdin : fopen (optarg, O_TEXT ? "rt" : "r");
+        if (!fp)
+          error (EXIT_TROUBLE, errno, "%s", optarg);
+        for (keyalloc = 1; keyalloc <= keycc + 1; keyalloc *= 2)
+          ;
+        keys = xrealloc (keys, keyalloc);
+        oldcc = keycc;
+        while ((cc = fread (keys + keycc, 1, keyalloc - 1 - keycc, fp)) != 0)
+          {
+            keycc += cc;
+            if (keycc == keyalloc - 1)
+              keys = x2nrealloc (keys, &keyalloc, sizeof *keys);
+          }
+        fread_errno = errno;
+        if (ferror (fp))
+          error (EXIT_TROUBLE, fread_errno, "%s", optarg);
+        if (fp != stdin)
+          fclose (fp);
+        /* Append final newline if file ended in non-newline. */
+        if (oldcc != keycc && keys[keycc - 1] != '\n')
+          keys[keycc++] = '\n';
+        break;
+
+      case 'h':
+        with_filenames = 0;
+        no_filenames = 1;
+        break;
+
+      case 'i':
+      case 'y':                        /* For old-timers . . . */
+        match_icase = 1;
+        break;
+
+      case 'L':
+        /* Like -l, except list files that don't contain matches.
+           Inspired by the same option in Hume's gre. */
+        list_files = -1;
+        break;
+
+      case 'l':
+        list_files = 1;
+        break;
+
+      case 'm':
+        switch (xstrtoimax (optarg, 0, 10, &max_count, ""))
+          {
+          case LONGINT_OK:
+          case LONGINT_OVERFLOW:
+            break;
+
+          default:
+            error (EXIT_TROUBLE, 0, _("invalid max count"));
+          }
+        break;
+
+      case 'n':
+        out_line = 1;
+        break;
+
+      case 'o':
+        only_matching = 1;
+        break;
+
+      case 'q':
+        exit_on_match = 1;
+        exit_failure = 0;
+        break;
+
+      case 'R':
+        fts_options = basic_fts_options | FTS_LOGICAL;
+        /* Fall through.  */
+      case 'r':
+        directories = RECURSE_DIRECTORIES;
+        last_recursive = prev_optind;
+        break;
+
+      case 's':
+        suppress_errors = 1;
+        break;
+
+      case 'v':
+        out_invert = true;
+        break;
+
+      case 'w':
+        match_words = 1;
+        break;
+
+      case 'x':
+        match_lines = 1;
+        break;
+
+      case 'Z':
+        filename_mask = 0;
+        break;
+
+      case 'z':
+        eolbyte = '\0';
+        break;
+
+      case BINARY_FILES_OPTION:
+        if (STREQ (optarg, "binary"))
+          binary_files = BINARY_BINARY_FILES;
+        else if (STREQ (optarg, "text"))
+          binary_files = TEXT_BINARY_FILES;
+        else if (STREQ (optarg, "without-match"))
+          binary_files = WITHOUT_MATCH_BINARY_FILES;
+        else
+          error (EXIT_TROUBLE, 0, _("unknown binary-files type"));
+        break;
+
+      case COLOR_OPTION:
+        if (optarg)
+          {
+            if (!strcasecmp (optarg, "always") || !strcasecmp (optarg, "yes")
+                || !strcasecmp (optarg, "force"))
+              color_option = 1;
+            else if (!strcasecmp (optarg, "never") || !strcasecmp (optarg, "no")
+                     || !strcasecmp (optarg, "none"))
+              color_option = 0;
+            else if (!strcasecmp (optarg, "auto") || !strcasecmp (optarg, "tty")
+                     || !strcasecmp (optarg, "if-tty"))
+              color_option = 2;
+            else
+              show_help = 1;
+          }
+        else
+          color_option = 2;
+        break;
+
+      case EXCLUDE_OPTION:
+      case INCLUDE_OPTION:
+        if (!excluded_patterns)
+          excluded_patterns = new_exclude ();
+        add_exclude (excluded_patterns, optarg,
+                     (EXCLUDE_WILDCARDS
+                      | (opt == INCLUDE_OPTION ? EXCLUDE_INCLUDE : 0)));
+        break;
+      case EXCLUDE_FROM_OPTION:
+        if (!excluded_patterns)
+          excluded_patterns = new_exclude ();
+        if (add_exclude_file (add_exclude, excluded_patterns, optarg,
+                              EXCLUDE_WILDCARDS, '\n') != 0)
+          {
+            error (EXIT_TROUBLE, errno, "%s", optarg);
+          }
+        break;
+
+      case EXCLUDE_DIRECTORY_OPTION:
+        if (!excluded_directory_patterns)
+          excluded_directory_patterns = new_exclude ();
+        add_exclude (excluded_directory_patterns, optarg, EXCLUDE_WILDCARDS);
+        break;
+
+      case GROUP_SEPARATOR_OPTION:
+        group_separator = optarg;
+        break;
+
+      case LINE_BUFFERED_OPTION:
+        line_buffered = 1;
+        break;
+
+      case LABEL_OPTION:
+        label = optarg;
+        break;
+
+      case 0:
+        /* long options */
+        break;
+
+      default:
+        usage (EXIT_TROUBLE);
+        break;
+
+      }
+
+  if (color_option == 2)
+    color_option = isatty (STDOUT_FILENO) && should_colorize ();
+  init_colorize ();
+
+  /* POSIX says that -q overrides -l, which in turn overrides the
+     other output options.  */
+  if (exit_on_match)
+    list_files = 0;
+  if (exit_on_match | list_files)
+    {
+      count_matches = 0;
+      done_on_match = 1;
+    }
+  out_quiet = count_matches | done_on_match;
+
+  if (out_after < 0)
+    out_after = default_context;
+  if (out_before < 0)
+    out_before = default_context;
+
+  if (color_option)
+    {
+      /* Legacy.  */
+      char *userval = getenv ("GREP_COLOR");
+      if (userval != NULL && *userval != '\0')
+        selected_match_color = context_match_color = userval;
+
+      /* New GREP_COLORS has priority.  */
+      parse_grep_colors ();
+    }
+
+  if (show_version)
+    {
+      version_etc (stdout, program_name, PACKAGE_NAME, VERSION, AUTHORS,
+                   (char *) NULL);
+      exit (EXIT_SUCCESS);
+    }
+
+  if (show_help)
+    usage (EXIT_SUCCESS);
+
+  struct stat tmp_stat;
+  if (fstat (STDOUT_FILENO, &tmp_stat) == 0 && S_ISREG (tmp_stat.st_mode))
+    out_stat = tmp_stat;
+
+  if (keys)
+    {
+      if (keycc == 0)
+        {
+          /* No keys were specified (e.g. -f /dev/null).  Match nothing.  */
+          out_invert ^= true;
+          match_lines = match_words = 0;
+        }
+      else
+        /* Strip trailing newline. */
+        --keycc;
+    }
+  else if (optind < argc)
+    {
+      /* A copy must be made in case of an xrealloc() or free() later.  */
+      keycc = strlen (argv[optind]);
+      keys = xmemdup (argv[optind++], keycc + 1);
+    }
+  else
+    usage (EXIT_TROUBLE);
+
+  /* If fgrep in a multibyte locale, then use grep if either
+     (1) case is ignored (where grep is typically faster), or
+     (2) the pattern has an encoding error (where fgrep might not work).  */
+  if (compile == Fcompile && MB_CUR_MAX > 1
+      && (match_icase || contains_encoding_error (keys, keycc)))
+    {
+      size_t new_keycc;
+      char *new_keys;
+      fgrep_to_grep_pattern (keycc, keys, &new_keycc, &new_keys);
+      free (keys);
+      keys = new_keys;
+      keycc = new_keycc;
+      matcher = "grep";
+      compile = Gcompile;
+      execute = EGexecute;
+    }
+
+  if (MB_CUR_MAX > 1)
+    build_mbclen_cache ();
+
+  compile (keys, keycc);
+  free (keys);
+
+  if ((argc - optind > 1 && !no_filenames) || with_filenames)
+    out_file = 1;
+
+#ifdef SET_BINARY
+  /* Output is set to binary mode because we shouldn't convert
+     NL to CR-LF pairs, especially when grepping binary files.  */
+  if (!isatty (1))
+    SET_BINARY (1);
+#endif
+
+  if (max_count == 0)
+    exit (EXIT_FAILURE);
+
+  if (fts_options & FTS_LOGICAL && devices == READ_COMMAND_LINE_DEVICES)
+    devices = READ_DEVICES;
+
+  if (optind < argc)
+    {
+      status = 1;
+      do
+        status &= grep_command_line_arg (argv[optind]);
+      while (++optind < argc);
+    }
+  else if (directories == RECURSE_DIRECTORIES && prepended < last_recursive)
+    {
+      /* Grep through ".", omitting leading "./" from diagnostics.  */
+      filename_prefix_len = 2;
+      status = grep_command_line_arg (".");
+    }
+  else
+    status = grep_command_line_arg ("-");
+
+  /* We register via atexit() to test stdout.  */
+  exit (errseen ? EXIT_TROUBLE : status);
+}
+/* vim:set shiftwidth=2: */
index 4d642a1..4935872 100644 (file)
 #ifndef GREP_GREP_H
 #define GREP_GREP_H 1
 
-/* Function pointer types.  */
-typedef void (*compile_fp_t) (char const *, size_t);
-typedef size_t (*execute_fp_t) (char const *, size_t, size_t *, char const *);
-
-/* grep.c expects the matchers vector to be terminated by an entry
-   with a NULL name, and to contain at least one entry. */
-struct matcher
-{
-  const char *name;
-  compile_fp_t compile;
-  execute_fp_t execute;
-};
-extern const struct matcher matchers[];
-
-extern const char before_options[];
-extern const char after_options[];
-
 /* The following flags are exported from grep for the matchers
    to look at. */
 extern int match_icase;                /* -i */
index 5d57639..6bd516a 100644 (file)
 #include <config.h>
 #include "search.h"
 
-/* For -w, we also consider _ to be word constituent.  */
-#define WCHAR(C) (isalnum (C) || (C) == '_')
+/* Whether -w considers WC to be a word constituent.  */
+static bool
+wordchar (wint_t wc)
+{
+  return wc == L'_' || iswalnum (wc);
+}
 
 /* KWset compiled pattern.  For Ecompile and Gcompile, we compile
    a list of strings, at least one of which is known to occur in
@@ -32,47 +36,69 @@ static kwset_t kwset;
 void
 Fcompile (char const *pattern, size_t size)
 {
-  char const *err;
-  size_t psize = size;
+  size_t total = size;
   mb_len_map_t *map = NULL;
   char const *pat = (match_icase && MB_CUR_MAX > 1
-                     ? mbtolower (pattern, &psize, &map)
+                     ? mbtoupper (pattern, &total, &map)
                      : pattern);
 
   kwsinit (&kwset);
 
-  char const *beg = pat;
+  char const *p = pat;
   do
     {
-      char const *lim;
-      char const *end;
-      for (lim = beg;; ++lim)
+      size_t len;
+      char const *sep = memchr (p, '\n', total);
+      if (sep)
+        {
+          len = sep - p;
+          sep++;
+          total -= (len + 1);
+        }
+      else
+        {
+          len = total;
+          total = 0;
+        }
+
+      char *buf = NULL;
+      if (match_lines)
         {
-          end = lim;
-          if (lim >= pat + psize)
-            break;
-         if (*lim == '\n')
-           {
-             lim++;
-             break;
-           }
-#if HAVE_DOS_FILE_CONTENTS
-         if (*lim == '\r' && lim + 1 < pat + psize && lim[1] == '\n')
-           {
-             lim += 2;
-             break;
-           }
-#endif
+          buf = xmalloc (len + 2);
+          buf[0] = eolbyte;
+          memcpy (buf + 1, p, len);
+          buf[len + 1] = eolbyte;
+          p = buf;
+          len += 2;
         }
+      kwsincr (kwset, p, len);
+      free (buf);
 
-      if ((err = kwsincr (kwset, beg, end - beg)) != NULL)
-        error (EXIT_TROUBLE, 0, "%s", err);
-      beg = lim;
+      p = sep;
     }
-  while (beg < pat + psize);
+  while (p);
 
-  if ((err = kwsprep (kwset)) != NULL)
-    error (EXIT_TROUBLE, 0, "%s", err);
+  kwsprep (kwset);
+}
+
+/* Apply the MAP (created by mbtoupper) to the uppercase-buffer-relative
+   *OFF and *LEN, converting them to be relative to the original buffer.  */
+
+static void
+mb_case_map_apply (mb_len_map_t const *map, size_t *off, size_t *len)
+{
+  if (map)
+    {
+      size_t off_incr = 0;
+      size_t len_incr = 0;
+      size_t k;
+      for (k = 0; k < *off; k++)
+        off_incr += map[k];
+      for (; k < *off + *len; k++)
+        len_incr += map[k];
+      *off += off_incr;
+      *len += len_incr;
+    }
 }
 
 size_t
@@ -90,7 +116,7 @@ Fexecute (char const *buf, size_t size, size_t *match_size,
     {
       if (match_icase)
         {
-          char *case_buf = mbtolower (buf, &size, &map);
+          char *case_buf = mbtoupper (buf, &size, &map);
           if (start_ptr)
             start_ptr = case_buf + (start_ptr - buf);
           buf = case_buf;
@@ -99,40 +125,30 @@ Fexecute (char const *buf, size_t size, size_t *match_size,
 
   for (mb_start = beg = start_ptr ? start_ptr : buf; beg <= buf + size; beg++)
     {
-      size_t offset = kwsexec (kwset, beg, buf + size - beg, &kwsmatch);
+      size_t offset = kwsexec (kwset, beg - match_lines,
+                               buf + size - beg + match_lines, &kwsmatch);
       if (offset == (size_t) -1)
         goto failure;
-      len = kwsmatch.size[0];
-      if (MB_CUR_MAX > 1
-          && is_mb_middle (&mb_start, beg + offset, buf + size, len))
+      len = kwsmatch.size[0] - match_lines;
+      if (!match_lines && MB_CUR_MAX > 1 && !using_utf8 ()
+          && mb_goback (&mb_start, beg + offset, buf + size) != 0)
         {
           /* The match was a part of multibyte character, advance at least
              one byte to ensure no infinite loop happens.  */
-          mbstate_t s;
-          memset (&s, 0, sizeof s);
-          size_t mb_len = mbrlen (mb_start, (buf + size) - (beg + offset), &s);
-          if (mb_len == (size_t) -2 || mb_len == (size_t) -1)
-            goto failure;
-          beg = mb_start + mb_len - 1;
+          beg = mb_start;
           continue;
         }
       beg += offset;
       if (start_ptr && !match_words)
         goto success_in_beg_and_len;
       if (match_lines)
-        {
-          if (beg > buf && beg[-1] != eol)
-            continue;
-          if (beg + len < buf + size && beg[len] != eol)
-            continue;
-          goto success;
-        }
-      else if (match_words)
+        goto success_in_beg_and_len;
+      if (match_words)
         for (try = beg; ; )
           {
-            if (try > buf && WCHAR((unsigned char) try[-1]))
+            if (wordchar (mb_prev_wc (buf, try, buf + size)))
               break;
-            if (try + len < buf + size && WCHAR((unsigned char) try[len]))
+            if (wordchar (mb_next_wc (try + len, buf + size)))
               {
                 if (!len)
                   break;
index 901e122..6d21893 100644 (file)
 
 /* The algorithm implemented by these routines bears a startling resemblance
    to one discovered by Beate Commentz-Walter, although it is not identical.
-   See "A String Matching Algorithm Fast on the Average," Technical Report,
-   IBM-Germany, Scientific Center Heidelberg, Tiergartenstrasse 15, D-6900
-   Heidelberg, Germany.  See also Aho, A.V., and M. Corasick, "Efficient
-   String Matching:  An Aid to Bibliographic Search," CACM June 1975,
-   Vol. 18, No. 6, which describes the failure function used below. */
+   See: Commentz-Walter B. A string matching algorithm fast on the average.
+   Lecture Notes in Computer Science 71 (1979), 118-32
+   <http://dx.doi.org/10.1007/3-540-09510-1_10>.
+   See also: Aho AV, Corasick MJ. Efficient string matching: an aid to
+   bibliographic search. CACM 18, 6 (1975), 333-40
+   <http://dx.doi.org/10.1145/360825.360855>, which describes the
+   failure function used below. */
 
 #include <config.h>
+
+#include "kwset.h"
+
+#include <stdbool.h>
+#include <stdint.h>
 #include <sys/types.h>
 #include "system.h"
-#include "kwset.h"
+#include "memchr2.h"
 #include "obstack.h"
+#include "xalloc.h"
 
 #define link kwset_link
 
@@ -47,7 +55,7 @@
 #define obstack_chunk_alloc malloc
 #define obstack_chunk_free free
 
-#define U(c) ((unsigned char) (c))
+#define U(c) (to_uchar (c))
 
 /* Balanced tree of edges and labels leaving a given trie node. */
 struct tree
@@ -83,30 +91,45 @@ struct kwset
   unsigned char delta[NCHAR];  /* Delta table for rapid search. */
   struct trie *next[NCHAR];    /* Table of children of the root. */
   char *target;                        /* Target string if there's only one. */
-  int mind2;                   /* Used in Boyer-Moore search for one string. */
+  int *shift;                  /* Used in Boyer-Moore search for one string. */
   char const *trans;           /* Character translation table. */
+
+  /* If there's only one string, this is the string's last byte,
+     translated via TRANS if TRANS is nonnull.  */
+  char gc1;
+
+  /* Likewise for the string's penultimate byte, if it has two or more
+     bytes.  */
+  char gc2;
+
+  /* If there's only one string, this helps to match the string's last byte.
+     If GC1HELP is negative, only GC1 matches the string's last byte;
+     otherwise at least two bytes match, and B matches if TRANS[B] == GC1.
+     If GC1HELP is in the range 0..(NCHAR - 1), there are exactly two
+     such matches, and GC1HELP is the other match after conversion to
+     unsigned char.  If GC1HELP is at least NCHAR, there are three or
+     more such matches; e.g., Greek has three sigma characters that
+     all match when case-folding.  */
+  int gc1help;
 };
 
+/* Use TRANS to transliterate C.  A null TRANS does no transliteration.  */
+static inline char
+tr (char const *trans, char c)
+{
+  return trans ? trans[U(c)] : c;
+}
+
 /* Allocate and initialize a keyword set object, returning an opaque
-   pointer to it.  Return NULL if memory is not available. */
+   pointer to it.  */
 kwset_t
 kwsalloc (char const *trans)
 {
-  struct kwset *kwset;
-
-  kwset = (struct kwset *) malloc(sizeof (struct kwset));
-  if (!kwset)
-    return NULL;
+  struct kwset *kwset = xmalloc (sizeof *kwset);
 
-  obstack_init(&kwset->obstack);
+  obstack_init (&kwset->obstack);
   kwset->words = 0;
-  kwset->trie
-    = (struct trie *) obstack_alloc(&kwset->obstack, sizeof (struct trie));
-  if (!kwset->trie)
-    {
-      kwsfree((kwset_t) kwset);
-      return NULL;
-    }
+  kwset->trie = obstack_alloc (&kwset->obstack, sizeof *kwset->trie);
   kwset->trie->accepting = 0;
   kwset->trie->links = NULL;
   kwset->trie->parent = NULL;
@@ -119,44 +142,38 @@ kwsalloc (char const *trans)
   kwset->target = NULL;
   kwset->trans = trans;
 
-  return (kwset_t) kwset;
+  return kwset;
 }
 
 /* This upper bound is valid for CHAR_BIT >= 4 and
    exact for CHAR_BIT in { 4..11, 13, 15, 17, 19 }. */
 #define DEPTH_SIZE (CHAR_BIT + CHAR_BIT/2)
 
-/* Add the given string to the contents of the keyword set.  Return NULL
-   for success, an error message otherwise. */
-const char *
-kwsincr (kwset_t kws, char const *text, size_t len)
+/* Add the given string to the contents of the keyword set.  */
+void
+kwsincr (kwset_t kwset, char const *text, size_t len)
 {
-  struct kwset *kwset;
-  struct trie *trie;
-  unsigned char label;
-  struct tree *link;
-  int depth;
-  struct tree *links[DEPTH_SIZE];
-  enum { L, R } dirs[DEPTH_SIZE];
-  struct tree *t, *r, *l, *rl, *lr;
+  struct trie *trie = kwset->trie;
+  char const *trans = kwset->trans;
 
-  kwset = (struct kwset *) kws;
-  trie = kwset->trie;
   text += len;
 
   /* Descend the trie (built of reversed keywords) character-by-character,
      installing new nodes when necessary. */
   while (len--)
     {
-      label = kwset->trans ? kwset->trans[U(*--text)] : *--text;
+      unsigned char uc = *--text;
+      unsigned char label = trans ? trans[uc] : uc;
 
       /* Descend the tree of outgoing links for this trie node,
          looking for the current character and keeping track
          of the path followed. */
-      link = trie->links;
+      struct tree *link = trie->links;
+      struct tree *links[DEPTH_SIZE];
+      enum { L, R } dirs[DEPTH_SIZE];
       links[0] = (struct tree *) &trie->links;
       dirs[0] = L;
-      depth = 1;
+      int depth = 1;
 
       while (link && label != link->label)
         {
@@ -172,19 +189,10 @@ kwsincr (kwset_t kws, char const *text, size_t len)
          a link in the current trie node's tree. */
       if (!link)
         {
-          link = (struct tree *) obstack_alloc(&kwset->obstack,
-                                               sizeof (struct tree));
-          if (!link)
-            return _("memory exhausted");
+          link = obstack_alloc (&kwset->obstack, sizeof *link);
           link->llink = NULL;
           link->rlink = NULL;
-          link->trie = (struct trie *) obstack_alloc(&kwset->obstack,
-                                                     sizeof (struct trie));
-          if (!link->trie)
-            {
-              obstack_free(&kwset->obstack, link);
-              return _("memory exhausted");
-            }
+          link->trie = obstack_alloc (&kwset->obstack, sizeof *link->trie);
           link->trie->accepting = 0;
           link->trie->links = NULL;
           link->trie->parent = trie;
@@ -215,6 +223,8 @@ kwsincr (kwset_t kws, char const *text, size_t len)
           if (depth && ((dirs[depth] == L && --links[depth]->balance)
                         || (dirs[depth] == R && ++links[depth]->balance)))
             {
+              struct tree *t, *r, *l, *rl, *lr;
+
               switch (links[depth]->balance)
                 {
                 case (char) -2:
@@ -282,8 +292,6 @@ kwsincr (kwset_t kws, char const *text, size_t len)
     kwset->mind = trie->depth;
   if (trie->depth > kwset->maxd)
     kwset->maxd = trie->depth;
-
-  return NULL;
 }
 
 /* Enqueue the trie nodes referenced from the given tree in the
@@ -381,132 +389,210 @@ treenext (struct tree const *tree, struct trie *next[])
 
 /* Compute the shift for each trie node, as well as the delta
    table and next cache for the given keyword set. */
-const char *
-kwsprep (kwset_t kws)
+void
+kwsprep (kwset_t kwset)
 {
-  struct kwset *kwset;
+  char const *trans = kwset->trans;
   int i;
-  struct trie *curr;
-  char const *trans;
-  unsigned char delta[NCHAR];
-
-  kwset = (struct kwset *) kws;
+  unsigned char deltabuf[NCHAR];
+  unsigned char *delta = trans ? deltabuf : kwset->delta;
 
   /* Initial values for the delta table; will be changed later.  The
      delta entry for a given character is the smallest depth of any
      node at which an outgoing edge is labeled by that character. */
-  memset(delta, kwset->mind < UCHAR_MAX ? kwset->mind : UCHAR_MAX, NCHAR);
+  memset (delta, MIN (kwset->mind, UCHAR_MAX), sizeof deltabuf);
+
+  /* Traverse the nodes of the trie in level order, simultaneously
+     computing the delta table, failure function, and shift function.  */
+  struct trie *curr, *last;
+  for (curr = last = kwset->trie; curr; curr = curr->next)
+    {
+      /* Enqueue the immediate descendants in the level order queue.  */
+      enqueue (curr->links, &last);
+
+      curr->shift = kwset->mind;
+      curr->maxshift = kwset->mind;
+
+      /* Update the delta table for the descendants of this node.  */
+      treedelta (curr->links, curr->depth, delta);
+
+      /* Compute the failure function for the descendants of this node.  */
+      treefails (curr->links, curr->fail, kwset->trie);
+
+      /* Update the shifts at each node in the current node's chain
+         of fails back to the root.  */
+      struct trie *fail;
+      for (fail = curr->fail; fail; fail = fail->fail)
+        {
+          /* If the current node has some outgoing edge that the fail
+             doesn't, then the shift at the fail should be no larger
+             than the difference of their depths.  */
+          if (!hasevery (fail->links, curr->links))
+            if (curr->depth - fail->depth < fail->shift)
+              fail->shift = curr->depth - fail->depth;
+
+          /* If the current node is accepting then the shift at the
+             fail and its descendants should be no larger than the
+             difference of their depths.  */
+          if (curr->accepting && fail->maxshift > curr->depth - fail->depth)
+            fail->maxshift = curr->depth - fail->depth;
+        }
+    }
+
+  /* Traverse the trie in level order again, fixing up all nodes whose
+     shift exceeds their inherited maxshift.  */
+  for (curr = kwset->trie->next; curr; curr = curr->next)
+    {
+      if (curr->maxshift > curr->parent->maxshift)
+        curr->maxshift = curr->parent->maxshift;
+      if (curr->shift > curr->maxshift)
+        curr->shift = curr->maxshift;
+    }
+
+  /* Create a vector, indexed by character code, of the outgoing links
+     from the root node.  */
+  struct trie *nextbuf[NCHAR];
+  struct trie **next = trans ? nextbuf : kwset->next;
+  memset (next, 0, sizeof nextbuf);
+  treenext (kwset->trie->links, next);
+  if (trans)
+    for (i = 0; i < NCHAR; ++i)
+      kwset->next[i] = next[U(trans[i])];
 
   /* Check if we can use the simple boyer-moore algorithm, instead
      of the hairy commentz-walter algorithm. */
-  if (kwset->words == 1 && kwset->trans == NULL)
+  if (kwset->words == 1)
     {
-      char c;
-
       /* Looking for just one string.  Extract it from the trie. */
-      kwset->target = obstack_alloc(&kwset->obstack, kwset->mind);
-      if (!kwset->target)
-        return _("memory exhausted");
+      kwset->target = obstack_alloc (&kwset->obstack, kwset->mind);
       for (i = kwset->mind - 1, curr = kwset->trie; i >= 0; --i)
         {
           kwset->target[i] = curr->links->label;
-          curr = curr->links->trie;
+          curr = curr->next;
         }
-      /* Build the Boyer Moore delta.  Boy that's easy compared to CW. */
-      for (i = 0; i < kwset->mind; ++i)
-        delta[U(kwset->target[i])] = kwset->mind - (i + 1);
-      /* Find the minimal delta2 shift that we might make after
-         a backwards match has failed. */
-      c = kwset->target[kwset->mind - 1];
-      for (i = kwset->mind - 2; i >= 0; --i)
-        if (kwset->target[i] == c)
-          break;
-      kwset->mind2 = kwset->mind - (i + 1);
-    }
-  else
-    {
-      struct trie *fail;
-      struct trie *last, *next[NCHAR];
+      /* Looking for the delta2 shift that we might make after a
+         backwards match has failed.  Extract it from the trie.  */
+      if (kwset->mind > 1)
+        {
+          kwset->shift
+            = obstack_alloc (&kwset->obstack,
+                             sizeof *kwset->shift * (kwset->mind - 1));
+          for (i = 0, curr = kwset->trie->next; i < kwset->mind - 1; ++i)
+            {
+              kwset->shift[i] = curr->shift;
+              curr = curr->next;
+            }
+        }
+
+      char gc1 = tr (trans, kwset->target[kwset->mind - 1]);
 
-      /* Traverse the nodes of the trie in level order, simultaneously
-         computing the delta table, failure function, and shift function. */
-      for (curr = last = kwset->trie; curr; curr = curr->next)
+      /* Set GC1HELP according to whether exactly one, exactly two, or
+         three-or-more characters match GC1.  */
+      int gc1help = -1;
+      if (trans)
         {
-          /* Enqueue the immediate descendants in the level order queue. */
-          enqueue(curr->links, &last);
+          char const *equiv1 = memchr (trans, gc1, NCHAR);
+          char const *equiv2 = memchr (equiv1 + 1, gc1,
+                                       trans + NCHAR - (equiv1 + 1));
+          if (equiv2)
+            gc1help = (memchr (equiv2 + 1, gc1, trans + NCHAR - (equiv2 + 1))
+                       ? NCHAR
+                       : U(gc1) ^ (equiv1 - trans) ^ (equiv2 - trans));
+        }
 
-          curr->shift = kwset->mind;
-          curr->maxshift = kwset->mind;
+      kwset->gc1 = gc1;
+      kwset->gc1help = gc1help;
+      if (kwset->mind > 1)
+        kwset->gc2 = tr (trans, kwset->target[kwset->mind - 2]);
+    }
 
-          /* Update the delta table for the descendants of this node. */
-          treedelta(curr->links, curr->depth, delta);
+  /* Fix things up for any translation table. */
+  if (trans)
+    for (i = 0; i < NCHAR; ++i)
+      kwset->delta[i] = delta[U(trans[i])];
+}
 
-          /* Compute the failure function for the descendants of this node.  */
-          treefails(curr->links, curr->fail, kwset->trie);
+/* Delta2 portion of a Boyer-Moore search.  *TP is the string text
+   pointer; it is updated in place.  EP is the end of the string text,
+   and SP the end of the pattern.  LEN is the pattern length; it must
+   be at least 2.  TRANS, if nonnull, is the input translation table.
+   GC1 and GC2 are the last and second-from last bytes of the pattern,
+   transliterated by TRANS; the caller precomputes them for
+   efficiency.  If D1 is nonnull, it is a delta1 table for shifting *TP
+   when failing.  KWSET->shift says how much to shift.  */
+static inline bool
+bm_delta2_search (char const **tpp, char const *ep, char const *sp, int len,
+                  char const *trans, char gc1, char gc2,
+                  unsigned char const *d1, kwset_t kwset)
+{
+  char const *tp = *tpp;
+  int d = len, skip = 0;
 
-          /* Update the shifts at each node in the current node's chain
-             of fails back to the root. */
-          for (fail = curr->fail; fail; fail = fail->fail)
+  while (true)
+    {
+      int i = 2;
+      if (tr (trans, tp[-2]) == gc2)
+        {
+          while (++i <= d)
+            if (tr (trans, tp[-i]) != tr (trans, sp[-i]))
+              break;
+          if (i > d)
             {
-              /* If the current node has some outgoing edge that the fail
-                 doesn't, then the shift at the fail should be no larger
-                 than the difference of their depths. */
-              if (!hasevery(fail->links, curr->links))
-                if (curr->depth - fail->depth < fail->shift)
-                  fail->shift = curr->depth - fail->depth;
-
-              /* If the current node is accepting then the shift at the
-                 fail and its descendants should be no larger than the
-                 difference of their depths. */
-              if (curr->accepting && fail->maxshift > curr->depth - fail->depth)
-                fail->maxshift = curr->depth - fail->depth;
+              for (i = d + skip + 1; i <= len; ++i)
+                if (tr (trans, tp[-i]) != tr (trans, sp[-i]))
+                  break;
+              if (i > len)
+                {
+                  *tpp = tp - len;
+                  return true;
+                }
             }
         }
 
-      /* Traverse the trie in level order again, fixing up all nodes whose
-         shift exceeds their inherited maxshift. */
-      for (curr = kwset->trie->next; curr; curr = curr->next)
+      tp += d = kwset->shift[i - 2];
+      if (tp > ep)
+        break;
+      if (tr (trans, tp[-1]) != gc1)
         {
-          if (curr->maxshift > curr->parent->maxshift)
-            curr->maxshift = curr->parent->maxshift;
-          if (curr->shift > curr->maxshift)
-            curr->shift = curr->maxshift;
+          if (d1)
+            tp += d1[U(tp[-1])];
+          break;
         }
-
-      /* Create a vector, indexed by character code, of the outgoing links
-         from the root node. */
-      for (i = 0; i < NCHAR; ++i)
-        next[i] = NULL;
-      treenext(kwset->trie->links, next);
-
-      if ((trans = kwset->trans) != NULL)
-        for (i = 0; i < NCHAR; ++i)
-          kwset->next[i] = next[U(trans[i])];
-      else
-        memcpy(kwset->next, next, NCHAR * sizeof(struct trie *));
+      skip = i - 1;
     }
 
-  /* Fix things up for any translation table. */
-  if ((trans = kwset->trans) != NULL)
-    for (i = 0; i < NCHAR; ++i)
-      kwset->delta[i] = delta[U(trans[i])];
-  else
-    memcpy(kwset->delta, delta, NCHAR);
+  *tpp = tp;
+  return false;
+}
 
-  return NULL;
+/* Return the address of the first byte in the buffer S (of size N)
+   that matches the last byte specified by KWSET, a singleton.  */
+static char const *
+memchr_kwset (char const *s, size_t n, kwset_t kwset)
+{
+  if (kwset->gc1help < 0)
+    return memchr (s, kwset->gc1, n);
+  int small_heuristic = 2;
+  int small = (- (uintptr_t) s % sizeof (long)
+               + small_heuristic * sizeof (long));
+  size_t ntrans = kwset->gc1help < NCHAR && small < n ? small : n;
+  char const *slim = s + ntrans;
+  for (; s < slim; s++)
+    if (kwset->trans[U(*s)] == kwset->gc1)
+      return s;
+  n -= ntrans;
+  return n == 0 ? NULL : memchr2 (s, kwset->gc1, kwset->gc1help, n);
 }
 
-/* Fast boyer-moore search. */
-static size_t _GL_ATTRIBUTE_PURE
-bmexec (kwset_t kws, char const *text, size_t size)
+/* Fast Boyer-Moore search (inlinable version).  */
+static inline size_t _GL_ATTRIBUTE_PURE
+bmexec_trans (kwset_t kwset, char const *text, size_t size)
 {
-  struct kwset const *kwset;
   unsigned char const *d1;
   char const *ep, *sp, *tp;
-  int d, gc, i, len, md2;
-
-  kwset = (struct kwset const *) kws;
-  len = kwset->mind;
+  int d;
+  int len = kwset->mind;
+  char const *trans = kwset->trans;
 
   if (len == 0)
     return 0;
@@ -514,50 +600,55 @@ bmexec (kwset_t kws, char const *text, size_t size)
     return -1;
   if (len == 1)
     {
-      tp = memchr (text, kwset->target[0], size);
+      tp = memchr_kwset (text, size, kwset);
       return tp ? tp - text : -1;
     }
 
   d1 = kwset->delta;
   sp = kwset->target + len;
-  gc = U(sp[-2]);
-  md2 = kwset->mind2;
   tp = text + len;
+  char gc1 = kwset->gc1;
+  char gc2 = kwset->gc2;
 
   /* Significance of 12: 1 (initial offset) + 10 (skip loop) + 1 (md2). */
   if (size > 12 * len)
     /* 11 is not a bug, the initial offset happens only once. */
-    for (ep = text + size - 11 * len;;)
+    for (ep = text + size - 11 * len; tp <= ep; )
       {
-        while (tp <= ep)
+        char const *tp0 = tp;
+        d = d1[U(tp[-1])], tp += d;
+        d = d1[U(tp[-1])], tp += d;
+        if (d != 0)
           {
             d = d1[U(tp[-1])], tp += d;
             d = d1[U(tp[-1])], tp += d;
-            if (d == 0)
-              goto found;
-            d = d1[U(tp[-1])], tp += d;
-            d = d1[U(tp[-1])], tp += d;
-            d = d1[U(tp[-1])], tp += d;
-            if (d == 0)
-              goto found;
-            d = d1[U(tp[-1])], tp += d;
-            d = d1[U(tp[-1])], tp += d;
-            d = d1[U(tp[-1])], tp += d;
-            if (d == 0)
-              goto found;
-            d = d1[U(tp[-1])], tp += d;
             d = d1[U(tp[-1])], tp += d;
+            if (d != 0)
+              {
+                d = d1[U(tp[-1])], tp += d;
+                d = d1[U(tp[-1])], tp += d;
+                d = d1[U(tp[-1])], tp += d;
+                if (d != 0)
+                  {
+                    d = d1[U(tp[-1])], tp += d;
+                    d = d1[U(tp[-1])], tp += d;
+
+                    /* As a heuristic, prefer memchr to seeking by
+                       delta1 when the latter doesn't advance much.  */
+                    int advance_heuristic = 16 * sizeof (long);
+                    if (advance_heuristic <= tp - tp0)
+                      goto big_advance;
+                    tp--;
+                    tp = memchr_kwset (tp, text + size - tp, kwset);
+                    if (! tp)
+                      return -1;
+                    tp++;
+                  }
+              }
           }
-        break;
-      found:
-        if (U(tp[-2]) == gc)
-          {
-            for (i = 3; i <= len && U(tp[-i]) == U(sp[-i]); ++i)
-              ;
-            if (i > len)
-              return tp - len - text;
-          }
-        tp += md2;
+        if (bm_delta2_search (&tp, ep, sp, len, trans, gc1, gc2, d1, kwset))
+          return tp - text;
+      big_advance:;
       }
 
   /* Now we have only a few characters left to search.  We
@@ -569,24 +660,28 @@ bmexec (kwset_t kws, char const *text, size_t size)
       d = d1[U((tp += d)[-1])];
       if (d != 0)
         continue;
-      if (U(tp[-2]) == gc)
-        {
-          for (i = 3; i <= len && U(tp[-i]) == U(sp[-i]); ++i)
-            ;
-          if (i > len)
-            return tp - len - text;
-        }
-      d = md2;
+      if (bm_delta2_search (&tp, ep, sp, len, trans, gc1, gc2, NULL, kwset))
+        return tp - text;
     }
 
   return -1;
 }
 
+/* Fast Boyer-Moore search.  */
+static size_t
+bmexec (kwset_t kwset, char const *text, size_t size)
+{
+  /* Help the compiler inline bmexec_trans in two ways, depending on
+     whether kwset->trans is null.  */
+  return (kwset->trans
+          ? bmexec_trans (kwset, text, size)
+          : bmexec_trans (kwset, text, size));
+}
+
 /* Hairy multiple string search. */
 static size_t _GL_ARG_NONNULL ((4))
-cwexec (kwset_t kws, char const *text, size_t len, struct kwsmatch *kwsmatch)
+cwexec (kwset_t kwset, char const *text, size_t len, struct kwsmatch *kwsmatch)
 {
-  struct kwset const *kwset;
   struct trie * const *next;
   struct trie const *trie;
   struct trie const *accept;
@@ -603,7 +698,6 @@ cwexec (kwset_t kws, char const *text, size_t len, struct kwsmatch *kwsmatch)
 #endif
 
   /* Initialize register copies and look for easy ways out. */
-  kwset = (struct kwset *) kws;
   if (len < kwset->mind)
     return -1;
   next = kwset->next;
@@ -651,7 +745,8 @@ cwexec (kwset_t kws, char const *text, size_t len, struct kwsmatch *kwsmatch)
       d = trie->shift;
       while (beg > text)
         {
-          c = trans ? trans[U(*--beg)] : *--beg;
+          unsigned char uc = *--beg;
+          c = trans ? trans[uc] : uc;
           tree = trie->links;
           while (tree && c != tree->label)
             if (c < tree->label)
@@ -702,7 +797,8 @@ cwexec (kwset_t kws, char const *text, size_t len, struct kwsmatch *kwsmatch)
       d = trie->shift;
       while (beg > text)
         {
-          c = trans ? trans[U(*--beg)] : *--beg;
+          unsigned char uc = *--beg;
+          c = trans ? trans[uc] : uc;
           tree = trie->links;
           while (tree && c != tree->label)
             if (c < tree->label)
@@ -738,18 +834,18 @@ cwexec (kwset_t kws, char const *text, size_t len, struct kwsmatch *kwsmatch)
   return mch - text;
 }
 
-/* Search TEXT for a match of any member of the keyword set, KWS.
+/* Search TEXT for a match of any member of KWSET.
    Return the offset (into TEXT) of the first byte of the matching substring,
    or (size_t) -1 if no match is found.  Upon a match, store details in
    *KWSMATCH: index of matched keyword, start offset (same as the return
    value), and length.  */
 size_t
-kwsexec (kwset_t kws, char const *text, size_t size, struct kwsmatch *kwsmatch)
+kwsexec (kwset_t kwset, char const *text, size_t size,
+         struct kwsmatch *kwsmatch)
 {
-  struct kwset const *kwset = (struct kwset *) kws;
-  if (kwset->words == 1 && kwset->trans == NULL)
+  if (kwset->words == 1)
     {
-      size_t ret = bmexec (kws, text, size);
+      size_t ret = bmexec (kwset, text, size);
       if (ret != (size_t) -1)
         {
           kwsmatch->index = 0;
@@ -759,16 +855,13 @@ kwsexec (kwset_t kws, char const *text, size_t size, struct kwsmatch *kwsmatch)
       return ret;
     }
   else
-    return cwexec(kws, text, size, kwsmatch);
+    return cwexec (kwset, text, size, kwsmatch);
 }
 
 /* Free the components of the given keyword set. */
 void
-kwsfree (kwset_t kws)
+kwsfree (kwset_t kwset)
 {
-  struct kwset *kwset;
-
-  kwset = (struct kwset *) kws;
-  obstack_free(&kwset->obstack, NULL);
-  free(kws);
+  obstack_free (&kwset->obstack, NULL);
+  free (kwset);
 }
index 2d3cdd9..12afb8e 100644 (file)
@@ -21,6 +21,8 @@
    The author may be reached (Email) at the address mike@ai.mit.edu,
    or (US mail) as Mike Haertel c/o Free Software Foundation. */
 
+#include <stddef.h>
+
 struct kwsmatch
 {
   size_t index;                        /* Index number of matching keyword. */
@@ -33,20 +35,17 @@ struct kwsmatch
 struct kwset;
 typedef struct kwset *kwset_t;
 
-/* Return an opaque pointer to a newly allocated keyword set, or NULL
-   if enough memory cannot be obtained.  The argument if non-NULL
+/* Return an opaque pointer to a newly allocated keyword set.  A nonnull arg
    specifies a table of character translations to be applied to all
-   pattern and search text. */
+   pattern and search text.  */
 extern kwset_t kwsalloc (char const *);
 
 /* Incrementally extend the keyword set to include the given string.
-   Return NULL for success, or an error message.  Remember an index
-   number for each keyword included in the set. */
-extern const char *kwsincr (kwset_t, char const *, size_t);
+   Remember an index number for each keyword included in the set.  */
+extern void kwsincr (kwset_t, char const *, size_t);
 
-/* When the keyword set has been completely built, prepare it for
-   use.  Return NULL for success, or an error message. */
-extern const char *kwsprep (kwset_t);
+/* When the keyword set has been completely built, prepare it for use.  */
+extern void kwsprep (kwset_t);
 
 /* Search through the given buffer for a member of the keyword set.
    Return a pointer to the leftmost longest match found, or NULL if
diff --git a/src/main.c b/src/main.c
deleted file mode 100644 (file)
index 44090be..0000000
+++ /dev/null
@@ -1,2304 +0,0 @@
-/* grep.c - main driver file for grep.
-   Copyright (C) 1992, 1997-2002, 2004-2014 Free Software Foundation, Inc.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3, or (at your option)
-   any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
-   02110-1301, USA.  */
-
-/* Written July 1992 by Mike Haertel.  */
-
-#include <config.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include "mbsupport.h"
-#include <wchar.h>
-#include <wctype.h>
-#include <fcntl.h>
-#include <inttypes.h>
-#include <stdio.h>
-#include "system.h"
-
-#include "argmatch.h"
-#include "c-ctype.h"
-#include "closeout.h"
-#include "colorize.h"
-#include "error.h"
-#include "exclude.h"
-#include "exitfail.h"
-#include "fcntl-safer.h"
-#include "fts_.h"
-#include "getopt.h"
-#include "grep.h"
-#include "intprops.h"
-#include "progname.h"
-#include "propername.h"
-#include "quote.h"
-#include "safe-read.h"
-#include "version-etc.h"
-#include "xalloc.h"
-#include "xstrtol.h"
-
-#define SEP_CHAR_SELECTED ':'
-#define SEP_CHAR_REJECTED '-'
-#define SEP_STR_GROUP    "--"
-
-#define AUTHORS \
-  proper_name ("Mike Haertel"), \
-  _("others, see <http://git.sv.gnu.org/cgit/grep.git/tree/AUTHORS>")
-
-/* When stdout is connected to a regular file, save its stat
-   information here, so that we can automatically skip it, thus
-   avoiding a potential (racy) infinite loop.  */
-static struct stat out_stat;
-
-/* if non-zero, display usage information and exit */
-static int show_help;
-
-/* If non-zero, print the version on standard output and exit.  */
-static int show_version;
-
-/* If nonzero, suppress diagnostics for nonexistent or unreadable files.  */
-static int suppress_errors;
-
-/* If nonzero, use color markers.  */
-static int color_option;
-
-/* If nonzero, show only the part of a line matching the expression. */
-static int only_matching;
-
-/* If nonzero, make sure first content char in a line is on a tab stop. */
-static int align_tabs;
-
-/* The group separator used when context is requested. */
-static const char *group_separator = SEP_STR_GROUP;
-
-/* The context and logic for choosing default --color screen attributes
-   (foreground and background colors, etc.) are the following.
-      -- There are eight basic colors available, each with its own
-         nominal luminosity to the human eye and foreground/background
-         codes (black [0 %, 30/40], blue [11 %, 34/44], red [30 %, 31/41],
-         magenta [41 %, 35/45], green [59 %, 32/42], cyan [70 %, 36/46],
-         yellow [89 %, 33/43], and white [100 %, 37/47]).
-      -- Sometimes, white as a background is actually implemented using
-         a shade of light gray, so that a foreground white can be visible
-         on top of it (but most often not).
-      -- Sometimes, black as a foreground is actually implemented using
-         a shade of dark gray, so that it can be visible on top of a
-         background black (but most often not).
-      -- Sometimes, more colors are available, as extensions.
-      -- Other attributes can be selected/deselected (bold [1/22],
-         underline [4/24], standout/inverse [7/27], blink [5/25], and
-         invisible/hidden [8/28]).  They are sometimes implemented by
-         using colors instead of what their names imply; e.g., bold is
-         often achieved by using brighter colors.  In practice, only bold
-         is really available to us, underline sometimes being mapped by
-         the terminal to some strange color choice, and standout best
-         being left for use by downstream programs such as less(1).
-      -- We cannot assume that any of the extensions or special features
-         are available for the purpose of choosing defaults for everyone.
-      -- The most prevalent default terminal backgrounds are pure black
-         and pure white, and are not necessarily the same shades of
-         those as if they were selected explicitly with SGR sequences.
-         Some terminals use dark or light pictures as default background,
-         but those are covered over by an explicit selection of background
-         color with an SGR sequence; their users will appreciate their
-         background pictures not be covered like this, if possible.
-      -- Some uses of colors attributes is to make some output items
-         more understated (e.g., context lines); this cannot be achieved
-         by changing the background color.
-      -- For these reasons, the grep color defaults should strive not
-         to change the background color from its default, unless it's
-         for a short item that should be highlighted, not understated.
-      -- The grep foreground color defaults (without an explicitly set
-         background) should provide enough contrast to be readable on any
-         terminal with either a black (dark) or white (light) background.
-         This only leaves red, magenta, green, and cyan (and their bold
-         counterparts) and possibly bold blue.  */
-/* The color strings used for matched text.
-   The user can overwrite them using the deprecated
-   environment variable GREP_COLOR or the new GREP_COLORS.  */
-static const char *selected_match_color = "01;31";     /* bold red */
-static const char *context_match_color  = "01;31";     /* bold red */
-
-/* Other colors.  Defaults look damn good.  */
-static const char *filename_color = "35";      /* magenta */
-static const char *line_num_color = "32";      /* green */
-static const char *byte_num_color = "32";      /* green */
-static const char *sep_color      = "36";      /* cyan */
-static const char *selected_line_color = "";   /* default color pair */
-static const char *context_line_color  = "";   /* default color pair */
-
-/* Select Graphic Rendition (SGR, "\33[...m") strings.  */
-/* Also Erase in Line (EL) to Right ("\33[K") by default.  */
-/*    Why have EL to Right after SGR?
-         -- The behavior of line-wrapping when at the bottom of the
-            terminal screen and at the end of the current line is often
-            such that a new line is introduced, entirely cleared with
-            the current background color which may be different from the
-            default one (see the boolean back_color_erase terminfo(5)
-            capability), thus scrolling the display by one line.
-            The end of this new line will stay in this background color
-            even after reverting to the default background color with
-            "\33[m', unless it is explicitly cleared again with "\33[K"
-            (which is the behavior the user would instinctively expect
-            from the whole thing).  There may be some unavoidable
-            background-color flicker at the end of this new line because
-            of this (when timing with the monitor's redraw is just right).
-         -- The behavior of HT (tab, "\t") is usually the same as that of
-            Cursor Forward Tabulation (CHT) with a default parameter
-            of 1 ("\33[I"), i.e., it performs pure movement to the next
-            tab stop, without any clearing of either content or screen
-            attributes (including background color); try
-               printf 'asdfqwerzxcv\rASDF\tZXCV\n'
-            in a bash(1) shell to demonstrate this.  This is not what the
-            user would instinctively expect of HT (but is ok for CHT).
-            The instinctive behavior would include clearing the terminal
-            cells that are skipped over by HT with blank cells in the
-            current screen attributes, including background color;
-            the boolean dest_tabs_magic_smso terminfo(5) capability
-            indicates this saner behavior for HT, but only some rare
-            terminals have it (although it also indicates a special
-            glitch with standout mode in the Teleray terminal for which
-            it was initially introduced).  The remedy is to add "\33K"
-            after each SGR sequence, be it START (to fix the behavior
-            of any HT after that before another SGR) or END (to fix the
-            behavior of an HT in default background color that would
-            follow a line-wrapping at the bottom of the screen in another
-            background color, and to complement doing it after START).
-            Piping grep's output through a pager such as less(1) avoids
-            any HT problems since the pager performs tab expansion.
-
-      Generic disadvantages of this remedy are:
-         -- Some very rare terminals might support SGR but not EL (nobody
-            will use "grep --color" on a terminal that does not support
-            SGR in the first place).
-         -- Having these extra control sequences might somewhat complicate
-            the task of any program trying to parse "grep --color"
-            output in order to extract structuring information from it.
-      A specific disadvantage to doing it after SGR START is:
-         -- Even more possible background color flicker (when timing
-            with the monitor's redraw is just right), even when not at the
-            bottom of the screen.
-      There are no additional disadvantages specific to doing it after
-      SGR END.
-
-      It would be impractical for GNU grep to become a full-fledged
-      terminal program linked against ncurses or the like, so it will
-      not detect terminfo(5) capabilities.  */
-static const char *sgr_start = "\33[%sm\33[K";
-static const char *sgr_end   = "\33[m\33[K";
-
-/* SGR utility functions.  */
-static void
-pr_sgr_start (char const *s)
-{
-  if (*s)
-    print_start_colorize (sgr_start, s);
-}
-static void
-pr_sgr_end (char const *s)
-{
-  if (*s)
-    print_end_colorize (sgr_end);
-}
-static void
-pr_sgr_start_if (char const *s)
-{
-  if (color_option)
-    pr_sgr_start (s);
-}
-static void
-pr_sgr_end_if (char const *s)
-{
-  if (color_option)
-    pr_sgr_end (s);
-}
-
-struct color_cap
-  {
-    const char *name;
-    const char **var;
-    void (*fct) (void);
-  };
-
-static void
-color_cap_mt_fct (void)
-{
-  /* Our caller just set selected_match_color.  */
-  context_match_color = selected_match_color;
-}
-
-static void
-color_cap_rv_fct (void)
-{
-  /* By this point, it was 1 (or already -1).  */
-  color_option = -1;  /* That's still != 0.  */
-}
-
-static void
-color_cap_ne_fct (void)
-{
-  sgr_start = "\33[%sm";
-  sgr_end   = "\33[m";
-}
-
-/* For GREP_COLORS.  */
-static const struct color_cap color_dict[] =
-  {
-    { "mt", &selected_match_color, color_cap_mt_fct }, /* both ms/mc */
-    { "ms", &selected_match_color, NULL }, /* selected matched text */
-    { "mc", &context_match_color,  NULL }, /* context matched text */
-    { "fn", &filename_color,       NULL }, /* filename */
-    { "ln", &line_num_color,       NULL }, /* line number */
-    { "bn", &byte_num_color,       NULL }, /* byte (sic) offset */
-    { "se", &sep_color,            NULL }, /* separator */
-    { "sl", &selected_line_color,  NULL }, /* selected lines */
-    { "cx", &context_line_color,   NULL }, /* context lines */
-    { "rv", NULL,                  color_cap_rv_fct }, /* -v reverses sl/cx */
-    { "ne", NULL,                  color_cap_ne_fct }, /* no EL on SGR_* */
-    { NULL, NULL,                  NULL }
-  };
-
-static struct exclude *excluded_patterns;
-static struct exclude *excluded_directory_patterns;
-/* Short options.  */
-static char const short_options[] =
-"0123456789A:B:C:D:EFGHIPTUVX:abcd:e:f:hiLlm:noqRrsuvwxyZz";
-
-/* Non-boolean long options that have no corresponding short equivalents.  */
-enum
-{
-  BINARY_FILES_OPTION = CHAR_MAX + 1,
-  COLOR_OPTION,
-  INCLUDE_OPTION,
-  EXCLUDE_OPTION,
-  EXCLUDE_FROM_OPTION,
-  LINE_BUFFERED_OPTION,
-  LABEL_OPTION,
-  EXCLUDE_DIRECTORY_OPTION,
-  GROUP_SEPARATOR_OPTION,
-  MMAP_OPTION
-};
-
-/* Long options equivalences. */
-static struct option const long_options[] =
-{
-  {"basic-regexp",    no_argument, NULL, 'G'},
-  {"extended-regexp", no_argument, NULL, 'E'},
-  {"fixed-regexp",    no_argument, NULL, 'F'},
-  {"fixed-strings",   no_argument, NULL, 'F'},
-  {"perl-regexp",     no_argument, NULL, 'P'},
-  {"after-context", required_argument, NULL, 'A'},
-  {"before-context", required_argument, NULL, 'B'},
-  {"binary-files", required_argument, NULL, BINARY_FILES_OPTION},
-  {"byte-offset", no_argument, NULL, 'b'},
-  {"context", required_argument, NULL, 'C'},
-  {"color", optional_argument, NULL, COLOR_OPTION},
-  {"colour", optional_argument, NULL, COLOR_OPTION},
-  {"count", no_argument, NULL, 'c'},
-  {"devices", required_argument, NULL, 'D'},
-  {"directories", required_argument, NULL, 'd'},
-  {"exclude", required_argument, NULL, EXCLUDE_OPTION},
-  {"exclude-from", required_argument, NULL, EXCLUDE_FROM_OPTION},
-  {"exclude-dir", required_argument, NULL, EXCLUDE_DIRECTORY_OPTION},
-  {"file", required_argument, NULL, 'f'},
-  {"files-with-matches", no_argument, NULL, 'l'},
-  {"files-without-match", no_argument, NULL, 'L'},
-  {"group-separator", required_argument, NULL, GROUP_SEPARATOR_OPTION},
-  {"help", no_argument, &show_help, 1},
-  {"include", required_argument, NULL, INCLUDE_OPTION},
-  {"ignore-case", no_argument, NULL, 'i'},
-  {"initial-tab", no_argument, NULL, 'T'},
-  {"label", required_argument, NULL, LABEL_OPTION},
-  {"line-buffered", no_argument, NULL, LINE_BUFFERED_OPTION},
-  {"line-number", no_argument, NULL, 'n'},
-  {"line-regexp", no_argument, NULL, 'x'},
-  {"max-count", required_argument, NULL, 'm'},
-
-  /* FIXME: disabled in Mar 2010; warn towards end of 2011; remove in 2013.  */
-  {"mmap", no_argument, NULL, MMAP_OPTION},
-  {"no-filename", no_argument, NULL, 'h'},
-  {"no-group-separator", no_argument, NULL, GROUP_SEPARATOR_OPTION},
-  {"no-messages", no_argument, NULL, 's'},
-  {"null", no_argument, NULL, 'Z'},
-  {"null-data", no_argument, NULL, 'z'},
-  {"only-matching", no_argument, NULL, 'o'},
-  {"quiet", no_argument, NULL, 'q'},
-  {"recursive", no_argument, NULL, 'r'},
-  {"dereference-recursive", no_argument, NULL, 'R'},
-  {"regexp", required_argument, NULL, 'e'},
-  {"invert-match", no_argument, NULL, 'v'},
-  {"silent", no_argument, NULL, 'q'},
-  {"text", no_argument, NULL, 'a'},
-  {"binary", no_argument, NULL, 'U'},
-  {"unix-byte-offsets", no_argument, NULL, 'u'},
-  {"version", no_argument, NULL, 'V'},
-  {"with-filename", no_argument, NULL, 'H'},
-  {"word-regexp", no_argument, NULL, 'w'},
-  {0, 0, 0, 0}
-};
-
-/* Define flags declared in grep.h. */
-int match_icase;
-int match_words;
-int match_lines;
-unsigned char eolbyte;
-
-/* For error messages. */
-/* The input file name, or (if standard input) "-" or a --label argument.  */
-static char const *filename;
-static size_t filename_prefix_len;
-static int errseen;
-static int write_error_seen;
-
-enum directories_type
-  {
-    READ_DIRECTORIES = 2,
-    RECURSE_DIRECTORIES,
-    SKIP_DIRECTORIES
-  };
-
-/* How to handle directories.  */
-static char const *const directories_args[] =
-{
-  "read", "recurse", "skip", NULL
-};
-static enum directories_type const directories_types[] =
-{
-  READ_DIRECTORIES, RECURSE_DIRECTORIES, SKIP_DIRECTORIES
-};
-ARGMATCH_VERIFY (directories_args, directories_types);
-
-static enum directories_type directories = READ_DIRECTORIES;
-
-enum { basic_fts_options = FTS_CWDFD | FTS_NOSTAT | FTS_TIGHT_CYCLE_CHECK };
-static int fts_options = basic_fts_options | FTS_COMFOLLOW | FTS_PHYSICAL;
-
-/* How to handle devices. */
-static enum
-  {
-    READ_COMMAND_LINE_DEVICES,
-    READ_DEVICES,
-    SKIP_DEVICES
-  } devices = READ_COMMAND_LINE_DEVICES;
-
-static int grepfile (int, char const *, int, int);
-static int grepdesc (int, int);
-#if defined HAVE_DOS_FILE_CONTENTS
-static inline int undossify_input (char *, size_t);
-#endif
-
-static int
-is_device_mode (mode_t m)
-{
-  return S_ISCHR (m) || S_ISBLK (m) || S_ISSOCK (m) || S_ISFIFO (m);
-}
-
-/* Return nonzero if ST->st_size is defined.  Assume the file is not a
-   symbolic link.  */
-static int
-usable_st_size (struct stat const *st)
-{
-  return S_ISREG (st->st_mode) || S_TYPEISSHM (st) || S_TYPEISTMO (st);
-}
-
-/* Functions we'll use to search. */
-static compile_fp_t compile;
-static execute_fp_t execute;
-
-/* Like error, but suppress the diagnostic if requested.  */
-static void
-suppressible_error (char const *mesg, int errnum)
-{
-  if (! suppress_errors)
-    error (0, errnum, "%s", mesg);
-  errseen = 1;
-}
-
-/* If there has already been a write error, don't bother closing
-   standard output, as that might elicit a duplicate diagnostic.  */
-static void
-clean_up_stdout (void)
-{
-  if (! write_error_seen)
-    close_stdout ();
-}
-
-/* Return 1 if a file is known to be binary for the purpose of 'grep'.
-   BUF, of size BUFSIZE, is the initial buffer read from the file with
-   descriptor FD and status ST.  */
-static int
-file_is_binary (char const *buf, size_t bufsize, int fd, struct stat const *st)
-{
-  #ifndef SEEK_HOLE
-  enum { SEEK_HOLE = SEEK_END };
-  #endif
-
-  /* If -z, test only whether the initial buffer contains '\200';
-     knowing about holes won't help.  */
-  if (! eolbyte)
-    return memchr (buf, '\200', bufsize) != 0;
-
-  /* If the initial buffer contains a null byte, guess that the file
-     is binary.  */
-  if (memchr (buf, '\0', bufsize))
-    return 1;
-
-  /* If the file has holes, it must contain a null byte somewhere.  */
-  if (SEEK_HOLE != SEEK_END && usable_st_size (st))
-    {
-      off_t cur = bufsize;
-      if (O_BINARY || fd == STDIN_FILENO)
-        {
-          cur = lseek (fd, 0, SEEK_CUR);
-          if (cur < 0)
-            return 0;
-        }
-
-      /* Look for a hole after the current location.  */
-      off_t hole_start = lseek (fd, cur, SEEK_HOLE);
-      if (0 <= hole_start)
-        {
-          if (lseek (fd, cur, SEEK_SET) < 0)
-            suppressible_error (filename, errno);
-          if (hole_start < st->st_size)
-            return 1;
-        }
-    }
-
-  /* Guess that the file does not contain binary data.  */
-  return 0;
-}
-
-/* Convert STR to a nonnegative integer, storing the result in *OUT.
-   STR must be a valid context length argument; report an error if it
-   isn't.  Silently ceiling *OUT at the maximum value, as that is
-   practically equivalent to infinity for grep's purposes.  */
-static void
-context_length_arg (char const *str, intmax_t *out)
-{
-  switch (xstrtoimax (str, 0, 10, out, ""))
-    {
-    case LONGINT_OK:
-    case LONGINT_OVERFLOW:
-      if (0 <= *out)
-        break;
-      /* Fall through.  */
-    default:
-      error (EXIT_TROUBLE, 0, "%s: %s", str,
-             _("invalid context length argument"));
-    }
-}
-
-/* Return nonzero if the file with NAME should be skipped.
-   If COMMAND_LINE is nonzero, it is a command-line argument.
-   If IS_DIR is nonzero, it is a directory.  */
-static int
-skipped_file (char const *name, int command_line, int is_dir)
-{
-  return (is_dir
-          ? (directories == SKIP_DIRECTORIES
-             || (! (command_line && filename_prefix_len != 0)
-                 && excluded_directory_patterns
-                 && excluded_file_name (excluded_directory_patterns, name)))
-          : (excluded_patterns
-             && excluded_file_name (excluded_patterns, name)));
-}
-
-/* Hairy buffering mechanism for grep.  The intent is to keep
-   all reads aligned on a page boundary and multiples of the
-   page size, unless a read yields a partial page.  */
-
-static char *buffer;           /* Base of buffer. */
-static size_t bufalloc;                /* Allocated buffer size, counting slop. */
-#define INITIAL_BUFSIZE 32768  /* Initial buffer size, not counting slop. */
-static int bufdesc;            /* File descriptor. */
-static char *bufbeg;           /* Beginning of user-visible stuff. */
-static char *buflim;           /* Limit of user-visible stuff. */
-static size_t pagesize;                /* alignment of memory pages */
-static off_t bufoffset;                /* Read offset; defined on regular files.  */
-static off_t after_last_match; /* Pointer after last matching line that
-                                   would have been output if we were
-                                   outputting characters. */
-
-/* Return VAL aligned to the next multiple of ALIGNMENT.  VAL can be
-   an integer or a pointer.  Both args must be free of side effects.  */
-#define ALIGN_TO(val, alignment) \
-  ((size_t) (val) % (alignment) == 0 \
-   ? (val) \
-   : (val) + ((alignment) - (size_t) (val) % (alignment)))
-
-/* Reset the buffer for a new file, returning zero if we should skip it.
-   Initialize on the first time through. */
-static int
-reset (int fd, struct stat const *st)
-{
-  if (! pagesize)
-    {
-      pagesize = getpagesize ();
-      if (pagesize == 0 || 2 * pagesize + 1 <= pagesize)
-        abort ();
-      bufalloc = ALIGN_TO (INITIAL_BUFSIZE, pagesize) + pagesize + 1;
-      buffer = xmalloc (bufalloc);
-    }
-
-  bufbeg = buflim = ALIGN_TO (buffer + 1, pagesize);
-  bufbeg[-1] = eolbyte;
-  bufdesc = fd;
-
-  if (S_ISREG (st->st_mode))
-    {
-      if (fd != STDIN_FILENO)
-        bufoffset = 0;
-      else
-        {
-          bufoffset = lseek (fd, 0, SEEK_CUR);
-          if (bufoffset < 0)
-            {
-              suppressible_error (_("lseek failed"), errno);
-              return 0;
-            }
-        }
-    }
-  return 1;
-}
-
-/* Read new stuff into the buffer, saving the specified
-   amount of old stuff.  When we're done, 'bufbeg' points
-   to the beginning of the buffer contents, and 'buflim'
-   points just after the end.  Return zero if there's an error.  */
-static int
-fillbuf (size_t save, struct stat const *st)
-{
-  ssize_t fillsize;
-  int cc = 1;
-  char *readbuf;
-  size_t readsize;
-
-  /* Offset from start of buffer to start of old stuff
-     that we want to save.  */
-  size_t saved_offset = buflim - save - buffer;
-
-  if (pagesize <= buffer + bufalloc - buflim)
-    {
-      readbuf = buflim;
-      bufbeg = buflim - save;
-    }
-  else
-    {
-      size_t minsize = save + pagesize;
-      size_t newsize;
-      size_t newalloc;
-      char *newbuf;
-
-      /* Grow newsize until it is at least as great as minsize.  */
-      for (newsize = bufalloc - pagesize - 1; newsize < minsize; newsize *= 2)
-        if (newsize * 2 < newsize || newsize * 2 + pagesize + 1 < newsize * 2)
-          xalloc_die ();
-
-      /* Try not to allocate more memory than the file size indicates,
-         as that might cause unnecessary memory exhaustion if the file
-         is large.  However, do not use the original file size as a
-         heuristic if we've already read past the file end, as most
-         likely the file is growing.  */
-      if (usable_st_size (st))
-        {
-          off_t to_be_read = st->st_size - bufoffset;
-          off_t maxsize_off = save + to_be_read;
-          if (0 <= to_be_read && to_be_read <= maxsize_off
-              && maxsize_off == (size_t) maxsize_off
-              && minsize <= (size_t) maxsize_off
-              && (size_t) maxsize_off < newsize)
-            newsize = maxsize_off;
-        }
-
-      /* Add enough room so that the buffer is aligned and has room
-         for byte sentinels fore and aft.  */
-      newalloc = newsize + pagesize + 1;
-
-      newbuf = bufalloc < newalloc ? xmalloc (bufalloc = newalloc) : buffer;
-      readbuf = ALIGN_TO (newbuf + 1 + save, pagesize);
-      bufbeg = readbuf - save;
-      memmove (bufbeg, buffer + saved_offset, save);
-      bufbeg[-1] = eolbyte;
-      if (newbuf != buffer)
-        {
-          free (buffer);
-          buffer = newbuf;
-        }
-    }
-
-  readsize = buffer + bufalloc - readbuf;
-  readsize -= readsize % pagesize;
-
-  fillsize = safe_read (bufdesc, readbuf, readsize);
-  if (fillsize < 0)
-    fillsize = cc = 0;
-  bufoffset += fillsize;
-#if defined HAVE_DOS_FILE_CONTENTS
-  if (fillsize)
-    fillsize = undossify_input (readbuf, fillsize);
-#endif
-  buflim = readbuf + fillsize;
-  return cc;
-}
-
-/* Flags controlling the style of output. */
-static enum
-{
-  BINARY_BINARY_FILES,
-  TEXT_BINARY_FILES,
-  WITHOUT_MATCH_BINARY_FILES
-} binary_files;                /* How to handle binary files.  */
-
-static int filename_mask;      /* If zero, output nulls after filenames.  */
-static int out_quiet;          /* Suppress all normal output. */
-static int out_invert;         /* Print nonmatching stuff. */
-static int out_file;           /* Print filenames. */
-static int out_line;           /* Print line numbers. */
-static int out_byte;           /* Print byte offsets. */
-static intmax_t out_before;    /* Lines of leading context. */
-static intmax_t out_after;     /* Lines of trailing context. */
-static int count_matches;      /* Count matching lines.  */
-static int list_files;         /* List matching files.  */
-static int no_filenames;       /* Suppress file names.  */
-static intmax_t max_count;     /* Stop after outputting this many
-                                   lines from an input file.  */
-static int line_buffered;       /* If nonzero, use line buffering, i.e.
-                                   fflush everyline out.  */
-static char *label = NULL;      /* Fake filename for stdin */
-
-
-/* Internal variables to keep track of byte count, context, etc. */
-static uintmax_t totalcc;      /* Total character count before bufbeg. */
-static char const *lastnl;     /* Pointer after last newline counted. */
-static char const *lastout;    /* Pointer after last character output;
-                                   NULL if no character has been output
-                                   or if it's conceptually before bufbeg. */
-static uintmax_t totalnl;      /* Total newline count before lastnl. */
-static intmax_t outleft;       /* Maximum number of lines to be output.  */
-static intmax_t pending;       /* Pending lines of output.
-                                   Always kept 0 if out_quiet is true.  */
-static int done_on_match;      /* Stop scanning file on first match.  */
-static int exit_on_match;      /* Exit on first match.  */
-
-#if defined HAVE_DOS_FILE_CONTENTS
-# include "dosbuf.c"
-#endif
-
-/* Add two numbers that count input bytes or lines, and report an
-   error if the addition overflows.  */
-static uintmax_t
-add_count (uintmax_t a, uintmax_t b)
-{
-  uintmax_t sum = a + b;
-  if (sum < a)
-    error (EXIT_TROUBLE, 0, _("input is too large to count"));
-  return sum;
-}
-
-static void
-nlscan (char const *lim)
-{
-  size_t newlines = 0;
-  char const *beg;
-  for (beg = lastnl; beg < lim; beg++)
-    {
-      beg = memchr (beg, eolbyte, lim - beg);
-      if (!beg)
-        break;
-      newlines++;
-    }
-  totalnl = add_count (totalnl, newlines);
-  lastnl = lim;
-}
-
-/* Print the current filename.  */
-static void
-print_filename (void)
-{
-  pr_sgr_start_if (filename_color);
-  fputs (filename, stdout);
-  pr_sgr_end_if (filename_color);
-}
-
-/* Print a character separator.  */
-static void
-print_sep (char sep)
-{
-  pr_sgr_start_if (sep_color);
-  fputc (sep, stdout);
-  pr_sgr_end_if (sep_color);
-}
-
-/* Print a line number or a byte offset.  */
-static void
-print_offset (uintmax_t pos, int min_width, const char *color)
-{
-  /* Do not rely on printf to print pos, since uintmax_t may be longer
-     than long, and long long is not portable.  */
-
-  char buf[sizeof pos * CHAR_BIT];
-  char *p = buf + sizeof buf;
-
-  do
-    {
-      *--p = '0' + pos % 10;
-      --min_width;
-    }
-  while ((pos /= 10) != 0);
-
-  /* Do this to maximize the probability of alignment across lines.  */
-  if (align_tabs)
-    while (--min_width >= 0)
-      *--p = ' ';
-
-  pr_sgr_start_if (color);
-  fwrite (p, 1, buf + sizeof buf - p, stdout);
-  pr_sgr_end_if (color);
-}
-
-/* Print a whole line head (filename, line, byte).  */
-static void
-print_line_head (char const *beg, char const *lim, int sep)
-{
-  int pending_sep = 0;
-
-  if (out_file)
-    {
-      print_filename ();
-      if (filename_mask)
-        pending_sep = 1;
-      else
-        fputc (0, stdout);
-    }
-
-  if (out_line)
-    {
-      if (lastnl < lim)
-        {
-          nlscan (beg);
-          totalnl = add_count (totalnl, 1);
-          lastnl = lim;
-        }
-      if (pending_sep)
-        print_sep (sep);
-      print_offset (totalnl, 4, line_num_color);
-      pending_sep = 1;
-    }
-
-  if (out_byte)
-    {
-      uintmax_t pos = add_count (totalcc, beg - bufbeg);
-#if defined HAVE_DOS_FILE_CONTENTS
-      pos = dossified_pos (pos);
-#endif
-      if (pending_sep)
-        print_sep (sep);
-      print_offset (pos, 6, byte_num_color);
-      pending_sep = 1;
-    }
-
-  if (pending_sep)
-    {
-      /* This assumes sep is one column wide.
-         Try doing this any other way with Unicode
-         (and its combining and wide characters)
-         filenames and you're wasting your efforts.  */
-      if (align_tabs)
-        fputs ("\t\b", stdout);
-
-      print_sep (sep);
-    }
-}
-
-static const char *
-print_line_middle (const char *beg, const char *lim,
-                   const char *line_color, const char *match_color)
-{
-  size_t match_size;
-  size_t match_offset;
-  const char *cur = beg;
-  const char *mid = NULL;
-
-  while (cur < lim
-         && ((match_offset = execute (beg, lim - beg, &match_size,
-                                      beg + (cur - beg))) != (size_t) -1))
-    {
-      char const *b = beg + match_offset;
-
-      /* Avoid matching the empty line at the end of the buffer. */
-      if (b == lim)
-        break;
-
-      /* Avoid hanging on grep --color "" foo */
-      if (match_size == 0)
-        {
-          /* Make minimal progress; there may be further non-empty matches.  */
-          /* XXX - Could really advance by one whole multi-octet character.  */
-          match_size = 1;
-          if (!mid)
-            mid = cur;
-        }
-      else
-        {
-          /* This function is called on a matching line only,
-             but is it selected or rejected/context?  */
-          if (only_matching)
-            print_line_head (b, lim, (out_invert ? SEP_CHAR_REJECTED
-                                      : SEP_CHAR_SELECTED));
-          else
-            {
-              pr_sgr_start (line_color);
-              if (mid)
-                {
-                  cur = mid;
-                  mid = NULL;
-                }
-              fwrite (cur, sizeof (char), b - cur, stdout);
-            }
-
-          pr_sgr_start_if (match_color);
-          fwrite (b, sizeof (char), match_size, stdout);
-          pr_sgr_end_if (match_color);
-          if (only_matching)
-            fputs ("\n", stdout);
-        }
-      cur = b + match_size;
-    }
-
-  if (only_matching)
-    cur = lim;
-  else if (mid)
-    cur = mid;
-
-  return cur;
-}
-
-static const char *
-print_line_tail (const char *beg, const char *lim, const char *line_color)
-{
-  size_t eol_size;
-  size_t tail_size;
-
-  eol_size   = (lim > beg && lim[-1] == eolbyte);
-  eol_size  += (lim - eol_size > beg && lim[-(1 + eol_size)] == '\r');
-  tail_size  =  lim - eol_size - beg;
-
-  if (tail_size > 0)
-    {
-      pr_sgr_start (line_color);
-      fwrite (beg, 1, tail_size, stdout);
-      beg += tail_size;
-      pr_sgr_end (line_color);
-    }
-
-  return beg;
-}
-
-static void
-prline (char const *beg, char const *lim, int sep)
-{
-  int matching;
-  const char *line_color;
-  const char *match_color;
-
-  if (!only_matching)
-    print_line_head (beg, lim, sep);
-
-  matching = (sep == SEP_CHAR_SELECTED) ^ !!out_invert;
-
-  if (color_option)
-    {
-      line_color = (((sep == SEP_CHAR_SELECTED)
-                     ^ (out_invert && (color_option < 0)))
-                    ? selected_line_color  : context_line_color);
-      match_color = (sep == SEP_CHAR_SELECTED
-                     ? selected_match_color : context_match_color);
-    }
-  else
-    line_color = match_color = NULL; /* Shouldn't be used.  */
-
-  if ((only_matching && matching)
-      || (color_option && (*line_color || *match_color)))
-    {
-      /* We already know that non-matching lines have no match (to colorize). */
-      if (matching && (only_matching || *match_color))
-        beg = print_line_middle (beg, lim, line_color, match_color);
-
-      if (!only_matching && *line_color)
-        {
-          /* This code is exercised at least when grep is invoked like this:
-             echo k| GREP_COLORS='sl=01;32' src/grep k --color=always  */
-          beg = print_line_tail (beg, lim, line_color);
-        }
-    }
-
-  if (!only_matching && lim > beg)
-    fwrite (beg, 1, lim - beg, stdout);
-
-  if (ferror (stdout))
-    {
-      write_error_seen = 1;
-      error (EXIT_TROUBLE, 0, _("write error"));
-    }
-
-  lastout = lim;
-
-  if (line_buffered)
-    fflush (stdout);
-}
-
-/* Print pending lines of trailing context prior to LIM. Trailing context ends
-   at the next matching line when OUTLEFT is 0.  */
-static void
-prpending (char const *lim)
-{
-  if (!lastout)
-    lastout = bufbeg;
-  while (pending > 0 && lastout < lim)
-    {
-      char const *nl = memchr (lastout, eolbyte, lim - lastout);
-      size_t match_size;
-      --pending;
-      if (outleft
-          || ((execute (lastout, nl + 1 - lastout,
-                        &match_size, NULL) == (size_t) -1)
-              == !out_invert))
-        prline (lastout, nl + 1, SEP_CHAR_REJECTED);
-      else
-        pending = 0;
-    }
-}
-
-/* Print the lines between BEG and LIM.  Deal with context crap.
-   If NLINESP is non-null, store a count of lines between BEG and LIM.  */
-static void
-prtext (char const *beg, char const *lim, intmax_t *nlinesp)
-{
-  static int used;     /* avoid printing SEP_STR_GROUP before any output */
-  char const *bp, *p;
-  char eol = eolbyte;
-  intmax_t i, n;
-
-  if (!out_quiet && pending > 0)
-    prpending (beg);
-
-  p = beg;
-
-  if (!out_quiet)
-    {
-      /* Deal with leading context crap. */
-
-      bp = lastout ? lastout : bufbeg;
-      for (i = 0; i < out_before; ++i)
-        if (p > bp)
-          do
-            --p;
-          while (p[-1] != eol);
-
-      /* We print the SEP_STR_GROUP separator only if our output is
-         discontiguous from the last output in the file. */
-      if ((out_before || out_after) && used && p != lastout && group_separator)
-        {
-          pr_sgr_start_if (sep_color);
-          fputs (group_separator, stdout);
-          pr_sgr_end_if (sep_color);
-          fputc ('\n', stdout);
-        }
-
-      while (p < beg)
-        {
-          char const *nl = memchr (p, eol, beg - p);
-          nl++;
-          prline (p, nl, SEP_CHAR_REJECTED);
-          p = nl;
-        }
-    }
-
-  if (nlinesp)
-    {
-      /* Caller wants a line count. */
-      for (n = 0; p < lim && n < outleft; n++)
-        {
-          char const *nl = memchr (p, eol, lim - p);
-          nl++;
-          if (!out_quiet)
-            prline (p, nl, SEP_CHAR_SELECTED);
-          p = nl;
-        }
-      *nlinesp = n;
-
-      /* relying on it that this function is never called when outleft = 0.  */
-      after_last_match = bufoffset - (buflim - p);
-    }
-  else if (!out_quiet)
-    prline (beg, lim, SEP_CHAR_SELECTED);
-
-  pending = out_quiet ? 0 : out_after;
-  used = 1;
-}
-
-/* Invoke the matcher, EXECUTE, on buffer BUF of SIZE bytes.  If there
-   is no match, return (size_t) -1.  Otherwise, set *MATCH_SIZE to the
-   length of the match and return the offset of the start of the match.  */
-static size_t
-do_execute (char const *buf, size_t size, size_t *match_size,
-            char const *start_ptr)
-{
-  size_t result;
-  const char *line_next;
-
-  /* With the current implementation, using --ignore-case with a multi-byte
-     character set is very inefficient when applied to a large buffer
-     containing many matches.  We can avoid much of the wasted effort
-     by matching line-by-line.
-
-     FIXME: this is just an ugly workaround, and it doesn't really
-     belong here.  Also, PCRE is always using this same per-line
-     matching algorithm.  Either we fix -i, or we should refactor
-     this code---for example, we could add another function pointer
-     to struct matcher to split the buffer passed to execute.  It would
-     perform the memchr if line-by-line matching is necessary, or just
-     return buf + size otherwise.  */
-  if (MB_CUR_MAX == 1 || !match_icase)
-    return execute (buf, size, match_size, start_ptr);
-
-  for (line_next = buf; line_next < buf + size; )
-    {
-      const char *line_buf = line_next;
-      const char *line_end = memchr (line_buf, eolbyte,
-                                     (buf + size) - line_buf);
-      if (line_end == NULL)
-        line_next = line_end = buf + size;
-      else
-        line_next = line_end + 1;
-
-      if (start_ptr && start_ptr >= line_end)
-        continue;
-
-      result = execute (line_buf, line_next - line_buf, match_size, start_ptr);
-      if (result != (size_t) -1)
-        return (line_buf - buf) + result;
-    }
-
-  return (size_t) -1;
-}
-
-/* Scan the specified portion of the buffer, matching lines (or
-   between matching lines if OUT_INVERT is true).  Return a count of
-   lines printed. */
-static intmax_t
-grepbuf (char const *beg, char const *lim)
-{
-  intmax_t nlines, n;
-  char const *p;
-  size_t match_offset;
-  size_t match_size;
-
-  nlines = 0;
-  p = beg;
-  while ((match_offset = do_execute (p, lim - p, &match_size,
-                                     NULL)) != (size_t) -1)
-    {
-      char const *b = p + match_offset;
-      char const *endp = b + match_size;
-      /* Avoid matching the empty line at the end of the buffer. */
-      if (b == lim)
-        break;
-      if (!out_invert)
-        {
-          prtext (b, endp, NULL);
-          nlines++;
-          outleft--;
-          if (!outleft || done_on_match)
-            {
-              if (exit_on_match)
-                exit (EXIT_SUCCESS);
-              after_last_match = bufoffset - (buflim - endp);
-              return nlines;
-            }
-        }
-      else if (p < b)
-        {
-          prtext (p, b, &n);
-          nlines += n;
-          outleft -= n;
-          if (!outleft)
-            return nlines;
-        }
-      p = endp;
-    }
-  if (out_invert && p < lim)
-    {
-      prtext (p, lim, &n);
-      nlines += n;
-      outleft -= n;
-    }
-  return nlines;
-}
-
-/* Search a given file.  Normally, return a count of lines printed;
-   but if the file is a directory and we search it recursively, then
-   return -2 if there was a match, and -1 otherwise.  */
-static intmax_t
-grep (int fd, struct stat const *st)
-{
-  intmax_t nlines, i;
-  int not_text;
-  size_t residue, save;
-  char oldc;
-  char *beg;
-  char *lim;
-  char eol = eolbyte;
-
-  if (! reset (fd, st))
-    return 0;
-
-  totalcc = 0;
-  lastout = 0;
-  totalnl = 0;
-  outleft = max_count;
-  after_last_match = 0;
-  pending = 0;
-
-  nlines = 0;
-  residue = 0;
-  save = 0;
-
-  if (! fillbuf (save, st))
-    {
-      suppressible_error (filename, errno);
-      return 0;
-    }
-
-  not_text = (((binary_files == BINARY_BINARY_FILES && !out_quiet)
-               || binary_files == WITHOUT_MATCH_BINARY_FILES)
-              && file_is_binary (bufbeg, buflim - bufbeg, fd, st));
-  if (not_text && binary_files == WITHOUT_MATCH_BINARY_FILES)
-    return 0;
-  done_on_match += not_text;
-  out_quiet += not_text;
-
-  for (;;)
-    {
-      lastnl = bufbeg;
-      if (lastout)
-        lastout = bufbeg;
-
-      beg = bufbeg + save;
-
-      /* no more data to scan (eof) except for maybe a residue -> break */
-      if (beg == buflim)
-        break;
-
-      /* Determine new residue (the length of an incomplete line at the end of
-         the buffer, 0 means there is no incomplete last line).  */
-      oldc = beg[-1];
-      beg[-1] = eol;
-      /* FIXME: use rawmemrchr if/when it exists, since we have ensured
-         that this use of memrchr is guaranteed never to return NULL.  */
-      lim = memrchr (beg - 1, eol, buflim - beg + 1);
-      ++lim;
-      beg[-1] = oldc;
-      if (lim == beg)
-        lim = beg - residue;
-      beg -= residue;
-      residue = buflim - lim;
-
-      if (beg < lim)
-        {
-          if (outleft)
-            nlines += grepbuf (beg, lim);
-          if (pending)
-            prpending (lim);
-          if ((!outleft && !pending)
-              || (nlines && done_on_match && !out_invert))
-            goto finish_grep;
-        }
-
-      /* The last OUT_BEFORE lines at the end of the buffer will be needed as
-         leading context if there is a matching line at the begin of the
-         next data. Make beg point to their begin.  */
-      i = 0;
-      beg = lim;
-      while (i < out_before && beg > bufbeg && beg != lastout)
-        {
-          ++i;
-          do
-            --beg;
-          while (beg[-1] != eol);
-        }
-
-      /* detect if leading context is discontinuous from last printed line.  */
-      if (beg != lastout)
-        lastout = 0;
-
-      /* Handle some details and read more data to scan.  */
-      save = residue + lim - beg;
-      if (out_byte)
-        totalcc = add_count (totalcc, buflim - bufbeg - save);
-      if (out_line)
-        nlscan (beg);
-      if (! fillbuf (save, st))
-        {
-          suppressible_error (filename, errno);
-          goto finish_grep;
-        }
-    }
-  if (residue)
-    {
-      *buflim++ = eol;
-      if (outleft)
-        nlines += grepbuf (bufbeg + save - residue, buflim);
-      if (pending)
-        prpending (buflim);
-    }
-
- finish_grep:
-  done_on_match -= not_text;
-  out_quiet -= not_text;
-  if ((not_text & ~out_quiet) && nlines != 0)
-    printf (_("Binary file %s matches\n"), filename);
-  return nlines;
-}
-
-static int
-grepdirent (FTS *fts, FTSENT *ent, int command_line)
-{
-  int follow, dirdesc;
-  struct stat *st = ent->fts_statp;
-  command_line &= ent->fts_level == FTS_ROOTLEVEL;
-
-  if (ent->fts_info == FTS_DP)
-    {
-      if (directories == RECURSE_DIRECTORIES && command_line)
-        out_file &= ~ (2 * !no_filenames);
-      return 1;
-    }
-
-  if (skipped_file (ent->fts_name, command_line,
-                    (ent->fts_info == FTS_D || ent->fts_info == FTS_DC
-                     || ent->fts_info == FTS_DNR)))
-    {
-      fts_set (fts, ent, FTS_SKIP);
-      return 1;
-    }
-
-  filename = ent->fts_path + filename_prefix_len;
-  follow = (fts->fts_options & FTS_LOGICAL
-            || (fts->fts_options & FTS_COMFOLLOW && command_line));
-
-  switch (ent->fts_info)
-    {
-    case FTS_D:
-      if (directories == RECURSE_DIRECTORIES)
-        {
-          out_file |= 2 * !no_filenames;
-          return 1;
-        }
-      fts_set (fts, ent, FTS_SKIP);
-      break;
-
-    case FTS_DC:
-      if (!suppress_errors)
-        error (0, 0, _("warning: %s: %s"), filename,
-               _("recursive directory loop"));
-      return 1;
-
-    case FTS_DNR:
-    case FTS_ERR:
-    case FTS_NS:
-      suppressible_error (filename, ent->fts_errno);
-      return 1;
-
-    case FTS_DEFAULT:
-    case FTS_NSOK:
-      if (devices == SKIP_DEVICES
-          || (devices == READ_COMMAND_LINE_DEVICES && !command_line))
-        {
-          struct stat st1;
-          if (! st->st_mode)
-            {
-              /* The file type is not already known.  Get the file status
-                 before opening, since opening might have side effects
-                 on a device.  */
-              int flag = follow ? 0 : AT_SYMLINK_NOFOLLOW;
-              if (fstatat (fts->fts_cwd_fd, ent->fts_accpath, &st1, flag) != 0)
-                {
-                  suppressible_error (filename, errno);
-                  return 1;
-                }
-              st = &st1;
-            }
-          if (is_device_mode (st->st_mode))
-            return 1;
-        }
-      break;
-
-    case FTS_F:
-    case FTS_SLNONE:
-      break;
-
-    case FTS_SL:
-    case FTS_W:
-      return 1;
-
-    default:
-      abort ();
-    }
-
-  dirdesc = ((fts->fts_options & (FTS_NOCHDIR | FTS_CWDFD)) == FTS_CWDFD
-             ? fts->fts_cwd_fd
-             : AT_FDCWD);
-  return grepfile (dirdesc, ent->fts_accpath, follow, command_line);
-}
-
-static int
-grepfile (int dirdesc, char const *name, int follow, int command_line)
-{
-  int desc = openat_safer (dirdesc, name, O_RDONLY | (follow ? 0 : O_NOFOLLOW));
-  if (desc < 0)
-    {
-      if (follow || (errno != ELOOP && errno != EMLINK))
-        suppressible_error (filename, errno);
-      return 1;
-    }
-  return grepdesc (desc, command_line);
-}
-
-static int
-grepdesc (int desc, int command_line)
-{
-  intmax_t count;
-  int status = 1;
-  struct stat st;
-
-  /* Get the file status, possibly for the second time.  This catches
-     a race condition if the directory entry changes after the
-     directory entry is read and before the file is opened.  For
-     example, normally DESC is a directory only at the top level, but
-     there is an exception if some other process substitutes a
-     directory for a non-directory while 'grep' is running.  */
-  if (fstat (desc, &st) != 0)
-    {
-      suppressible_error (filename, errno);
-      goto closeout;
-    }
-
-  if (desc != STDIN_FILENO && command_line
-      && skipped_file (filename, 1, S_ISDIR (st.st_mode)))
-    goto closeout;
-
-  if (desc != STDIN_FILENO
-      && directories == RECURSE_DIRECTORIES && S_ISDIR (st.st_mode))
-    {
-      /* Traverse the directory starting with its full name, because
-         unfortunately fts provides no way to traverse the directory
-         starting from its file descriptor.  */
-
-      FTS *fts;
-      FTSENT *ent;
-      int opts = fts_options & ~(command_line ? 0 : FTS_COMFOLLOW);
-      char *fts_arg[2];
-
-      /* Close DESC now, to conserve file descriptors if the race
-         condition occurs many times in a deep recursion.  */
-      if (close (desc) != 0)
-        suppressible_error (filename, errno);
-
-      fts_arg[0] = (char *) filename;
-      fts_arg[1] = NULL;
-      fts = fts_open (fts_arg, opts, NULL);
-
-      if (!fts)
-        xalloc_die ();
-      while ((ent = fts_read (fts)))
-        status &= grepdirent (fts, ent, command_line);
-      if (errno)
-        suppressible_error (filename, errno);
-      if (fts_close (fts) != 0)
-        suppressible_error (filename, errno);
-      return status;
-    }
-  if (desc != STDIN_FILENO
-      && ((directories == SKIP_DIRECTORIES && S_ISDIR (st.st_mode))
-          || ((devices == SKIP_DEVICES
-               || (devices == READ_COMMAND_LINE_DEVICES && !command_line))
-              && is_device_mode (st.st_mode))))
-    goto closeout;
-
-  /* If there is a regular file on stdout and the current file refers
-     to the same i-node, we have to report the problem and skip it.
-     Otherwise when matching lines from some other input reach the
-     disk before we open this file, we can end up reading and matching
-     those lines and appending them to the file from which we're reading.
-     Then we'd have what appears to be an infinite loop that'd terminate
-     only upon filling the output file system or reaching a quota.
-     However, there is no risk of an infinite loop if grep is generating
-     no output, i.e., with --silent, --quiet, -q.
-     Similarly, with any of these:
-       --max-count=N (-m) (for N >= 2)
-       --files-with-matches (-l)
-       --files-without-match (-L)
-     there is no risk of trouble.
-     For --max-count=1, grep stops after printing the first match,
-     so there is no risk of malfunction.  But even --max-count=2, with
-     input==output, while there is no risk of infloop, there is a race
-     condition that could result in "alternate" output.  */
-  if (!out_quiet && list_files == 0 && 1 < max_count
-      && S_ISREG (out_stat.st_mode) && out_stat.st_ino
-      && SAME_INODE (st, out_stat))
-    {
-      if (! suppress_errors)
-        error (0, 0, _("input file %s is also the output"), quote (filename));
-      errseen = 1;
-      goto closeout;
-    }
-
-#if defined SET_BINARY
-  /* Set input to binary mode.  Pipes are simulated with files
-     on DOS, so this includes the case of "foo | grep bar".  */
-  if (!isatty (desc))
-    SET_BINARY (desc);
-#endif
-
-  count = grep (desc, &st);
-  if (count < 0)
-    status = count + 2;
-  else
-    {
-      if (count_matches)
-        {
-          if (out_file)
-            {
-              print_filename ();
-              if (filename_mask)
-                print_sep (SEP_CHAR_SELECTED);
-              else
-                fputc (0, stdout);
-            }
-          printf ("%" PRIdMAX "\n", count);
-        }
-
-      status = !count;
-      if (list_files == 1 - 2 * status)
-        {
-          print_filename ();
-          fputc ('\n' & filename_mask, stdout);
-        }
-
-      if (desc == STDIN_FILENO)
-        {
-          off_t required_offset = outleft ? bufoffset : after_last_match;
-          if (required_offset != bufoffset
-              && lseek (desc, required_offset, SEEK_SET) < 0
-              && S_ISREG (st.st_mode))
-            suppressible_error (filename, errno);
-        }
-    }
-
- closeout:
-  if (desc != STDIN_FILENO && close (desc) != 0)
-    suppressible_error (filename, errno);
-  return status;
-}
-
-static int
-grep_command_line_arg (char const *arg)
-{
-  if (STREQ (arg, "-"))
-    {
-      filename = label ? label : _("(standard input)");
-      return grepdesc (STDIN_FILENO, 1);
-    }
-  else
-    {
-      filename = arg;
-      return grepfile (AT_FDCWD, arg, 1, 1);
-    }
-}
-
-_Noreturn void usage (int);
-void
-usage (int status)
-{
-  if (status != 0)
-    {
-      fprintf (stderr, _("Usage: %s [OPTION]... PATTERN [FILE]...\n"),
-               program_name);
-      fprintf (stderr, _("Try '%s --help' for more information.\n"),
-               program_name);
-    }
-  else
-    {
-      printf (_("Usage: %s [OPTION]... PATTERN [FILE]...\n"), program_name);
-      printf (_("\
-Search for PATTERN in each FILE or standard input.\n"));
-      fputs (_(before_options), stdout);
-      printf (_("\
-Example: %s -i 'hello world' menu.h main.c\n\
-\n\
-Regexp selection and interpretation:\n"), program_name);
-      if (matchers[1].name)
-        printf (_("\
-  -E, --extended-regexp     PATTERN is an extended regular expression (ERE)\n\
-  -F, --fixed-strings       PATTERN is a set of newline-separated fixed strings\n\
-  -G, --basic-regexp        PATTERN is a basic regular expression (BRE)\n\
-  -P, --perl-regexp         PATTERN is a Perl regular expression\n"));
-  /* -X is undocumented on purpose. */
-      printf (_("\
-  -e, --regexp=PATTERN      use PATTERN for matching\n\
-  -f, --file=FILE           obtain PATTERN from FILE\n\
-  -i, --ignore-case         ignore case distinctions\n\
-  -w, --word-regexp         force PATTERN to match only whole words\n\
-  -x, --line-regexp         force PATTERN to match only whole lines\n\
-  -z, --null-data           a data line ends in 0 byte, not newline\n"));
-      printf (_("\
-\n\
-Miscellaneous:\n\
-  -s, --no-messages         suppress error messages\n\
-  -v, --invert-match        select non-matching lines\n\
-  -V, --version             print version information and exit\n\
-      --help                display this help and exit\n\
-      --mmap                deprecated no-op; evokes a warning\n"));
-      printf (_("\
-\n\
-Output control:\n\
-  -m, --max-count=NUM       stop after NUM matches\n\
-  -b, --byte-offset         print the byte offset with output lines\n\
-  -n, --line-number         print line number with output lines\n\
-      --line-buffered       flush output on every line\n\
-  -H, --with-filename       print the file name for each match\n\
-  -h, --no-filename         suppress the file name prefix on output\n\
-      --label=LABEL         use LABEL as the standard input file name prefix\n\
-"));
-      printf (_("\
-  -o, --only-matching       show only the part of a line matching PATTERN\n\
-  -q, --quiet, --silent     suppress all normal output\n\
-      --binary-files=TYPE   assume that binary files are TYPE;\n\
-                            TYPE is 'binary', 'text', or 'without-match'\n\
-  -a, --text                equivalent to --binary-files=text\n\
-"));
-      printf (_("\
-  -I                        equivalent to --binary-files=without-match\n\
-  -d, --directories=ACTION  how to handle directories;\n\
-                            ACTION is 'read', 'recurse', or 'skip'\n\
-  -D, --devices=ACTION      how to handle devices, FIFOs and sockets;\n\
-                            ACTION is 'read' or 'skip'\n\
-  -r, --recursive           like --directories=recurse\n\
-  -R, --dereference-recursive  likewise, but follow all symlinks\n\
-"));
-      printf (_("\
-      --include=FILE_PATTERN  search only files that match FILE_PATTERN\n\
-      --exclude=FILE_PATTERN  skip files and directories matching FILE_PATTERN\n\
-      --exclude-from=FILE   skip files matching any file pattern from FILE\n\
-      --exclude-dir=PATTERN  directories that match PATTERN will be skipped.\n\
-"));
-      printf (_("\
-  -L, --files-without-match  print only names of FILEs containing no match\n\
-  -l, --files-with-matches  print only names of FILEs containing matches\n\
-  -c, --count               print only a count of matching lines per FILE\n\
-  -T, --initial-tab         make tabs line up (if needed)\n\
-  -Z, --null                print 0 byte after FILE name\n"));
-      printf (_("\
-\n\
-Context control:\n\
-  -B, --before-context=NUM  print NUM lines of leading context\n\
-  -A, --after-context=NUM   print NUM lines of trailing context\n\
-  -C, --context=NUM         print NUM lines of output context\n\
-"));
-      printf (_("\
-  -NUM                      same as --context=NUM\n\
-      --color[=WHEN],\n\
-      --colour[=WHEN]       use markers to highlight the matching strings;\n\
-                            WHEN is 'always', 'never', or 'auto'\n\
-  -U, --binary              do not strip CR characters at EOL (MSDOS/Windows)\n\
-  -u, --unix-byte-offsets   report offsets as if CRs were not there\n\
-                            (MSDOS/Windows)\n\
-\n"));
-      fputs (_(after_options), stdout);
-      printf (_("\
-When FILE is -, read standard input.  With no FILE, read . if a command-line\n\
--r is given, - otherwise.  If fewer than two FILEs are given, assume -h.\n\
-Exit status is 0 if any line is selected, 1 otherwise;\n\
-if any error occurs and -q is not given, the exit status is 2.\n"));
-      printf (_("\nReport bugs to: %s\n"), PACKAGE_BUGREPORT);
-      printf (_("GNU Grep home page: <%s>\n"),
-              "http://www.gnu.org/software/grep/");
-      fputs (_("General help using GNU software: <http://www.gnu.org/gethelp/>\n"),
-             stdout);
-
-    }
-  exit (status);
-}
-
-/* If M is NULL, initialize the matcher to the default.  Otherwise set the
-   matcher to M if available.  Exit in case of conflicts or if M is not
-   available.  */
-static void
-setmatcher (char const *m)
-{
-  static char const *matcher;
-  unsigned int i;
-
-  if (!m)
-    {
-      compile = matchers[0].compile;
-      execute = matchers[0].execute;
-      if (!matchers[1].name)
-        matcher = matchers[0].name;
-    }
-
-  else if (matcher)
-    {
-      if (matcher && STREQ (matcher, m))
-        ;
-
-      else if (!matchers[1].name)
-        error (EXIT_TROUBLE, 0, _("%s can only use the %s pattern syntax"),
-               program_name, matcher);
-      else
-        error (EXIT_TROUBLE, 0, _("conflicting matchers specified"));
-    }
-
-  else
-    {
-      for (i = 0; matchers[i].name; i++)
-        if (STREQ (m, matchers[i].name))
-          {
-            compile = matchers[i].compile;
-            execute = matchers[i].execute;
-            matcher = m;
-            return;
-          }
-
-      error (EXIT_TROUBLE, 0, _("invalid matcher %s"), m);
-    }
-}
-
-/* Find the white-space-separated options specified by OPTIONS, and
-   using BUF to store copies of these options, set ARGV[0], ARGV[1],
-   etc. to the option copies.  Return the number N of options found.
-   Do not set ARGV[N] to NULL.  If ARGV is NULL, do not store ARGV[0]
-   etc.  Backslash can be used to escape whitespace (and backslashes).  */
-static size_t
-prepend_args (char const *options, char *buf, char **argv)
-{
-  char const *o = options;
-  char *b = buf;
-  size_t n = 0;
-
-  for (;;)
-    {
-      while (c_isspace ((unsigned char) *o))
-        o++;
-      if (!*o)
-        return n;
-      if (argv)
-        argv[n] = b;
-      n++;
-
-      do
-        if ((*b++ = *o++) == '\\' && *o)
-          b[-1] = *o++;
-      while (*o && ! c_isspace ((unsigned char) *o));
-
-      *b++ = '\0';
-    }
-}
-
-/* Prepend the whitespace-separated options in OPTIONS to the argument
-   vector of a main program with argument count *PARGC and argument
-   vector *PARGV.  Return the number of options prepended.  */
-static int
-prepend_default_options (char const *options, int *pargc, char ***pargv)
-{
-  if (options && *options)
-    {
-      char *buf = xmalloc (strlen (options) + 1);
-      size_t prepended = prepend_args (options, buf, NULL);
-      int argc = *pargc;
-      char *const *argv = *pargv;
-      char **pp;
-      enum { MAX_ARGS = MIN (INT_MAX, SIZE_MAX / sizeof *pp - 1) };
-      if (MAX_ARGS - argc < prepended)
-        xalloc_die ();
-      pp = xmalloc ((prepended + argc + 1) * sizeof *pp);
-      *pargc = prepended + argc;
-      *pargv = pp;
-      *pp++ = *argv++;
-      pp += prepend_args (options, buf, pp);
-      while ((*pp++ = *argv++))
-        continue;
-      return prepended;
-    }
-
-  return 0;
-}
-
-/* Get the next non-digit option from ARGC and ARGV.
-   Return -1 if there are no more options.
-   Process any digit options that were encountered on the way,
-   and store the resulting integer into *DEFAULT_CONTEXT.  */
-static int
-get_nondigit_option (int argc, char *const *argv, intmax_t *default_context)
-{
-  static int prev_digit_optind = -1;
-  int this_digit_optind, was_digit;
-  char buf[INT_BUFSIZE_BOUND (intmax_t) + 4];
-  char *p = buf;
-  int opt;
-
-  was_digit = 0;
-  this_digit_optind = optind;
-  while (1)
-    {
-      opt = getopt_long (argc, (char **) argv, short_options,
-                         long_options, NULL);
-      if ( ! ('0' <= opt && opt <= '9'))
-        break;
-
-      if (prev_digit_optind != this_digit_optind || !was_digit)
-        {
-          /* Reset to start another context length argument.  */
-          p = buf;
-        }
-      else
-        {
-          /* Suppress trivial leading zeros, to avoid incorrect
-             diagnostic on strings like 00000000000.  */
-          p -= buf[0] == '0';
-        }
-
-      if (p == buf + sizeof buf - 4)
-        {
-          /* Too many digits.  Append "..." to make context_length_arg
-             complain about "X...", where X contains the digits seen
-             so far.  */
-          strcpy (p, "...");
-          p += 3;
-          break;
-        }
-      *p++ = opt;
-
-      was_digit = 1;
-      prev_digit_optind = this_digit_optind;
-      this_digit_optind = optind;
-    }
-  if (p != buf)
-    {
-      *p = '\0';
-      context_length_arg (buf, default_context);
-    }
-
-  return opt;
-}
-
-/* Parse GREP_COLORS.  The default would look like:
-     GREP_COLORS='ms=01;31:mc=01;31:sl=:cx=:fn=35:ln=32:bn=32:se=36'
-   with boolean capabilities (ne and rv) unset (i.e., omitted).
-   No character escaping is needed or supported.  */
-static void
-parse_grep_colors (void)
-{
-  const char *p;
-  char *q;
-  char *name;
-  char *val;
-
-  p = getenv ("GREP_COLORS"); /* Plural! */
-  if (p == NULL || *p == '\0')
-    return;
-
-  /* Work off a writable copy.  */
-  q = xstrdup (p);
-
-  name = q;
-  val = NULL;
-  /* From now on, be well-formed or you're gone.  */
-  for (;;)
-    if (*q == ':' || *q == '\0')
-      {
-        char c = *q;
-        struct color_cap const *cap;
-
-        *q++ = '\0'; /* Terminate name or val.  */
-        /* Empty name without val (empty cap)
-         * won't match and will be ignored.  */
-        for (cap = color_dict; cap->name; cap++)
-          if (STREQ (cap->name, name))
-            break;
-        /* If name unknown, go on for forward compatibility.  */
-        if (cap->var && val)
-          *(cap->var) = val;
-        if (cap->fct)
-          cap->fct ();
-        if (c == '\0')
-          return;
-        name = q;
-        val = NULL;
-      }
-    else if (*q == '=')
-      {
-        if (q == name || val)
-          return;
-        *q++ = '\0'; /* Terminate name.  */
-        val = q; /* Can be the empty string.  */
-      }
-    else if (val == NULL)
-      q++; /* Accumulate name.  */
-    else if (*q == ';' || (*q >= '0' && *q <= '9'))
-      q++; /* Accumulate val.  Protect the terminal from being sent crap.  */
-    else
-      return;
-}
-
-int
-main (int argc, char **argv)
-{
-  char *keys;
-  size_t keycc, oldcc, keyalloc;
-  int with_filenames;
-  size_t cc;
-  int opt, status, prepended;
-  int prev_optind, last_recursive;
-  int fread_errno;
-  intmax_t default_context;
-  FILE *fp;
-  exit_failure = EXIT_TROUBLE;
-  initialize_main (&argc, &argv);
-  set_program_name (argv[0]);
-  program_name = argv[0];
-
-  keys = NULL;
-  keycc = 0;
-  with_filenames = 0;
-  eolbyte = '\n';
-  filename_mask = ~0;
-
-  max_count = INTMAX_MAX;
-
-  /* The value -1 means to use DEFAULT_CONTEXT. */
-  out_after = out_before = -1;
-  /* Default before/after context: changed by -C/-NUM options */
-  default_context = 0;
-  /* Changed by -o option */
-  only_matching = 0;
-
-  /* Internationalization. */
-#if defined HAVE_SETLOCALE
-  setlocale (LC_ALL, "");
-#endif
-#if defined ENABLE_NLS
-  bindtextdomain (PACKAGE, LOCALEDIR);
-  textdomain (PACKAGE);
-#endif
-
-  exit_failure = EXIT_TROUBLE;
-  atexit (clean_up_stdout);
-
-  last_recursive = 0;
-  prepended = prepend_default_options (getenv ("GREP_OPTIONS"), &argc, &argv);
-  setmatcher (NULL);
-
-  while (prev_optind = optind,
-         (opt = get_nondigit_option (argc, argv, &default_context)) != -1)
-    switch (opt)
-      {
-      case 'A':
-        context_length_arg (optarg, &out_after);
-        break;
-
-      case 'B':
-        context_length_arg (optarg, &out_before);
-        break;
-
-      case 'C':
-        /* Set output match context, but let any explicit leading or
-           trailing amount specified with -A or -B stand. */
-        context_length_arg (optarg, &default_context);
-        break;
-
-      case 'D':
-        if (STREQ (optarg, "read"))
-          devices = READ_DEVICES;
-        else if (STREQ (optarg, "skip"))
-          devices = SKIP_DEVICES;
-        else
-          error (EXIT_TROUBLE, 0, _("unknown devices method"));
-        break;
-
-      case 'E':
-        setmatcher ("egrep");
-        break;
-
-      case 'F':
-        setmatcher ("fgrep");
-        break;
-
-      case 'P':
-        setmatcher ("perl");
-        break;
-
-      case 'G':
-        setmatcher ("grep");
-        break;
-
-      case 'X': /* undocumented on purpose */
-        setmatcher (optarg);
-        break;
-
-      case 'H':
-        with_filenames = 1;
-        no_filenames = 0;
-        break;
-
-      case 'I':
-        binary_files = WITHOUT_MATCH_BINARY_FILES;
-        break;
-
-      case 'T':
-        align_tabs = 1;
-        break;
-
-      case 'U':
-#if defined HAVE_DOS_FILE_CONTENTS
-        dos_use_file_type = DOS_BINARY;
-#endif
-        break;
-
-      case 'u':
-#if defined HAVE_DOS_FILE_CONTENTS
-        dos_report_unix_offset = 1;
-#endif
-        break;
-
-      case 'V':
-        show_version = 1;
-        break;
-
-      case 'a':
-        binary_files = TEXT_BINARY_FILES;
-        break;
-
-      case 'b':
-        out_byte = 1;
-        break;
-
-      case 'c':
-        count_matches = 1;
-        break;
-
-      case 'd':
-        directories = XARGMATCH ("--directories", optarg,
-                                 directories_args, directories_types);
-        if (directories == RECURSE_DIRECTORIES)
-          last_recursive = prev_optind;
-        break;
-
-      case 'e':
-        cc = strlen (optarg);
-        keys = xrealloc (keys, keycc + cc + 1);
-        strcpy (&keys[keycc], optarg);
-        keycc += cc;
-        keys[keycc++] = '\n';
-        break;
-
-      case 'f':
-        fp = STREQ (optarg, "-") ? stdin : fopen (optarg, "r");
-        if (!fp)
-          error (EXIT_TROUBLE, errno, "%s", optarg);
-        for (keyalloc = 1; keyalloc <= keycc + 1; keyalloc *= 2)
-          ;
-        keys = xrealloc (keys, keyalloc);
-        oldcc = keycc;
-        while ((cc = fread (keys + keycc, 1, keyalloc - 1 - keycc, fp)) != 0)
-          {
-            keycc += cc;
-            if (keycc == keyalloc - 1)
-              keys = x2nrealloc (keys, &keyalloc, sizeof *keys);
-          }
-        fread_errno = errno;
-        if (ferror (fp))
-          error (EXIT_TROUBLE, fread_errno, "%s", optarg);
-        if (fp != stdin)
-          fclose (fp);
-        /* Append final newline if file ended in non-newline. */
-        if (oldcc != keycc && keys[keycc - 1] != '\n')
-          keys[keycc++] = '\n';
-        break;
-
-      case 'h':
-        with_filenames = 0;
-        no_filenames = 1;
-        break;
-
-      case 'i':
-      case 'y':                        /* For old-timers . . . */
-        match_icase = 1;
-        break;
-
-      case 'L':
-        /* Like -l, except list files that don't contain matches.
-           Inspired by the same option in Hume's gre. */
-        list_files = -1;
-        break;
-
-      case 'l':
-        list_files = 1;
-        break;
-
-      case 'm':
-        switch (xstrtoimax (optarg, 0, 10, &max_count, ""))
-          {
-          case LONGINT_OK:
-          case LONGINT_OVERFLOW:
-            break;
-
-          default:
-            error (EXIT_TROUBLE, 0, _("invalid max count"));
-          }
-        break;
-
-      case 'n':
-        out_line = 1;
-        break;
-
-      case 'o':
-        only_matching = 1;
-        break;
-
-      case 'q':
-        exit_on_match = 1;
-        exit_failure = 0;
-        break;
-
-      case 'R':
-        fts_options = basic_fts_options | FTS_LOGICAL;
-        /* Fall through.  */
-      case 'r':
-        directories = RECURSE_DIRECTORIES;
-        last_recursive = prev_optind;
-        break;
-
-      case 's':
-        suppress_errors = 1;
-        break;
-
-      case 'v':
-        out_invert = 1;
-        break;
-
-      case 'w':
-        match_words = 1;
-        break;
-
-      case 'x':
-        match_lines = 1;
-        break;
-
-      case 'Z':
-        filename_mask = 0;
-        break;
-
-      case 'z':
-        eolbyte = '\0';
-        break;
-
-      case BINARY_FILES_OPTION:
-        if (STREQ (optarg, "binary"))
-          binary_files = BINARY_BINARY_FILES;
-        else if (STREQ (optarg, "text"))
-          binary_files = TEXT_BINARY_FILES;
-        else if (STREQ (optarg, "without-match"))
-          binary_files = WITHOUT_MATCH_BINARY_FILES;
-        else
-          error (EXIT_TROUBLE, 0, _("unknown binary-files type"));
-        break;
-
-      case COLOR_OPTION:
-        if (optarg)
-          {
-            if (!strcasecmp (optarg, "always") || !strcasecmp (optarg, "yes")
-                || !strcasecmp (optarg, "force"))
-              color_option = 1;
-            else if (!strcasecmp (optarg, "never") || !strcasecmp (optarg, "no")
-                     || !strcasecmp (optarg, "none"))
-              color_option = 0;
-            else if (!strcasecmp (optarg, "auto") || !strcasecmp (optarg, "tty")
-                     || !strcasecmp (optarg, "if-tty"))
-              color_option = 2;
-            else
-              show_help = 1;
-          }
-        else
-          color_option = 2;
-        break;
-
-      case EXCLUDE_OPTION:
-      case INCLUDE_OPTION:
-        if (!excluded_patterns)
-          excluded_patterns = new_exclude ();
-        add_exclude (excluded_patterns, optarg,
-                     (EXCLUDE_WILDCARDS
-                      | (opt == INCLUDE_OPTION ? EXCLUDE_INCLUDE : 0)));
-        break;
-      case EXCLUDE_FROM_OPTION:
-        if (!excluded_patterns)
-          excluded_patterns = new_exclude ();
-        if (add_exclude_file (add_exclude, excluded_patterns, optarg,
-                              EXCLUDE_WILDCARDS, '\n') != 0)
-          {
-            error (EXIT_TROUBLE, errno, "%s", optarg);
-          }
-        break;
-
-      case EXCLUDE_DIRECTORY_OPTION:
-        if (!excluded_directory_patterns)
-          excluded_directory_patterns = new_exclude ();
-        add_exclude (excluded_directory_patterns, optarg, EXCLUDE_WILDCARDS);
-        break;
-
-      case GROUP_SEPARATOR_OPTION:
-        group_separator = optarg;
-        break;
-
-      case LINE_BUFFERED_OPTION:
-        line_buffered = 1;
-        break;
-
-      case LABEL_OPTION:
-        label = optarg;
-        break;
-
-      case MMAP_OPTION:
-        error (0, 0, _("the --mmap option has been a no-op since 2010"));
-        break;
-
-      case 0:
-        /* long options */
-        break;
-
-      default:
-        usage (EXIT_TROUBLE);
-        break;
-
-      }
-
-  if (color_option == 2)
-    color_option = isatty (STDOUT_FILENO) && should_colorize ();
-  init_colorize ();
-
-  /* POSIX says that -q overrides -l, which in turn overrides the
-     other output options.  */
-  if (exit_on_match)
-    list_files = 0;
-  if (exit_on_match | list_files)
-    {
-      count_matches = 0;
-      done_on_match = 1;
-    }
-  out_quiet = count_matches | done_on_match;
-
-  if (out_after < 0)
-    out_after = default_context;
-  if (out_before < 0)
-    out_before = default_context;
-
-  if (color_option)
-    {
-      /* Legacy.  */
-      char *userval = getenv ("GREP_COLOR");
-      if (userval != NULL && *userval != '\0')
-        selected_match_color = context_match_color = userval;
-
-      /* New GREP_COLORS has priority.  */
-      parse_grep_colors ();
-    }
-
-  if (show_version)
-    {
-      version_etc (stdout, program_name, PACKAGE_NAME, VERSION, AUTHORS,
-                   (char *) NULL);
-      exit (EXIT_SUCCESS);
-    }
-
-  if (show_help)
-    usage (EXIT_SUCCESS);
-
-  struct stat tmp_stat;
-  if (fstat (STDOUT_FILENO, &tmp_stat) == 0 && S_ISREG (tmp_stat.st_mode))
-    out_stat = tmp_stat;
-
-  if (keys)
-    {
-      if (keycc == 0)
-        {
-          /* No keys were specified (e.g. -f /dev/null).  Match nothing.  */
-          out_invert ^= 1;
-          match_lines = match_words = 0;
-        }
-      else
-        /* Strip trailing newline. */
-        --keycc;
-    }
-  else if (optind < argc)
-    {
-      /* A copy must be made in case of an xrealloc() or free() later.  */
-      keycc = strlen (argv[optind]);
-      keys = xmemdup (argv[optind++], keycc + 1);
-    }
-  else
-    usage (EXIT_TROUBLE);
-
-  compile (keys, keycc);
-  free (keys);
-
-  if ((argc - optind > 1 && !no_filenames) || with_filenames)
-    out_file = 1;
-
-#ifdef SET_BINARY
-  /* Output is set to binary mode because we shouldn't convert
-     NL to CR-LF pairs, especially when grepping binary files.  */
-  if (!isatty (1))
-    SET_BINARY (1);
-#endif
-
-  if (max_count == 0)
-    exit (EXIT_FAILURE);
-
-  if (fts_options & FTS_LOGICAL && devices == READ_COMMAND_LINE_DEVICES)
-    devices = READ_DEVICES;
-
-  if (optind < argc)
-    {
-      status = 1;
-      do
-        status &= grep_command_line_arg (argv[optind]);
-      while (++optind < argc);
-    }
-  else if (directories == RECURSE_DIRECTORIES && prepended < last_recursive)
-    {
-      /* Grep through ".", omitting leading "./" from diagnostics.  */
-      filename_prefix_len = 2;
-      status = grep_command_line_arg (".");
-    }
-  else
-    status = grep_command_line_arg ("-");
-
-  /* We register via atexit() to test stdout.  */
-  exit (errseen ? EXIT_TROUBLE : status);
-}
-/* vim:set shiftwidth=2: */
diff --git a/src/mbsupport.h b/src/mbsupport.h
deleted file mode 100644 (file)
index 49c7926..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/* mbsupport.h --- Localize determination of whether we have multibyte stuff.
-
-   Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3, or (at your option)
-   any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
-   02110-1301, USA.  */
-
-#include <stdlib.h>
-
-#ifndef MBS_SUPPORT
-# define MBS_SUPPORT 1
-#endif
-
-#if ! MBS_SUPPORT
-# undef MB_CUR_MAX
-# define MB_CUR_MAX 1
-#endif
index 5b5ba3e..820dd00 100644 (file)
@@ -25,9 +25,6 @@
 #elif HAVE_PCRE_PCRE_H
 # include <pcre/pcre.h>
 #endif
-#if HAVE_LANGINFO_CODESET
-# include <langinfo.h>
-#endif
 
 #if HAVE_LIBPCRE
 /* Compiled internal form of a Perl regular expression.  */
@@ -54,30 +51,23 @@ Pcompile (char const *pattern, size_t size)
   int e;
   char const *ep;
   char *re = xnmalloc (4, size + 7);
-  int flags = PCRE_MULTILINE | (match_icase ? PCRE_CASELESS : 0);
+  int flags = (PCRE_MULTILINE
+               | (match_icase ? PCRE_CASELESS : 0)
+               | (using_utf8 () ? PCRE_UTF8 : 0));
   char const *patlim = pattern + size;
   char *n = re;
   char const *p;
   char const *pnul;
 
-# if defined HAVE_LANGINFO_CODESET
-  if (STREQ (nl_langinfo (CODESET), "UTF-8"))
-    {
-      /* Enable PCRE's UTF-8 matching.  Note also the use of
-         PCRE_NO_UTF8_CHECK when calling pcre_extra, below.   */
-      flags |= PCRE_UTF8;
-    }
-# endif
-
   /* FIXME: Remove these restrictions.  */
   if (memchr (pattern, '\n', size))
     error (EXIT_TROUBLE, 0, _("the -P option only supports a single pattern"));
 
   *n = '\0';
   if (match_lines)
-    strcpy (n, "^(");
+    strcpy (n, "^(?:");
   if (match_words)
-    strcpy (n, "\\b(");
+    strcpy (n, "(?<!\\w)(?:");
   n += strlen (n);
 
   /* The PCRE interface doesn't allow NUL bytes in the pattern, so
@@ -103,7 +93,7 @@ Pcompile (char const *pattern, size_t size)
   n += patlim - p;
   *n = '\0';
   if (match_words)
-    strcpy (n, ")\\b");
+    strcpy (n, ")(?!\\w)");
   if (match_lines)
     strcpy (n, ")$");
 
@@ -158,10 +148,6 @@ Pexecute (char const *buf, size_t size, size_t *match_size,
        e == PCRE_ERROR_NOMATCH && line_next < buf + size;
        start_ofs -= line_next - line_buf)
     {
-      /* Disable the check that would make an invalid byte
-         seqence *in the input* trigger a failure.   */
-      int options = PCRE_NO_UTF8_CHECK;
-
       line_buf = line_next;
       line_end = memchr (line_buf, eolbyte, (buf + size) - line_buf);
       if (line_end == NULL)
@@ -176,7 +162,7 @@ Pexecute (char const *buf, size_t size, size_t *match_size,
         error (EXIT_TROUBLE, 0, _("exceeded PCRE's line length limit"));
 
       e = pcre_exec (cre, extra, line_buf, line_end - line_buf,
-                     start_ofs < 0 ? 0 : start_ofs, options,
+                     start_ofs < 0 ? 0 : start_ofs, 0,
                      sub, sizeof sub / sizeof *sub);
     }
 
index 61dcf95..14877bc 100644 (file)
@@ -23,9 +23,6 @@
 
 #include <sys/types.h>
 #include <stdint.h>
-
-#include "mbsupport.h"
-
 #include <wchar.h>
 #include <wctype.h>
 #include <regex.h>
@@ -33,6 +30,7 @@
 #include "system.h"
 #include "error.h"
 #include "grep.h"
+#include "dfa.h"
 #include "kwset.h"
 #include "xalloc.h"
 
@@ -45,8 +43,11 @@ typedef signed char mb_len_map_t;
 /* searchutils.c */
 extern void kwsinit (kwset_t *);
 
-extern char *mbtolower (const char *, size_t *, mb_len_map_t **);
-extern bool is_mb_middle (const char **, const char *, const char *, size_t);
+extern char *mbtoupper (char const *, size_t *, mb_len_map_t **);
+extern void build_mbclen_cache (void);
+extern ptrdiff_t mb_goback (char const **, char const *, char const *);
+extern wint_t mb_prev_wc (char const *, char const *, char const *);
+extern wint_t mb_next_wc (char const *, char const *);
 
 /* dfasearch.c */
 extern void GEAcompile (char const *, size_t, reg_syntax_t);
@@ -60,23 +61,4 @@ extern size_t Fexecute (char const *, size_t, size_t *, char const *);
 extern void Pcompile (char const *, size_t);
 extern size_t Pexecute (char const *, size_t, size_t *, char const *);
 
-/* Apply the MAP (created by mbtolower) to the lowercase-buffer-relative
-   *OFF and *LEN, converting them to be relative to the original buffer.  */
-static inline void
-mb_case_map_apply (mb_len_map_t const *map, size_t *off, size_t *len)
-{
-  if (map)
-    {
-      intmax_t off_incr = 0;
-      intmax_t len_incr = 0;
-      size_t k;
-      for (k = 0; k < *off; k++)
-        off_incr += map[k];
-      for (k = *off; k < *off + *len; k++)
-        len_incr += map[k];
-      *off += off_incr;
-      *len += len_incr;
-    }
-}
-
 #endif /* GREP_SEARCH_H */
index 778f4ad..18dd584 100644 (file)
@@ -22,6 +22,8 @@
 
 #define NCHAR (UCHAR_MAX + 1)
 
+static size_t mbclen_cache[NCHAR];
+
 void
 kwsinit (kwset_t *kwset)
 {
@@ -31,7 +33,7 @@ kwsinit (kwset_t *kwset)
   if (match_icase && MB_CUR_MAX == 1)
     {
       for (i = 0; i < NCHAR; ++i)
-        trans[i] = tolower (i);
+        trans[i] = toupper (i);
 
       *kwset = kwsalloc (trans);
     }
@@ -42,39 +44,37 @@ kwsinit (kwset_t *kwset)
     xalloc_die ();
 }
 
-#if MBS_SUPPORT
-/* Convert the *N-byte string, BEG, to lower-case, and write the
+/* Convert BEG, an *N-byte string, to uppercase, and write the
    NUL-terminated result into malloc'd storage.  Upon success, set *N
    to the length (in bytes) of the resulting string (not including the
-   trailing NUL byte), and return a pointer to the lower-case string.
-   Upon memory allocation failure, this function exits.
-   Note that on input, *N must be larger than zero.
+   trailing NUL byte), and return a pointer to the uppercase string.
+   Upon memory allocation failure, exit.  *N must be positive.
 
-   Note that while this function returns a pointer to malloc'd storage,
+   Although this function returns a pointer to malloc'd storage,
    the caller must not free it, since this function retains a pointer
    to the buffer and reuses it on any subsequent call.  As a consequence,
    this function is not thread-safe.
 
-   When each character in the lower-case result string has the same length
+   When each character in the uppercase result string has the same length
    as the corresponding character in the input string, set *LEN_MAP_P
    to NULL.  Otherwise, set it to a malloc'd buffer (like the returned
    buffer, this must not be freed by caller) of the same length as the
    result string.  (*LEN_MAP_P)[J] is the change in byte-length of the
    character in BEG that formed byte J of the result as it was converted to
-   lower-case.  It is usually zero.  For the upper-case Turkish I-with-dot
-   it is -1, since the upper-case character occupies two bytes, while the
-   lower-case one occupies only one byte.  For the Turkish-I-without-dot
-   in the tr_TR.utf8 locale, it is 1 because the lower-case representation
+   uppercase.  It is usually zero.  For lowercase Turkish dotless I it
+   is -1, since the lowercase input occupies two bytes, while the
+   uppercase output occupies only one byte.  For lowercase I in the
+   tr_TR.utf8 locale, it is 1 because the uppercase Turkish dotted I
    is one byte longer than the original.  When that happens, we have two
    or more slots in *LEN_MAP_P for each such character.  We store the
    difference in the first one and 0's in any remaining slots.
 
    This map is used by the caller to convert offset,length pairs that
-   reference the lower-case result to numbers that refer to the matched
+   reference the uppercase result to numbers that refer to the matched
    part of the original buffer.  */
 
 char *
-mbtolower (const char *beg, size_t *n, mb_len_map_t **len_map_p)
+mbtoupper (const char *beg, size_t *n, mb_len_map_t **len_map_p)
 {
   static char *out;
   static mb_len_map_t *len_map;
@@ -88,7 +88,7 @@ mbtolower (const char *beg, size_t *n, mb_len_map_t **len_map_p)
 
   if (*n > outalloc || outalloc == 0)
     {
-      outalloc = MAX(1, *n);
+      outalloc = MAX (1, *n);
       out = xrealloc (out, outalloc);
       len_map = xrealloc (len_map, outalloc);
     }
@@ -169,8 +169,8 @@ mbtolower (const char *beg, size_t *n, mb_len_map_t **len_map_p)
           /* Handle Unicode characters beyond the base plane.  */
           if (mbclen == 4)
             {
-              /* towlower, taking wint_t (4 bytes), handles UCS-4 values.  */
-              wci = towlower (wci);
+              /* towupper, taking wint_t (4 bytes), handles UCS-4 values.  */
+              wci = towupper (wci);
               if (wci >= 0x10000)
                 {
                   wci -= 0x10000;
@@ -191,7 +191,7 @@ mbtolower (const char *beg, size_t *n, mb_len_map_t **len_map_p)
             }
           else
 #endif
-          ombclen = wcrtomb (p, towlower ((wint_t) wc), &os);
+          ombclen = wcrtomb (p, towupper (wc), &os);
           *m = mbclen - ombclen;
           memset (m + 1, 0, ombclen - 1);
           m += ombclen;
@@ -207,41 +207,84 @@ mbtolower (const char *beg, size_t *n, mb_len_map_t **len_map_p)
   return out;
 }
 
+/* Initialize a cache of mbrlen values for each of its 1-byte inputs.  */
+void
+build_mbclen_cache (void)
+{
+  int i;
+
+  for (i = CHAR_MIN; i <= CHAR_MAX; ++i)
+    {
+      char c = i;
+      unsigned char uc = i;
+      mbstate_t mbs = { 0 };
+      mbclen_cache[uc] = mbrlen (&c, 1, &mbs);
+    }
+}
 
-bool
-is_mb_middle (const char **good, const char *buf, const char *end,
-              size_t match_len)
+/* In the buffer *MB_START, return the number of bytes needed to go
+   back from CUR to the previous boundary, where a "boundary" is the
+   start of a multibyte character or is an error-encoding byte.  The
+   buffer ends at END (i.e., one past the address of the buffer's last
+   byte).  If CUR is already at a boundary, return 0.  If *MB_START is
+   greater than or equal to CUR, return the negative value CUR - *MB_START.
+
+   When returning zero, set *MB_START to CUR.  When returning a
+   positive value, set *MB_START to the next boundary after CUR, or to
+   END if there is no such boundary.  When returning a negative value,
+   leave *MB_START alone.  */
+ptrdiff_t
+mb_goback (char const **mb_start, char const *cur, char const *end)
 {
-  const char *p = *good;
-  const char *prev = p;
+  const char *p = *mb_start;
+  const char *p0 = p;
   mbstate_t cur_state;
 
-  /* TODO: can be optimized for UTF-8.  */
-  memset(&cur_state, 0, sizeof(mbstate_t));
-  while (p < buf)
+  memset (&cur_state, 0, sizeof cur_state);
+
+  while (p < cur)
     {
-      size_t mbclen = mbrlen(p, end - p, &cur_state);
+      size_t mbclen = mbclen_cache[to_uchar (*p)];
 
-      /* Store the beginning of the previous complete multibyte character.  */
-      if (mbclen != (size_t) -2)
-        prev = p;
+      if (mbclen == (size_t) -2)
+        mbclen = mbrlen (p, end - p, &cur_state);
 
-      if (mbclen == (size_t) -1 || mbclen == (size_t) -2 || mbclen == 0)
+      if (! (0 < mbclen && mbclen < (size_t) -2))
         {
-          /* An invalid sequence, or a truncated multibyte character.
-             We treat it as a single byte character.  */
+          /* An invalid sequence, or a truncated multibyte character, or
+             a null wide character.  Treat it as a single byte character.  */
           mbclen = 1;
-          memset(&cur_state, 0, sizeof cur_state);
+          memset (&cur_state, 0, sizeof cur_state);
         }
+      p0 = p;
       p += mbclen;
     }
 
-  *good = prev;
+  *mb_start = p;
+  return p == cur ? 0 : cur - p0;
+}
 
-  if (p > buf)
-    return true;
+/* In the buffer BUF, return the wide character that is encoded just
+   before CUR.  The buffer ends at END.  Return WEOF if there is no
+   wide character just before CUR.  */
+wint_t
+mb_prev_wc (char const *buf, char const *cur, char const *end)
+{
+  if (cur == buf)
+    return WEOF;
+  char const *p = buf;
+  cur--;
+  cur -= mb_goback (&p, cur, end);
+  return mb_next_wc (cur, end);
+}
 
-  /* P == BUF here.  */
-  return 0 < match_len && match_len < mbrlen (p, end - p, &cur_state);
+/* Return the wide character that is encoded at CUR.  The buffer ends
+   at END.  Return WEOF if there is no wide character encoded at CUR.  */
+wint_t
+mb_next_wc (char const *cur, char const *end)
+{
+  wchar_t wc;
+  mbstate_t mbs = { 0 };
+  return (end - cur != 0 && mbrtowc (&wc, cur, end - cur, &mbs) < (size_t) -2
+          ? wc : WEOF);
 }
-#endif /* MBS_SUPPORT */
index b07471b..7da1d8d 100644 (file)
 #include "minmax.h"
 #include "same-inode.h"
 
-#if O_BINARY
-# define HAVE_DOS_FILE_CONTENTS 1
-#endif
-
 #include <stdlib.h>
 #include <stddef.h>
 #include <limits.h>
@@ -55,4 +51,13 @@ enum { EXIT_TROUBLE = 2 };
 
 #define STREQ(a, b) (strcmp (a, b) == 0)
 
+/* Convert a possibly-signed character to an unsigned character.  This is
+   a bit safer than casting to unsigned char, since it catches some type
+   errors that the cast doesn't.  */
+static inline unsigned char
+to_uchar (char ch)
+{
+  return ch;
+}
+
 #endif
index f4580b5..82a6d2d 100644 (file)
@@ -22,9 +22,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
 AM_LDFLAGS = $(IGNORE_UNUSED_LIBRARIES_CFLAGS)
 LDADD = ../lib/libgreputils.a $(LIBINTL) ../lib/libgreputils.a
 
-# Remove this definition once the failing test passes.
-XFAIL_TESTS = \
-  word-delim-multibyte
+XFAIL_TESTS =
 
 # Equivalence classes are only supported when using the system
 # matcher (which means only with glibc).
@@ -47,12 +45,16 @@ TESTS =                                             \
   case-fold-char-class                         \
   case-fold-char-range                         \
   case-fold-char-type                          \
+  case-fold-titlecase                          \
   char-class-multibyte                         \
   char-class-multibyte2                                \
+  context-0                                    \
+  count-newline                                        \
   dfa-coverage                                 \
   dfa-heap-overrun                             \
   dfaexec-multibyte                            \
   empty                                                \
+  empty-line                                   \
   epipe                                                \
   equiv-classes                                        \
   ere                                          \
@@ -65,7 +67,6 @@ TESTS =                                               \
   grep-dev-null                                        \
   grep-dir                                     \
   help-version                                 \
-  ignore-mmap                                  \
   in-eq-out-infloop                            \
   include-exclude                              \
   inconsistent-range                           \
@@ -73,16 +74,23 @@ TESTS =                                             \
   khadafy                                      \
   long-line-vs-2GiB-read                       \
   max-count-vs-context                         \
+  mb-non-UTF8-performance                      \
   multibyte-white-space                                \
+  null-byte                                    \
   empty-line-mb                                        \
   unibyte-bracket-expr                         \
+  unibyte-negated-circumflex                   \
   high-bit-range                               \
   options                                      \
   pcre                                         \
   pcre-abort                                   \
+  pcre-infloop                                 \
   pcre-invalid-utf8-input                      \
   pcre-utf8                                    \
+  pcre-w                                       \
+  pcre-wx-backref                              \
   pcre-z                                       \
+  posix-bracket                                        \
   prefix-of-multibyte                          \
   r-dot                                                \
   repetition-overflow                          \
@@ -94,6 +102,7 @@ TESTS =                                              \
   status                                       \
   surrogate-pair                               \
   symlink                                      \
+  turkish-eyes                                 \
   turkish-I                                    \
   turkish-I-without-dot                                \
   warn-char-classes                            \
index 0d97f3b..2c543aa 100644 (file)
@@ -1,7 +1,7 @@
 # Makefile.in generated by automake 1.99a from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+# Copyright (C) 1994-2014 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1236,6 +1236,7 @@ REPLACE_WCTOB = @REPLACE_WCTOB@
 REPLACE_WCTOMB = @REPLACE_WCTOMB@
 REPLACE_WCWIDTH = @REPLACE_WCWIDTH@
 REPLACE_WRITE = @REPLACE_WRITE@
+SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@
@@ -1326,9 +1327,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
 # Tell the linker to omit references to unused shared libraries.
 AM_LDFLAGS = $(IGNORE_UNUSED_LIBRARIES_CFLAGS)
 LDADD = ../lib/libgreputils.a $(LIBINTL) ../lib/libgreputils.a
-
-# Remove this definition once the failing test passes.
-XFAIL_TESTS = word-delim-multibyte $(am__append_1)
+XFAIL_TESTS = $(am__append_1)
 TESTS = \
   backref                                      \
   backref-multibyte-slow                       \
@@ -1344,12 +1343,16 @@ TESTS = \
   case-fold-char-class                         \
   case-fold-char-range                         \
   case-fold-char-type                          \
+  case-fold-titlecase                          \
   char-class-multibyte                         \
   char-class-multibyte2                                \
+  context-0                                    \
+  count-newline                                        \
   dfa-coverage                                 \
   dfa-heap-overrun                             \
   dfaexec-multibyte                            \
   empty                                                \
+  empty-line                                   \
   epipe                                                \
   equiv-classes                                        \
   ere                                          \
@@ -1362,7 +1365,6 @@ TESTS = \
   grep-dev-null                                        \
   grep-dir                                     \
   help-version                                 \
-  ignore-mmap                                  \
   in-eq-out-infloop                            \
   include-exclude                              \
   inconsistent-range                           \
@@ -1370,16 +1372,23 @@ TESTS = \
   khadafy                                      \
   long-line-vs-2GiB-read                       \
   max-count-vs-context                         \
+  mb-non-UTF8-performance                      \
   multibyte-white-space                                \
+  null-byte                                    \
   empty-line-mb                                        \
   unibyte-bracket-expr                         \
+  unibyte-negated-circumflex                   \
   high-bit-range                               \
   options                                      \
   pcre                                         \
   pcre-abort                                   \
+  pcre-infloop                                 \
   pcre-invalid-utf8-input                      \
   pcre-utf8                                    \
+  pcre-w                                       \
+  pcre-wx-backref                              \
   pcre-z                                       \
+  posix-bracket                                        \
   prefix-of-multibyte                          \
   r-dot                                                \
   repetition-overflow                          \
@@ -1391,6 +1400,7 @@ TESTS = \
   status                                       \
   surrogate-pair                               \
   symlink                                      \
+  turkish-eyes                                 \
   turkish-I                                    \
   turkish-I-without-dot                                \
   warn-char-classes                            \
@@ -1478,7 +1488,6 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
        echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/Makefile'; \
        $(am__cd) $(top_srcdir) && \
          $(AUTOMAKE) --gnu tests/Makefile
-.PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @case '$?' in \
          *config.status*) \
@@ -1610,7 +1619,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
        if test -n "$$am__remaking_logs"; then \
          echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
               "recursion detected" >&2; \
-       else \
+       elif test -n "$$redo_logs"; then \
          am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
        fi; \
        if $(am__make_dryrun); then :; else \
@@ -1819,6 +1828,13 @@ case-fold-char-type.log: case-fold-char-type
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+case-fold-titlecase.log: case-fold-titlecase
+       @p='case-fold-titlecase'; \
+       b='case-fold-titlecase'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 char-class-multibyte.log: char-class-multibyte
        @p='char-class-multibyte'; \
        b='char-class-multibyte'; \
@@ -1833,6 +1849,20 @@ char-class-multibyte2.log: char-class-multibyte2
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+context-0.log: context-0
+       @p='context-0'; \
+       b='context-0'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
+count-newline.log: count-newline
+       @p='count-newline'; \
+       b='count-newline'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 dfa-coverage.log: dfa-coverage
        @p='dfa-coverage'; \
        b='dfa-coverage'; \
@@ -1861,6 +1891,13 @@ empty.log: empty
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+empty-line.log: empty-line
+       @p='empty-line'; \
+       b='empty-line'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 epipe.log: epipe
        @p='epipe'; \
        b='epipe'; \
@@ -1945,13 +1982,6 @@ help-version.log: help-version
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
-ignore-mmap.log: ignore-mmap
-       @p='ignore-mmap'; \
-       b='ignore-mmap'; \
-       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
-       --log-file $$b.log --trs-file $$b.trs \
-       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
-       "$$tst" $(AM_TESTS_FD_REDIRECT)
 in-eq-out-infloop.log: in-eq-out-infloop
        @p='in-eq-out-infloop'; \
        b='in-eq-out-infloop'; \
@@ -2001,6 +2031,13 @@ max-count-vs-context.log: max-count-vs-context
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+mb-non-UTF8-performance.log: mb-non-UTF8-performance
+       @p='mb-non-UTF8-performance'; \
+       b='mb-non-UTF8-performance'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 multibyte-white-space.log: multibyte-white-space
        @p='multibyte-white-space'; \
        b='multibyte-white-space'; \
@@ -2008,6 +2045,13 @@ multibyte-white-space.log: multibyte-white-space
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+null-byte.log: null-byte
+       @p='null-byte'; \
+       b='null-byte'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 empty-line-mb.log: empty-line-mb
        @p='empty-line-mb'; \
        b='empty-line-mb'; \
@@ -2022,6 +2066,13 @@ unibyte-bracket-expr.log: unibyte-bracket-expr
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+unibyte-negated-circumflex.log: unibyte-negated-circumflex
+       @p='unibyte-negated-circumflex'; \
+       b='unibyte-negated-circumflex'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 high-bit-range.log: high-bit-range
        @p='high-bit-range'; \
        b='high-bit-range'; \
@@ -2050,6 +2101,13 @@ pcre-abort.log: pcre-abort
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+pcre-infloop.log: pcre-infloop
+       @p='pcre-infloop'; \
+       b='pcre-infloop'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 pcre-invalid-utf8-input.log: pcre-invalid-utf8-input
        @p='pcre-invalid-utf8-input'; \
        b='pcre-invalid-utf8-input'; \
@@ -2064,6 +2122,20 @@ pcre-utf8.log: pcre-utf8
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+pcre-w.log: pcre-w
+       @p='pcre-w'; \
+       b='pcre-w'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
+pcre-wx-backref.log: pcre-wx-backref
+       @p='pcre-wx-backref'; \
+       b='pcre-wx-backref'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 pcre-z.log: pcre-z
        @p='pcre-z'; \
        b='pcre-z'; \
@@ -2071,6 +2143,13 @@ pcre-z.log: pcre-z
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+posix-bracket.log: posix-bracket
+       @p='posix-bracket'; \
+       b='posix-bracket'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 prefix-of-multibyte.log: prefix-of-multibyte
        @p='prefix-of-multibyte'; \
        b='prefix-of-multibyte'; \
@@ -2148,6 +2227,13 @@ symlink.log: symlink
        --log-file $$b.log --trs-file $$b.trs \
        $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
        "$$tst" $(AM_TESTS_FD_REDIRECT)
+turkish-eyes.log: turkish-eyes
+       @p='turkish-eyes'; \
+       b='turkish-eyes'; \
+       $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+       --log-file $$b.log --trs-file $$b.trs \
+       $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+       "$$tst" $(AM_TESTS_FD_REDIRECT)
 turkish-I.log: turkish-I
        @p='turkish-I'; \
        b='turkish-I'; \
@@ -2358,6 +2444,8 @@ uninstall-am:
        mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
        recheck tags tags-am uninstall uninstall-am
 
+.PRECIOUS: Makefile
+
 
 check: check_executable_TESTS
 .PHONY: check_executable_TESTS
index 817957f..4c0eb13 100755 (executable)
--- a/tests/bre
+++ b/tests/bre
@@ -16,6 +16,6 @@ fail=0
 ${AWK-awk} -f $abs_top_srcdir/tests/bre.awk $abs_top_srcdir/tests/bre.tests \
     > bre.script || fail=1
 
-. ./bre.script || fail=1
+${re_shell-${SHELL-sh}} ./bre.script || fail=1
 
 Exit $fail
diff --git a/tests/case-fold-titlecase b/tests/case-fold-titlecase
new file mode 100755 (executable)
index 0000000..ba320c7
--- /dev/null
@@ -0,0 +1,190 @@
+#!/bin/sh
+# Check that case folding works even with titlecase and similarly odd chars.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+require_en_utf8_locale_
+require_compiled_in_MB_support
+LC_ALL=en_US.UTF-8
+export LC_ALL
+
+fail=0
+
+for testcase in \
+  0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
+do
+  case $testcase in
+    0)
+      a='\302\265'     # U+00B5
+      b='\316\234'     # U+039C
+      c='\316\274'     # U+03BC
+      ;;
+    1)
+      a='\111'         # U+0049
+      b='\151'         # U+0069
+      c='\304\260'     # U+0130
+      ;;
+    2)
+      a='\111'         # U+0049
+      b='\151'         # U+0069
+      c='\304\261'     # U+0131
+      ;;
+    3)
+      a='\123'         # U+0053
+      b='\163'         # U+0073
+      c='\305\277'     # U+017F
+      ;;
+    4)
+      a='\307\204'     # U+01C4
+      b='\307\205'     # U+01C5
+      c='\307\206'     # U+01C6
+      ;;
+    5)
+      a='\307\207'     # U+01C7
+      b='\307\210'     # U+01C8
+      c='\307\211'     # U+01C9
+      ;;
+    6)
+      a='\307\212'     # U+01CA
+      b='\307\213'     # U+01CB
+      c='\307\214'     # U+01CC
+      ;;
+    7)
+      a='\307\261'     # U+01F1
+      b='\307\262'     # U+01F2
+      c='\307\263'     # U+01F3
+      ;;
+    8)
+      a='\315\205'     # U+0345
+      b='\316\231'     # U+0399
+      c='\316\271'     # U+03B9
+      ;;
+    9)
+      a='\316\243'     # U+03A3
+      b='\317\202'     # U+03C2
+      c='\317\203'     # U+03C3
+      ;;
+    10)
+      a='\316\222'     # U+0392
+      b='\316\262'     # U+03B2
+      c='\317\220'     # U+03D0
+      ;;
+    11)
+      a='\316\230'     # U+0398
+      b='\316\270'     # U+03B8
+      c='\317\221'     # U+03D1
+      ;;
+    12)
+      a='\316\246'     # U+03A6
+      b='\317\206'     # U+03C6
+      c='\317\225'     # U+03D5
+      ;;
+    13)
+      a='\316\240'     # U+03A0
+      b='\317\200'     # U+03C0
+      c='\317\226'     # U+03D6
+      ;;
+    14)
+      a='\316\232'     # U+039A
+      b='\316\272'     # U+03BA
+      c='\317\260'     # U+03F0
+      ;;
+    15)
+      a='\316\241'     # U+03A1
+      b='\317\201'     # U+03C1
+      c='\317\261'     # U+03F1
+      ;;
+    16)
+      a='\316\230'     # U+0398
+      b='\316\270'     # U+03B8
+      c='\317\264'     # U+03F4
+      ;;
+    17)
+      a='\316\225'     # U+0395
+      b='\316\265'     # U+03B5
+      c='\317\265'     # U+03F5
+      ;;
+    18)
+      a='\341\271\240' # U+1E60
+      b='\341\271\241' # U+1E61
+      c='\341\272\233' # U+1E9B
+      ;;
+    19)
+      a='\303\237'     # U+00DF
+      b='\303\237'     # U+00DF
+      c='\341\272\236' # U+1E9E
+      ;;
+    20)
+      a='\316\231'     # U+0399
+      b='\316\271'     # U+03B9
+      c='\341\276\276' # U+1FBE
+      ;;
+    21)
+      a='\316\251'     # U+03A9
+      b='\317\211'     # U+03C9
+      c='\342\204\246' # U+2126
+      ;;
+    22)
+      a='\113'         # U+004B
+      b='\153'         # U+006B
+      c='\342\204\252' # U+212A
+      ;;
+    23)
+      a='\303\205'     # U+00C5
+      b='\303\245'     # U+00E5
+      c='\342\204\253' # U+212B
+      ;;
+    24)
+      a='\316\243'     # U+03A3
+      b='\317\203'     # U+03C3
+      c='\317\262'     # U+03F2
+      ;;
+  esac
+
+  printf "$a\\n$b\\n$c\\n" >in || framework_failure_
+  for pattern in "$a" "$b" "$c"; do
+     pat=$(printf "$pattern\\n") || framework_failure_
+     grep -i "\\(\\)\\1$pat" in >out-regex || fail=1
+     grep -i "$pat" in >out-dfa || fail=1
+     compare_ out-regex out-dfa || fail=1
+     grep -iF "$pat" in >out-fixed || fail=1
+     compare_ out-regex out-fixed || fail=1
+  done
+done
+
+# Try a unibyte test with ISO 8859-7, if available.
+if test "$(get-mb-cur-max el_GR.iso88597)" -eq 1; then
+  LC_ALL=el_GR.iso88597
+  export LC_ALL
+
+  a='\323' # SIGMA
+  b='\362' # stigma
+  c='\363' # sigma
+
+  printf "$a\\n$b\\n$c\\n" >in || framework_failure_
+  for pattern in "$a" "$b" "$c"; do
+     pat=$(printf "$pattern\\n") || framework_failure_
+     grep -i "\\(\\)\\1$pat" in >out-regex || fail=1
+     grep -i "$pat" in >out-dfa || fail=1
+     compare_ out-regex out-dfa || fail=1
+     grep -iF "$pat" in >out-fixed || fail=1
+     compare_ out-regex out-fixed || fail=1
+  done
+fi
+
+Exit $fail
diff --git a/tests/context-0 b/tests/context-0
new file mode 100755 (executable)
index 0000000..4b63305
--- /dev/null
@@ -0,0 +1,27 @@
+#!/bin/sh
+# 0 lines of context
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+cat <<EOF > in || framework_failure_
+needle
+1st line of context
+2nd line of context
+3rd line of context
+another needle
+5th line of context relative to first match
+6th line...
+EOF
+
+cat <<EOF > exp || framework_failure_
+needle
+--
+another needle
+EOF
+
+fail=0
+grep -C 0 needle in > out 2>err || fail=1
+
+compare exp out || fail=1
+compare /dev/null err || fail=1
+
+Exit $fail
diff --git a/tests/count-newline b/tests/count-newline
new file mode 100755 (executable)
index 0000000..fc8e9a8
--- /dev/null
@@ -0,0 +1,28 @@
+#!/bin/sh
+# Test that newline is counted correctly even when the transition
+# table is rebuilt.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+printf '%1024d\nb\n' 0 >in || framework_failure_
+
+grep -f in in >out || fail=1
+
+compare in out || fail=1
+
+Exit $fail
diff --git a/tests/empty-line b/tests/empty-line
new file mode 100755 (executable)
index 0000000..25e9509
--- /dev/null
@@ -0,0 +1,41 @@
+#! /bin/sh
+# Test that the empty pattern matches everything.
+# Some of these tests failed in grep 2.18.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+fail=0
+printf 'abc\n' >in || framework_failure_
+nl='
+'
+
+for opt in '' -E -F; do
+  case $opt in
+    '') prefix='\(\)\1';;
+    -E) prefix='()\1';;
+    -F) prefix="foo$nl";;
+  esac
+
+  for pattern in "" "$nl" "---$nl" "${nl}foo"; do
+    for pat in "$pattern" "$prefix$pattern"; do
+      grep $opt -e "$pat" in >out || fail=1
+      compare in out || fail=1
+
+      printf -- '%s\n' "$pat" >pat || framework_failure_
+      grep $opt -f pat in >out || fail=1
+      compare in out || fail=1
+
+      # Check that pattern files that end in non-newlines
+      # are treated as if a newline were appended.
+      case $pattern in
+        '' | *"$nl") ;;
+        *)
+          printf -- '%s' "$pat" >pat || framework_failure_
+          grep $opt -f pat in >out || fail=1
+          compare in out || fail=1;;
+      esac
+    done
+  done
+done
+
+Exit $fail
index 04e6a75..6ad7982 100755 (executable)
--- a/tests/ere
+++ b/tests/ere
@@ -16,6 +16,6 @@ fail=0
 ${AWK-awk} -f $abs_top_srcdir/tests/ere.awk $abs_top_srcdir/tests/ere.tests \
   > ere.script || fail=1
 
-${SHELL-sh} ere.script || fail=1
+${re_shell-${SHELL-sh}} ere.script || fail=1
 
 Exit $fail
index c0af220..aa254ca 100755 (executable)
@@ -30,7 +30,14 @@ fail=0
 # Does EUC-JP work at all?
 make_input BABA |euc_grep AB && fail=1
 
-# Whole line rejected after matching in the middle of a multibyte char?
-make_input BABAAB |euc_grep AB || fail=1
+# Here are two cases in which a KWSet search matches in the middle
+# of a multibyte character.  The first ensures that the DFA matcher
+# finds the real match at the end of line.  The second ensures that
+# while the KWSet match found a false positive, the DFA matcher
+# determines there is no match after all.
+make_input BABAAB |euc_grep AB > out || fail=1
+make_input BABAAB > exp || framework_failure_
+compare exp out || fail=1
+make_input BABABA |euc_grep AB; test $? = 1 || fail=1
 
 Exit $fail
index 07a0ce0..015ec74 100755 (executable)
@@ -8,14 +8,20 @@ require_compiled_in_MB_support
 
 encode() { echo "$1" | tr ABC '\357\274\241'; }
 
+encode ABC > in || framework_failure_
 fail=0
 
 for LOC in en_US.UTF-8 $LOCALE_FR_UTF8; do
   out=out1-$LOC
-  encode ABC \
-    | LC_ALL=$LOC timeout 10s grep -F "$(encode BC)" > $out 2>&1
-  test $? = 1 || fail=1
-  compare /dev/null $out || fail=1
+  LC_ALL=$LOC timeout 10s grep -F "$(encode BC)" in > $out
+  status=$?
+  if test $status -eq 0; then
+    compare in $out
+  elif test $status -eq 1; then
+    compare_dev_null_ /dev/null $out
+  else
+    test $status -eq 2
+  fi || fail=1
 done
 
 Exit $fail
diff --git a/tests/ignore-mmap b/tests/ignore-mmap
deleted file mode 100755 (executable)
index 8c40868..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/bin/sh
-# Ensure that --mmap is ignored
-. "${srcdir=.}/init.sh"; path_prepend_ ../src
-
-echo a > in || framework_failure_
-fail=0
-
-echo grep: the --mmap option has been a no-op since 2010 > exp
-
-grep --mmap a in > out 2> err || fail=1
-compare out in || fail=1
-compare exp err || fail=1
-
-grep --mmap b in > out 2>err
-# Expect no match and no output.
-test $? = 1 || fail=1
-compare /dev/null out || fail=1
-compare exp err || fail=1
-
-Exit $fail
index 2e8330b..3e9ab03 100644 (file)
@@ -87,6 +87,53 @@ require_compiled_in_MB_support()
     || skip_ this test requires MBS support
 }
 
+require_unibyte_locale()
+{
+  path_prepend_ .
+  for loc in C en_US; do
+    for encoding in '' .iso88591 .iso885915 .ISO8859-1 .ISO8859-15; do
+      locale=$loc$encoding
+      MB_CUR_MAX=$(get-mb-cur-max $locale 2>/dev/null) &&
+        test "$MB_CUR_MAX" -eq 1 &&
+        LC_ALL=$locale &&
+        export LC_ALL &&
+        return
+    done
+  done
+  skip_ 'no unibyte locale found'
+}
+
+# Define hi_res_time_ to a function that prints the current time
+# as a floating point number with greater than 1-second resolution.
+# Otherwise, skip the requiring test.
+require_hi_res_time_()
+{
+  local cmd
+  for cmd in 'date +%s.%N' \
+          'perl -le "use Time::HiRes qw(time); print scalar time()"'; do
+      case $($cmd) in
+          *.[0-9]*) eval 'hi_res_time_() { '"$cmd"'; }'; break;;
+      esac
+  done
+  type hi_res_time_ || skip_ no high-resolution timer support
+}
+
+require_JP_EUC_locale_()
+{
+  local locale=ja_JP.eucJP
+  path_prepend_ .
+  case $(get-mb-cur-max $locale) in
+    [23])
+        LC_ALL=$locale &&
+        export LC_ALL &&
+        return
+        ;;
+    *) ;;
+  esac
+
+  skip_ "$loc locale not found"
+}
+
 expensive_()
 {
   if test "$RUN_EXPENSIVE_TESTS" != yes; then
index b5c2e3f..fbd293d 100644 (file)
@@ -201,6 +201,8 @@ else
       *x*) opts_=-x ;;
       *) opts_= ;;
     esac
+    re_shell=$re_shell_
+    export re_shell
     exec "$re_shell_" $opts_ "$0" --no-reexec "$@"
     echo "$ME_: exec failed" 1>&2
     exit 127
index 487fef0..b28bc53 100755 (executable)
@@ -7,14 +7,21 @@ require_en_utf8_locale_
 require_compiled_in_MB_support
 require_timeout_
 
-printf '\202' > search-str || framework_failure_
-cat search-str search-str > input || framework_failure_
+encode() { echo "$1" | tr A '\202'; }
+
+encode AA > input
 
 fail=0
 
 # Before 2.15, this would infloop.
-LC_ALL=en_US.UTF-8 timeout 3 grep -F -f search-str input > out
-test $? = 1 || fail=1
-test -s out && fail=1
+LC_ALL=en_US.UTF-8 timeout 3 grep -F $(encode A) input > out
+status=$?
+if test $status -eq 0; then
+  compare input out
+elif test $status -eq 1; then
+  compare_dev_null_ /dev/null out
+else
+  test $status -eq 2
+fi || fail=1
 
 Exit $fail
diff --git a/tests/mb-non-UTF8-performance b/tests/mb-non-UTF8-performance
new file mode 100755 (executable)
index 0000000..b6d43da
--- /dev/null
@@ -0,0 +1,49 @@
+#!/bin/sh
+# grep-2.17 would take nearly 200x longer to run the command below.
+# The 200x is on an Intel i7-based system.
+# On an AMD FX-4100, it would take up to 2500x longer.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+require_timeout_
+require_hi_res_time_
+
+fail=0
+
+yes $(printf '%078d' 0) | head -50000 > in || framework_failure_
+
+start=$(hi_res_time_)
+LC_ALL=C grep -i foobar in; st=$?
+stop=$(hi_res_time_)
+
+# Use a multiple of the LC_ALL=C duration as the timeout for the JP/EUC test.
+# A multiple of 3 seems to be enough for i5,i7, but AMD needs >25.
+# Use an integer; some 'timeout' implementations have trouble with
+# floating-point in JP_EUC locales.
+timeout=$(
+  $AWK 'BEGIN { print 1 + int (30 * ('$stop' - '$start'))}' < /dev/null
+)
+
+test $st = 1 || fail=1
+
+require_JP_EUC_locale_
+
+# Expect no match, i.e., exit status of 1.  Anything else is an error.
+timeout $timeout grep -i foobar in; st=$?
+test $st = 1 || fail=1
+
+Exit $fail
diff --git a/tests/null-byte b/tests/null-byte
new file mode 100755 (executable)
index 0000000..c967dbc
--- /dev/null
@@ -0,0 +1,52 @@
+#!/bin/sh
+# Test NUL bytes in patterns and data.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+# Add "." to PATH for the use of get-mb-cur-max.
+path_prepend_ .
+
+locales=C
+for locale in en_US.iso885915 en_US.UTF-8; do
+  get-mb-cur-max en_US.UTF-8 >/dev/null 2>&1 && locales="$locales $locale"
+done
+
+fail=0
+
+for left in '' a '#' '\0'; do
+  for right in '' b '#' '\0'; do
+    data="$left\\0$right"
+    printf "$data\\n" >in || framework_failure_
+    for hat in '' '^'; do
+      for dollar in '' '$'; do
+        for force_regex in '' '\\(\\)\\1'; do
+          pat="$hat$force_regex$data$dollar"
+          printf "$pat\\n" >pat || framework_failure_
+          for locale in $locales; do
+            LC_ALL=$locale grep -f pat in ||
+              fail_ "'$pat' does not match '$data'"
+            LC_ALL=$locale grep -a -f pat in | cmp -s - in ||
+              fail_ "-a '$pat' does not match '$data'"
+          done
+        done
+      done
+    done
+  done
+done
+
+Exit $fail
index cbe6884..7efa560 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Ensure that with -P, \s*$ matches a newline.
+# Ensure that with -P, \s matches a newline.
 #
 # Copyright (C) 2001, 2006, 2009-2014 Free Software Foundation, Inc.
 #
@@ -12,7 +12,7 @@ require_pcre_
 
 fail=0
 
-# See CVS revision 1.32 of "src/search.c".
 echo | grep -P '\s*$' || fail=1
+echo | grep -zP '\s$' || fail=1
 
 Exit $fail
diff --git a/tests/pcre-infloop b/tests/pcre-infloop
new file mode 100755 (executable)
index 0000000..1b33e72
--- /dev/null
@@ -0,0 +1,33 @@
+#!/bin/sh
+# With some versions of libpcre, apparently including 8.35,
+# the following would trigger an infinite loop in its match function.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+require_pcre_
+require_timeout_
+require_en_utf8_locale_
+require_compiled_in_MB_support
+
+printf 'a\201b\r' > in || framework_failure_
+
+fail=0
+
+LC_ALL=en_US.UTF-8 timeout 3 grep -P 'a.?..b' in
+test $? = 2 || fail_ "libpcre's match function appears to infloop"
+
+Exit $fail
index ccf3caf..913e8ee 100755 (executable)
@@ -15,8 +15,7 @@ fail=0
 
 printf 'j\202\nj\n' > in || framework_failure_
 
-LC_ALL=en_US.UTF-8 grep -P j in > out 2>&1 || fail=1
-compare in out || fail=1
-compare /dev/null err || fail=1
+LC_ALL=en_US.UTF-8 grep -P j in
+test $? -eq 2 || fail=1
 
 Exit $fail
diff --git a/tests/pcre-w b/tests/pcre-w
new file mode 100755 (executable)
index 0000000..5040c5a
--- /dev/null
@@ -0,0 +1,31 @@
+#! /bin/sh
+# Before grep-2.19, grep -Pw %% would match %% enclosed in word boundaries
+#
+# Copyright (C) 2014 Free Software Foundation, Inc.
+#
+# Copying and distribution of this file, with or without modification,
+# are permitted in any medium without royalty provided the copyright
+# notice and this notice are preserved.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+require_pcre_
+
+fail=0
+
+echo %aa% > in || framework_failure_
+grep -Pw aa in > out || fail=1
+compare out in || fail=1
+
+echo a%%a > in || framework_failure_
+grep -Pw %% in > out && fail=1
+compare /dev/null out || fail=1
+
+echo %%%% > in || framework_failure_
+grep -Pw %% in > out || fail=1
+compare out in || fail=1
+
+echo %% > in || framework_failure_
+grep -Pw %% in > out || fail=1
+compare out in || fail=1
+
+Exit $fail
diff --git a/tests/pcre-wx-backref b/tests/pcre-wx-backref
new file mode 100755 (executable)
index 0000000..643aa9b
--- /dev/null
@@ -0,0 +1,28 @@
+#! /bin/sh
+# Before grep-2.19, grep -P and -w/-x would not with a backreference.
+#
+# Copyright (C) 2014 Free Software Foundation, Inc.
+#
+# Copying and distribution of this file, with or without modification,
+# are permitted in any medium without royalty provided the copyright
+# notice and this notice are preserved.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+require_pcre_
+
+echo aa > in || framework_failure_
+echo 'grep: reference to non-existent subpattern' > exp-err \
+  || framework_failure_
+
+fail=0
+
+for xw in x w; do
+  grep -P$xw '(.)\1' in > out 2>&1 || fail=1
+  compare out in || fail=1
+
+  grep -P$xw '(.)\2' in > out 2> err && fail=1
+  compare /dev/null out || fail=1
+  compare exp-err err || fail=1
+done
+
+Exit $fail
diff --git a/tests/posix-bracket b/tests/posix-bracket
new file mode 100755 (executable)
index 0000000..d9d1d84
--- /dev/null
@@ -0,0 +1,33 @@
+#!/bin/sh
+# Check various bracket expressions in the POSIX locale.
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+LC_ALL=C
+export LC_ALL
+
+fail=0
+
+echo a >in || framework_failure_
+for bracketed in '[.a.]' '[.a.]-a' 'a-[.a.]' '[.a.]-[.a.]' \
+    '[=a=]' '[:alpha:]'; do
+  grep "[$bracketed]" in >out || fail=1
+  compare in out || fail=1
+  grep "[^$bracketed]" in >out && fail=1
+  compare /dev/null out || fail=1
+done
+Exit $fail
index b15fa9b..2228a22 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh
-# This would mistakenly print a line prior to grep-2.6.2.
+# This would mistakenly print a line prior to grep-2.18.
 . "${srcdir=.}/init.sh"; path_prepend_ ../src
 
 require_en_utf8_locale_
@@ -7,14 +7,37 @@ require_compiled_in_MB_support
 
 encode() { echo "$1" | tr ABC '\357\274\241'; }
 
+encode ABC >exp1
+encode aABC >exp2
+encode ABCABC >exp3
+encode _____________________ABCABC___ >exp4
+
 fail=0
 
 for LOC in en_US.UTF-8 $LOCALE_FR_UTF8; do
-  for opt in '' '-F'; do
-    out=out-$opt-$LOC
-    encode ABC | LC_ALL=$LOC grep $opt "$(encode A)" > $out 2>&1
-    test $? = 1 || fail=1
-    compare /dev/null $out || fail=1
+  for pat in A aA BCA; do
+    for file in exp1 exp2 exp3 exp4; do
+      for type in regex dfa fgrep; do
+        case $type in
+          dfa) opt= prefix= ;;
+          fgrep) opt=-F prefix= ;;
+          regex) opt= prefix='\(\)\1' ;;
+        esac
+        pattern=$prefix$(encode $pat)
+        out=out-$type-$LOC
+        LC_ALL=$LOC grep $opt "$pattern" $file >$out
+        status=$?
+        echo $status >$out.status
+        if test $status -eq 0; then
+          compare $file $out
+        elif test $status -eq 1; then
+          compare_dev_null_ /dev/null $out
+        else
+          test $status -eq 2
+        fi || fail=1
+        compare out-regex-$LOC.status $out.status || fail=1
+      done
+    done
   done
 done
 
index 11000fe..e8deeac 100755 (executable)
@@ -18,6 +18,6 @@ ${AWK-awk} -v extra_locale=$LOCALE_FR_UTF8 \
     -f "$abs_srcdir/spencer1-locale.awk" "$abs_srcdir/spencer1.tests" \
   > spencer1-locale.script || fail=1
 
-${SHELL-sh} spencer1-locale.script || fail=1
+${re_shell-${SHELL-sh}} spencer1-locale.script || fail=1
 
 Exit $fail
diff --git a/tests/turkish-eyes b/tests/turkish-eyes
new file mode 100755 (executable)
index 0000000..cc585da
--- /dev/null
@@ -0,0 +1,46 @@
+#!/bin/sh
+# Ensure that case-insensitive matching works with all Turkish i's
+
+# Copyright (C) 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+
+require_compiled_in_MB_support
+
+fail=0
+
+L=tr_TR.UTF-8
+
+# Check for a broken tr_TR.UTF-8 locale definition.
+# In this locale, 'i' is not a lower-case 'I'.
+echo I | LC_ALL=$L grep -i i > /dev/null \
+    && skip_ "your $L locale appears to be broken"
+
+# Ensure that this matches:
+# printf 'I:İ ı:i\n'|LC_ALL=tr_TR.utf8 grep -i 'ı:i I:İ'
+I=$(printf '\304\260') # capital I with dot
+i=$(printf '\304\261') # lowercase dotless i
+
+      data="I:$I $i:i"
+search_str="$i:i I:$I"
+printf "$data\n" > in || framework_failure_
+
+for opt in -E -F -G; do
+  LC_ALL=$L grep $opt -i "$search_str" in > out || fail=1
+  compare out in || fail=1
+done
+
+Exit $fail
diff --git a/tests/unibyte-negated-circumflex b/tests/unibyte-negated-circumflex
new file mode 100755 (executable)
index 0000000..b6d747c
--- /dev/null
@@ -0,0 +1,27 @@
+#!/bin/sh
+# Exercise a bug where [^^-^] was treated as if it were [^-^].
+
+# Copyright 2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+. "${srcdir=.}/init.sh"; path_prepend_ ../src
+require_unibyte_locale
+
+fail=0
+
+echo a >in || framework_failure_
+grep '[^^-^]' in >out || fail=1
+compare out in || fail=1
+Exit $fail
index b7f1576..f65298f 100755 (executable)
@@ -11,8 +11,16 @@ LC_ALL=en_US.UTF-8
 export LC_ALL
 
 fail=0
-grep "\<$e_acute" in > out 2>err || fail=1
 
+grep "\\<$e_acute" in > out 2>err || fail=1
+compare out in || fail=1
+compare /dev/null err || fail=1
+
+grep "$e_acute\\>" in > out 2>err || fail=1
+compare out in || fail=1
+compare /dev/null err || fail=1
+
+grep -w "$e_acute" in > out 2>err || fail=1
 compare out in || fail=1
 compare /dev/null err || fail=1