| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
'configure' creates this file, so it shouldn't be distributed; see:
http://bugs.gnu.org/17480
* configure.ac (COLORIZE_SOURCE): New macro.
Don't use AC_CONFIG_LINKS for lib/colorize.c.
* lib/Makefile.am (nodist_libgreputils_a_SOURCES): New macro.
(libgreputils_a_SOURCES): Remove colorize.c.
(CLEANFILES): Add colorize.c
(colorize.c): New rule.
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
| |
Do that by running "make update-copyright".
|
|
|
|
|
|
| |
* Makefile.am (ACLOCAL_AMFLAGS): Don't use this deprecated variable.
* configure.ac (AC_CONFIG_MACRO_DIRS): Use this instead.
(AUTOMAKE_OPTIONS): Require automake-1.12.
|
|
|
|
|
|
| |
* configure.ac (WERROR_CFLAGS): Don't add -fdiagnostics-show-option
and -funit-at-a-time, as Gnulib does that for us now, and we're
merely piling on duplicats.
|
|
|
|
| |
* configure.ac (AM_INIT_AUTOMAKE): Add subdir-objects.
|
|
|
|
|
|
|
| |
* configure.ac: Don't use unquoted '^' in a pattern, as this
breaks 'configure' on Solaris 10, whose /bin/sh complains about it,
which causes 'configure' to exit even before it finds a decent shell.
Unix 7th edition shell accepted '^' as an alias for '|'.
|
|
|
|
|
|
| |
Problem reported by Brenton Hoff (Bug#15663).
* configure.ac (_FORTIFY_SOURCE): Don't define if already defined.
This is what Emacs does.
|
|
|
|
|
|
|
|
|
| |
* configure.ac (AM_GNU_GETTEXT_VERSION): Update to 0.18.2.
This is necessary to have the gettext-provided m4 files to use
AC_PROG_MKDIR_P rather than AM_PROG_MKDIR_P. This latter macro,
planned to disappear in Automake 1.14, has already been removed
in the development version of Automake, so that, without this
change, grep fails to bootstrap with bleeding-edge Automake.
|
|
|
|
| |
Run "make update-copyright".
|
|
|
|
|
|
| |
* configure.ac: Go back to using AC_PROG_CC rather than AC_PROG_CC_STDC,
as the latter is obsolescent and the Autoconf bug involving the former
has been fixed.
|
|
|
|
|
| |
* configure.ac: Use AC_PROG_CC_STDC rather than AC_PROG_CC,
to accommodate autoconf-2.69-37+.
|
|
|
|
|
|
|
|
| |
Anyone building from cloned sources can be assumed to have a new
enough environment, such that enabling gcc warnings by default will
be useful. Tarballs still default to no warnings, and the default
can still be overridden with --disable-gcc-warnings.
* configure.ac (gl_gcc_warnings): Set default based on environment.
|
|
|
|
|
|
|
|
| |
Starting with glibc 2.15, the system headers refuse to compile
unconditional use of FORTIFY_SOURCE if optimization is disabled
but -Werror is in effect.
* configure.ac (FORTIFY_SOURCE): Make conditional.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
See <http://lists.gnu.org/archive/html/bug-grep/2012-01/msg00125.html>.
* ChangeLog-2009, HACKING, NEWS, README-hacking, cfg.mk, configure.ac:
* lib/colorize-w32.c, m4/pcre.m4:
* src/Makefile.am, src/dfa.c, src/dosbuf.c, src/main.c:
* tests/backref, tests/help-version, tests/tests:
In commentary, quote 'like this' or "like this" rather than
`like this' or ``like this''.
* cfg.mk (old_NEWS_hash): Update due to changed old NEWS.
* doc/grep.texi (General Output Control): Quote sample text
with @samp, not with `...'.
* src/main.c (usage):
* tests/help-version: Quote 'like this' rather than `like this'
in diagnostics.
|
|
|
|
|
|
|
|
|
|
| |
* configure.ac: Create lib/colorize.c as a symbolic link.
* lib/colorize-posix.c: New name of lib/colorize-impl.c.
* lib/colorize-w32.c: New name of lib/ms/colorize-impl.c.
* lib/colorize.c: Delete.
* lib/Makefile.am (EXTRA_DIST): Adjust.
* .gitignore: Adjust.
* cfg.mk: Adjust syntax-check exclusions.
|
|
|
|
| |
Run "make update-copyright".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* cfg.mk (exclude_file_name_regexp--sc_prohibit_strcmp)
(exclude_file_name_regexp--sc_require_config_h)
(exclude_file_name_regexp--sc_require_config_h_first):
New rules.
* lib/colorize.c, lib/colorize.h, lib/colorize-impl.c:
* lib/ms/colorize.h, lib/ms/colorize-impl.c: New files.
* configure.ac (GREP_SRC_INCLUDES): New macro.
* lib/Makefile.am (libgreputils_a_SOURCES): Add colorize.[ch].
(EXTRA_DIST): New macro.
* src/Makefile.am (DEFAULT_INCLUDES): New macro.
* src/main.c: Include colorize.h.
(PR_SGR_START, PR_SGR_END, PR_SGR_START_IF, PR_SGR_END_IF):
Now static functions, not macros.
(hstdout, norm_attr, w32_console_init, w32_sgr2attr)
(w32_clreol) [__MINGW32__]: Move to lib/ms/colorize-impl.c.
(pr_sgr_start, pr_sgr_end): Remove; callers changed to use new
print_start_colorize, print_end_colorize from colorize.h.
(init_colorize): Rename from w32_console_init and move to
colorize module; caller changed.
(should_colorize): Move to colorize module.
|
|
|
|
|
|
|
|
|
| |
* bootstrap.conf (gnulib_modules): Add iswctype and wcscoll.
* configure.ac: Remove explicit checks for those functions.
* src/mbsupport.h (MBS_SUPPORT): Define to 1 if not already defined.
Remove the conditional, now that we're guaranteed by gnulib to have
wcscoll and iswctype.
Suggested by Alan Hourihane in http://savannah.gnu.org/bugs/?34930
|
|
|
|
|
|
|
|
|
|
|
| |
Now that we're using the latest manywarnings module from gnulib,
accommodate gcc's -Werror=suggest-attribute=pure option by marking
suggested functions with gnulib-defined _GL_ATTRIBUTE_PURE.
* src/kwset.c (hasevery): Mark function with pure attribute.
(bmexec): Likewise.
* src/dfa.c (nsubtoks, istrstr, find_pred, dfamusts): Likewise.
* configure.ac: Disable (for lib/) options that seem not to be worth
the trouble: -Wunsuffixed-float-constants and -Wformat-nonliteral.
|
|
|
|
|
| |
* configure.ac (AM_INIT_AUTOMAKE): Add no-dist-gzip.
* NEWS (Build-related): Mention that we're dropping .tar.gz.
|
|
|
|
|
|
| |
* configure.ac: Remove AC_SYS_LARGEFILE, subsumed by ...
* bootstrap.conf (gnulib_modules): ...this. Use largefile module.
* gnulib: Update to latest.
|
|
|
|
| |
Run "make update-copyright", so "make syntax-check" works in 2011.
|
|
|
|
| |
* configure.ac (fn_grep): Add comment suggested by Bruno Haible.
|
|
|
|
| |
* configure.ac: Add extra brackets around [...] patterns.
|
|
|
|
|
|
| |
* configure.ac (fn_grep): New. Set GREP and EGREP to it, replace
with newly-built grep before AC_OUTPUT. Reported by Florin Iucha
<http://savannah.gnu.org/bugs/?31646>.
|
|
|
|
| |
* configure.ac (GNULIB_WARN_CFLAGS): Remove -Wcast-align.
|
|
|
|
|
|
|
| |
* configure.ac (USE_INCLUDED_REGEX): Add Automake conditional.
* tests/equiv-classes: New test.
* tests/Makefile.am (TESTS): Add it.
(XFAIL_TESTS) [USE_INCLUDED_REGEX]: Mark it as expected failure.
|
|
|
|
|
|
|
| |
* configure.ac: Use gettext-0.18.
* bootstrap.conf (gnulib_modules): Use gettext-h, not gettext.
since the latter drags in a depedency on gettext 0.18.
Suggested by Bruno Haible.
|
|
|
|
|
| |
* configure.ac (ARGMATCH_DIE): Use usage(EXIT_FAILURE), not exit(1).
* po/POTFILES.in: Add lib/argmatch.c.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before, you'd see this:
grep: unknown directories method
Now, you'll see this:
grep: invalid argument `INVAL' for `--directories'
Valid arguments are:
- `read'
- `recurse'
- `skip'
Usage: src/grep [OPTION]... PATTERN [FILE]...
Try `src/grep --help' for more information.
* bootstrap.conf: Add argmatch.
* configure.ac: Define ARGMATCH_DIE and ARGMATCH_DIE_DECL.
* src/main.c (directories_type): Define.
(directories_args, directories_types) Define.
All of the above so we can...
(main): Use XARGMATCH.
(usage): Declare extern, now that argmatch calls it via ARGMATCH_DIE.
|
|
|
|
|
|
|
|
| |
* configure.ac (AC_CONFIG_FILES): Remove vms/Makefile
* Makefile.am (SUBDIRS): Remove vms.
* src/Makefile.am (EXTRA_DIST): Remove vms_fab.c and vms_fab.h.
* src/vms_fab.c, src/vms_fab.h, vms/make.com: Remove files.
* vms/Makefile.am, vms/README, vms/config_vms.h: Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* configure.ac: Do not use PKG_PROG_PKG_CONFIG or PKG_CHECK_MODULES.
Do not modify CPPFLAGS; that belongs to those who invoke make.
Instead, use autoconf's AC_CHECK_HEADERS and AC_SEARCH_LIBS via the
new macro, gl_FUNC_PCRE, defined in...
* m4/pcre.m4 (gl_FUNC_PCRE): New macro, to handle pcre-related
configure-time tests.
* src/Makefile.am (grep_LDADD): Use LIB_PCRE, not PCRE_LIBS.
* src/pcresearch.c: Test HAVE_LIBPCRE via "#if", not "#ifdef".
All other cpp tests of this symbol used "#if".
Prompted by a suggestion from Bruno Haible.
* NEWS (Build-related): Mention this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
mmap is a bad idea for sequentially accessed file because it will cause
a page fault for every read page. Just consider it a failed experiment,
and ignore --mmap while accepting it for backwards compatibility.
* configure.ac (AC_FUNC_MMAP): Remove.
* doc/grep.texi (Other options): Say --mmap is ignored.
* src/grep.c (mmap_option): Remove.
(long_options): Do not reference it.
(bufmapped, initial_bufoffset): Remove.
(reset, fillbuf): Remove HAVE_MMAP code.
(grepfile): Remove bufmapped reference.
(usage): Say --mmap is ignored.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Gnulib is incompatible with -Wunused-macros. Addtionally,
cygwin 1.7.1 coupled with --enable-gcc-warnings tripped on:
grep.c: In function 'print_line_middle':
grep.c:805: error: array subscript has type 'char' [-Wchar-subscripts]
grep.c: In function 'main':
grep.c:1833: error: 'optarg' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
grep.c:1834: error: 'optind' redeclared without dllimport attribute after being referenced with dll linkage
* configure.ac (GNULIB_WARN_FLAGS): Disable -Wunused-macros.
* src/grep.c (print_line_middle): Use correct type to tolower.
(main): Drop useless redeclarations.
* .gitignore: Ignore more built files.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
| |
* cfg.mk (local-checks-to-skip): Enable m4-quote-check.
* configure.ac: Fix occurrence.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that we enable more warnings in lib/, we choose
to avoid some via patches applied by bootstrap, using
files in the gl/ hierarchy. Other, less-important
warnings are avoided simply by turning off the
-Wold-style-definition option and using a slightly
relaxed set of warnings $(GNULIB_WARN_CFLAGS) in lib/.
* gl/lib/regcomp.c.diff: Avoid warnings.
* gl/lib/regex_internal.c.diff: Likewise.
* gl/lib/regex_internal.h.diff: Likewise.
* gl/lib/regexec.c.diff: Likewise.
* configure.ac (GNULIB_PORTCHECK): Disable only -Wold-style-definition.
* lib/Makefile.am (AM_CFLAGS): Use $(GNULIB_WARN_CFLAGS) rather
than the slightly more strict $(WARN_CFLAGS).
|
|
|
|
|
|
|
|
|
|
| |
* bootstrap.conf (gnulib_modules): Add regex.
* configure.ac: Don't use jm_INCLUDED_REGEX.
Update use of cache variable.
* lib/regex.c: Remove file.
* lib/regex.h: Likewise.
* m4/regex.m4: Likewise.
* POTFILES.in: Update to match.
|
|
|
|
|
|
|
| |
* bootstrap.conf (gnulib_modules): Add "manywarnings" module.
* configure.ac: Add --enable-gcc-warnings, derived from code in bison.
* src/Makefile.am (AM_CFLAGS): Set to $(WARN_CFLAGS) $(WERROR_CFLAGS)
* lib/Makefile.am (AM_CFLAGS): Likewise, but append.
|
|
|
|
|
|
|
|
| |
* Makefile.am (SUBDIRS): Add gnulib-tests.
* gnulib-tests/Makefile.am: New file.
* bootstrap.conf (bootstrap_epilogue): New function, from coreutils.
(gnulib_tool_option_extras): Define.
* configure.ac: Add gnulib-tests/Makefile.
|
|
|
|
|
|
| |
Use this command:
git ls-files |grep -vE '^(\..*|COPYING|gnulib)$' |xargs \
env UPDATE_COPYRIGHT_USE_INTERVALS=1 build-aux/update-copyright
|
|
|
|
|
| |
* configure.ac: use pkg-config to detect PCRE
* src/Makefile.am (grep_LDADD): link grep with PCRE_LIBS
|
|
|
|
|
|
|
| |
* configure.ac (AM_INIT_AUTOMAKE): Create xz-compressed tarballs,
not bzip2-compressed ones. Enable automake's silent-rules,
parallel tests, and test PASS/FAIL coloring options.
Use AC_CONFIG_HEADERS, not AM_CONFIG_HEADER. Quote the argument.
|
|
|
|
| |
* configure.ac (AC_INIT): Use git-version-gen.
|
|
|
|
|
|
|
|
| |
* bootstrap.conf: Add binary-io, dirname.
* configure.ac: Remove check for setmode, AC_DOSFILE.
* m4/dosfile.m4: Remove.
* src/grep.c: Adjust for dirname.h.
* src/system.h: Adjust for new gnulib modules.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bootstrap.conf: Add gnulib modules for replacement functions and
headers.
* configure.ac: Remove macros subsumed by gnulib.
* lib/hard-locale.c: Remove guards for headers/functions provided by gnulib.
* lib/regex.c: Likewise.
* lib/savedir.c: Likewise.
* src/dfa.c: Likewise.
* src/dfa.h: Do not look at PROTOTYPES.
* src/grep.c: Likewise.
* src/mbsupport.h: Likewise.
* src/system.h: Likewise.
* m4/mbstate_t.m4: Remove.
* src/getpagesize.h: Remove.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bootstrap.conf: Add gnulib modules and build libgreputils.a.
* configure.ac: Remove macros subsumed by gnulib.
* lib/Makefile.am: Remove files subsumed by gnulib.
* lib/alloca.c: Remove.
* lib/atexit.c: Remove.
* lib/error.c: Remove.
* lib/error.h: Remove.
* lib/fnmatch.c: Remove.
* lib/fnmatch.h: Remove.
* lib/getopt.c: Remove.
* lib/getopt.h: Remove.
* lib/getopt1.c: Remove.
* lib/gettext.h: Remove.
* lib/malloc.c: Remove.
* lib/memchr.c: Remove.
* lib/obstack.c: Remove.
* lib/obstack.h: Remove.
* lib/quotearg.c: Remove.
* lib/quotearg.h: Remove.
* lib/realloc.c: Remove.
* lib/stpcpy.c: Remove.
* lib/strtol.c: Remove.
* lib/strtoul.c: Remove.
* lib/strtoull.c: Remove.
* lib/xalloc.h: Remove.
* lib/xmalloc.c: Remove.
* lib/xstrtol.c: Remove.
* lib/xstrtol.h: Remove.
* lib/xstrtoumax.c: Remove.
* m4/error.m4: Remove.
* m4/inttypes_h.m4: Remove.
* m4/malloc.m4: Remove.
* m4/realloc.m4: Remove.
* m4/uintmax_t.m4: Remove.
* m4/ulonglong.m4: Remove.
* m4/xstrtoumax.m4: Remove.
* src/system.h: Remove strerror, sys_nerr, sys_errlist.
|
|
|
|
|
| |
* bootstrap: Use gnulib's build-aux/bootstrap.
* configure.ac: Add gl_INIT and gl_EARLY.
|