diff options
author | wxs <wxs@FreeBSD.org> | 2009-12-26 10:14:41 +0800 |
---|---|---|
committer | wxs <wxs@FreeBSD.org> | 2009-12-26 10:14:41 +0800 |
commit | a365b71c340291a0b4f6ee708d9163d654cd1b9e (patch) | |
tree | 4d504ddab218334bab2bdc58ca75028d825352b3 /sysutils/grok | |
parent | 551d5aced40326d6e9300b331f63d0d18f34aad4 (diff) | |
download | freebsd-ports-gnome-a365b71c340291a0b4f6ee708d9163d654cd1b9e.tar.gz freebsd-ports-gnome-a365b71c340291a0b4f6ee708d9163d654cd1b9e.tar.zst freebsd-ports-gnome-a365b71c340291a0b4f6ee708d9163d654cd1b9e.zip |
- Update to 20091225.01 - This is a complete rewrite in C.
PR: ports/140593
Submitted by: Sahil Tandon <sahil@tandon.net>
Diffstat (limited to 'sysutils/grok')
-rw-r--r-- | sysutils/grok/Makefile | 48 | ||||
-rw-r--r-- | sysutils/grok/distinfo | 6 | ||||
-rw-r--r-- | sysutils/grok/files/grok.sh.in | 28 | ||||
-rw-r--r-- | sysutils/grok/files/patch-Makefile | 22 | ||||
-rw-r--r-- | sysutils/grok/files/pkg-message.in | 6 | ||||
-rw-r--r-- | sysutils/grok/pkg-plist | 12 |
6 files changed, 55 insertions, 67 deletions
diff --git a/sysutils/grok/Makefile b/sysutils/grok/Makefile index e79c7b7f5e63..2d747a1455c8 100644 --- a/sysutils/grok/Makefile +++ b/sysutils/grok/Makefile @@ -6,50 +6,42 @@ # PORTNAME= grok -PORTVERSION= 20070915 +PORTVERSION= 20091225.01 CATEGORIES= sysutils -MASTER_SITES= http://www.semicomplete.com/files/grok/ \ - http://www.atarininja.org/~wxs/distfiles/ +MASTER_SITES= GOOGLE_CODE MAINTAINER= wxs@FreeBSD.org COMMENT= An expert system for real-time log analysis -RUN_DEPENDS= ${SITE_PERL}/Regexp/Common.pm:${PORTSDIR}/textproc/p5-Regexp-Common \ - ${SITE_PERL}/Parse/RecDescent.pm:${PORTSDIR}/devel/p5-Parse-RecDescent \ - ${SITE_PERL}/${PERL_ARCH}/Unix/Syslog.pm:${PORTSDIR}/sysutils/p5-Unix-Syslog \ - ${SITE_PERL}/Date/Format.pm:${PORTSDIR}/devel/p5-TimeDate \ - ${SITE_PERL}/URI.pm:${PORTSDIR}/net/p5-URI +BUILD_DEPENDS= gperf>=3.0.3:${PORTSDIR}/devel/gperf \ + libevent>=1.3:${PORTSDIR}/devel/libevent \ + pcre>=7.6:${PORTSDIR}/devel/pcre \ + tokyocabinet>=1.4.9:${PORTSDIR}/databases/tokyocabinet +RUN_DEPENDS= ${BUILD_DEPENDS} -USE_PERL5= yes -USE_RC_SUBR= grok.sh -NO_BUILD= yes +MAKE_ENV+= GPERF=${LOCALBASE}/bin/gperf \ + EXTRA_CFLAGS=-I${LOCALBASE}/include \ + EXTRA_LDFLAGS=-L${LOCALBASE}/lib + +USE_GMAKE= yes +USE_LDCONFIG= yes SUB_FILES= pkg-message -SUB_LIST= PERL=${PERL} -PORTDOCS= CHANGELIST -PORTEXAMPLES= line-to-byte-offset.conf -MAN1= grok.1 +PROJECTHOST= semicomplete +PORTDOCS= CHANGELIST INSTALL +MAN1= grok.1 -do-install: - @${INSTALL_SCRIPT} ${WRKSRC}/grok ${PREFIX}/bin - @${INSTALL_SCRIPT} ${WRKSRC}/grok_patfind.pl ${PREFIX}/bin - @${INSTALL_DATA} ${WRKSRC}/grok.conf ${PREFIX}/etc/grok.conf.sample - @${INSTALL_MAN} ${WRKSRC}/grok.1 ${MANPREFIX}/man/man1 +post-patch: + @${REINPLACE_CMD} 's|PREFIX=|PREFIX?=|; s|-g root|-g wheel|' \ + ${WRKSRC}/Makefile post-install: - @if [ ! -f ${PREFIX}/etc/grok.conf ]; then \ - ${CP} -p ${PREFIX}/etc/grok.conf.sample ${PREFIX}/etc/grok.conf ; \ - fi + ${INSTALL_MAN} ${WRKSRC}/grok.1 ${PREFIX}/man/man1 .if !defined(NOPORTDOCS) @${INSTALL} -d ${DOCSDIR} @${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${DOCSDIR} .endif -.if !defined(NOPORTEXAMPLES) - @${INSTALL} -d ${EXAMPLESDIR}/ - @cd ${WRKSRC}/examples/ && \ - ${INSTALL_DATA} ${PORTEXAMPLES} ${EXAMPLESDIR}/ -.endif @${CAT} ${PKGMESSAGE} .include <bsd.port.mk> diff --git a/sysutils/grok/distinfo b/sysutils/grok/distinfo index c9844aab7a59..00c47057724b 100644 --- a/sysutils/grok/distinfo +++ b/sysutils/grok/distinfo @@ -1,3 +1,3 @@ -MD5 (grok-20070915.tar.gz) = ce19c29d0eca6ed0129286cab9ade282 -SHA256 (grok-20070915.tar.gz) = 8b1c1ef1940b493ebd14ac12fbf16985d277c36e10ad64ae01aed46dc70c3ec6 -SIZE (grok-20070915.tar.gz) = 163840 +MD5 (grok-20091225.01.tar.gz) = b42a658bf4517ea6e771479f78fd7387 +SHA256 (grok-20091225.01.tar.gz) = 020e1769ca0c67dada07efabe9c0b81c8d0fd817ce47f3b2888cb5fdc38186d8 +SIZE (grok-20091225.01.tar.gz) = 1778329 diff --git a/sysutils/grok/files/grok.sh.in b/sysutils/grok/files/grok.sh.in deleted file mode 100644 index b5979f1d633b..000000000000 --- a/sysutils/grok/files/grok.sh.in +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - -# PROVIDE: grok -# REQUIRE: LOGIN - -# -# Add the following lines to /etc/rc.conf.local or /etc/rc.conf to enable grok: -# grok_enable (bool): Set to "NO" by default. -# Set it to "YES" to enable grok -# grok_config (path): Set to "%%PREFIX%%/etc/grok.conf" by default. -# - -. %%RC_SUBR%% - -name="grok" -rcvar=`set_rcvar` - -load_rc_config $name - -: ${grok_enable="NO"} -: ${grok_config="%%PREFIX%%/etc/grok.conf"} - -command_interpreter=%%PERL%% -command=%%PREFIX%%/bin/grok -command_args="-f $grok_config -b -d" -required_files=%%PREFIX%%/etc/grok.conf - -run_rc_command "$1" diff --git a/sysutils/grok/files/patch-Makefile b/sysutils/grok/files/patch-Makefile new file mode 100644 index 000000000000..784a0be3d965 --- /dev/null +++ b/sysutils/grok/files/patch-Makefile @@ -0,0 +1,22 @@ +--- Makefile.orig 2009-12-25 20:50:34.181480177 -0500 ++++ Makefile 2009-12-25 20:51:40.171173802 -0500 +@@ -12,7 +12,7 @@ + # On FreeBSD, you may want to set GPERF=/usr/local/bin/gperf since + # the base system gperf is too old. + ifeq ($(PLATFORM), FreeBSD) +-GPERF?=/usr/local/bin/gperf ++GPERF?=${LOCALBASE}/bin/gperf + else + GPERF?=/usr/bin/gperf + endif +@@ -28,8 +28,8 @@ + LDFLAGS+=-lpcre -levent -rdynamic -ltokyocabinet + + # Sane includes +-CFLAGS+=-I/usr/local/include +-LDFLAGS+=-L/usr/local/lib ++CFLAGS+=-I. -I${LOCALBASE}/include ++LDFLAGS+=-L${LOCALBASE}/lib + + # Uncomment to totally disable logging features + #CFLAGS+=-DNOLOGGING diff --git a/sysutils/grok/files/pkg-message.in b/sysutils/grok/files/pkg-message.in index 376754846684..7e86945280a9 100644 --- a/sysutils/grok/files/pkg-message.in +++ b/sysutils/grok/files/pkg-message.in @@ -1,9 +1,7 @@ ============================================================ -You'll have to edit %%PREFIX%%/etc/grok.conf to your -liking. Examples and documentation are available at -grok(1) and at: +Examples and documentation are available at: -http://www.semicomplete.com/projects/grok/ +http://code.google.com/p/semicomplete/wiki/Grok Also, modifications to syslog.conf may be necessary. Usually "user.info /var/log/messages" is enough. diff --git a/sysutils/grok/pkg-plist b/sysutils/grok/pkg-plist index be6afdd0eb1c..ac7ccc35f895 100644 --- a/sysutils/grok/pkg-plist +++ b/sysutils/grok/pkg-plist @@ -1,5 +1,9 @@ bin/grok -bin/grok_patfind.pl -@unexec if cmp -s %D/etc/grok.conf.sample %D/etc/grok.conf; then rm -f %D/etc/grok.conf; fi -etc/grok.conf.sample -@exec if [ ! -f %D/etc/grok.conf ] ; then cp -p %D/%F %B/grok.conf; fi +include/grok.h +include/grok_capture.h +include/grok_capture_xdr.h +include/grok_logging.h +include/grok_match.h +include/grok_pattern.h +include/grokre.h +lib/libgrok.so |