SHA256
3
0
forked from pool/grep
grep/grep-2.5.1a.diff

74 lines
2.4 KiB
Diff

--- Makefile.am
+++ Makefile.am
@@ -5,21 +5,7 @@
EXTRA_DIST = TODO README README-alpha PATCHES.AC PATCHES.AM
-# We should be able to just define `ACLOCAL_AMFLAGS = --acdir=m4',
-# but this runs afoul of a bug in automake 1.
-# The following hack works around this bug by creating acinclude.m4 manually.
-ACLOCAL_AMFLAGS =
-M4DIR = $(srcdir)/m4
-ACINCLUDE_INPUTS = $(M4DIR)/decl.m4 $(M4DIR)/djgpp.m4 $(M4DIR)/dosfile.m4 \
- $(M4DIR)/envsep.m4 $(M4DIR)/error.m4 $(M4DIR)/gettext.m4 $(M4DIR)/glibc.m4 \
- $(M4DIR)/header.m4 $(M4DIR)/init.m4 $(M4DIR)/install.m4 \
- $(M4DIR)/inttypes_h.m4 $(M4DIR)/isc-posix.m4 $(M4DIR)/largefile.m4 \
- $(M4DIR)/lcmessage.m4 $(M4DIR)/malloc.m4 $(M4DIR)/mbstate_t.m4 \
- $(M4DIR)/missing.m4 $(M4DIR)/progtest.m4 $(M4DIR)/realloc.m4 \
- $(M4DIR)/regex.m4 $(M4DIR)/sanity.m4 $(M4DIR)/strerror_r.m4 \
- $(M4DIR)/uintmax_t.m4 $(M4DIR)/ulonglong.m4 $(M4DIR)/xstrtoumax.m4
-$(srcdir)/acinclude.m4 : $(ACINCLUDE_INPUTS)
- cat $(ACINCLUDE_INPUTS) >$(srcdir)/acinclude.m4
+ACLOCAL_AMFLAGS = -I m4
# make cvs-clean blatantly stolen from KDE CVS ;)
cvs-clean:
--- m4/strerror_r.m4
+++ m4/strerror_r.m4
@@ -4,8 +4,6 @@
# `run'-test that works on BeOS and segfaults on DEC Unix.
# Use with the error.c file in ../lib.
-undefine([AC_FUNC_STRERROR_R])
-
# AC_FUNC_STRERROR_R
# ------------------
AC_DEFUN([AC_FUNC_STRERROR_R],
--- src/Makefile.am
+++ src/Makefile.am
@@ -20,11 +20,11 @@
egrep:
echo '#!/bin/sh' >$@
- echo 'exec grep -E $${1+"$$@"}' >>$@
+ echo 'exec $(bindir)/'`echo grep|sed '$(transform)'`' -E $${1+"$$@"}' >>$@
chmod a+x $@
fgrep:
echo '#!/bin/sh' >$@
- echo 'exec grep -F $${1+"$$@"}' >>$@
+ echo 'exec $(bindir)/'`echo grep|sed '$(transform)'`' -F $${1+"$$@"}' >>$@
chmod a+x $@
--- src/dfa.c
+++ src/dfa.c
@@ -482,7 +482,8 @@
work_mbc->nchars = work_mbc->nranges = work_mbc->nch_classes = 0;
work_mbc->nequivs = work_mbc->ncoll_elems = 0;
- work_mbc->chars = work_mbc->ch_classes = NULL;
+ work_mbc->chars = NULL;
+ work_mbc->ch_classes = NULL;
work_mbc->range_sts = work_mbc->range_ends = NULL;
work_mbc->equivs = work_mbc->coll_elems = NULL;
@@ -551,7 +552,7 @@
wt = wctype (str);
if (ch_classes_al == 0)
- MALLOC(work_mbc->ch_classes, wchar_t, ++ch_classes_al);
+ MALLOC(work_mbc->ch_classes, wctype_t, ++ch_classes_al);
REALLOC_IF_NECESSARY(work_mbc->ch_classes, wctype_t,
ch_classes_al,
work_mbc->nch_classes + 1);