1 VERSION = $(shell cat configure.in |grep INIT_AUTOMAKE |sed -e 's/.*,//;s/^ //;s/.$$//' )
4 all: autogen.sh configure.in
8 [ -e configure.in ] || ( echo Must be run from grep source dir ; exit 1 )
9 rm -rf /tmp/grep-$(VERSION) && cp -aR $(SRCDIR) /tmp/grep-$(VERSION) && cd /tmp/grep-$(VERSION) && make -f Makefile.cvs cvs-clean && make -f Makefile.cvs && rm -rf autom4te.cache && (find . -type d -name CVS |xargs rm -rf) && cd .. && tar chf $(SRCDIR)/grep-$(VERSION).tar grep-$(VERSION)
11 grep-$(VERSION).tar.bz2: grep-$(VERSION).tar
12 bzip2 -9f grep-$(VERSION).tar
14 grep-$(VERSION).tar.gz: grep-$(VERSION).tar
15 gzip -9f grep-$(VERSION).tar
17 rpm: grep-$(VERSION).tar.bz2
18 rpm -ts --define '_srcrpmdir $(SRCDIR)' grep-$(VERSION).tar.bz2
20 # make cvs-clean blatantly stolen from KDE CVS ;)
22 @if test ! -d CVS; then \
23 echo "You don't have a toplevel CVS directory."; \
24 echo "You most certainly didn't use cvs to get these sources."; \
25 echo "But this function depends on cvs's information."; \
29 dirs=`find . -type d | grep -v CVS | sed -e "s#^./##"` ;\
31 if test ! -d "$$pwd/$$i/CVS"; then \
38 if test ! -d "$$f"; then \
39 if grep "^/$$f/" CVS/Entries > /dev/null; then \
43 rm -f "$$pwd/$$i/$$f"; \