diff -Nru grok-1.20110708.1/debian/changelog grok-1.20110708.1/debian/changelog --- grok-1.20110708.1/debian/changelog 2020-04-25 19:57:15.000000000 +0000 +++ grok-1.20110708.1/debian/changelog 2021-10-14 19:51:00.000000000 +0000 @@ -1,3 +1,37 @@ +grok (1.20110708.1-7) unstable; urgency=medium + + * debian/control: Update Vcs-* with packaging repository + + -- Stig Sandbeck Mathisen Thu, 14 Oct 2021 21:51:00 +0200 + +grok (1.20110708.1-6) unstable; urgency=medium + + * Add package tests + + -- Stig Sandbeck Mathisen Sun, 26 Sep 2021 15:13:52 +0200 + +grok (1.20110708.1-5) unstable; urgency=medium + + * Build with TI RPC on GNU/Linux. + Thanks to Aurelien Jarno (Closes: #992917) + * Update upstream URIs (Closes: #981689) + * Bump standards version + * Bump debhelper from deprecated 9 to 13. + * Change priority extra to priority optional. + * Update upstream homepage + * Update upstream VCS headers + * Set upstream metadata fields: Bug-Database, Bug-Submit. + * Use secure copyright file specification URI. + * Transition to automatic debug package (from: grok-dbg). + * Replace build flag patches with variables in debian/rules + * Manage patches with dgit + * Update debian/watch for github upstream + * Use DEB_*FLAGS_MAINT_* variables + * Add lintian overrides for built binaries in the source tarball + * Drop build dependency on dctrl-tools and dpkg-dev + + -- Stig Sandbeck Mathisen Sun, 26 Sep 2021 12:15:18 +0200 + grok (1.20110708.1-4.5) unstable; urgency=medium * Non-maintainer upload. @@ -12,6 +46,14 @@ -- Sudip Mukherjee Mon, 13 Jan 2020 22:12:23 +0000 +grok (1.20110708.1-4.3~deb9u1) stretch; urgency=medium + + * Non-maintainer upload. + * Rebuild for stretch. + * Drop the gperf 3.1 patches + + -- Andreas Beckmann Mon, 27 Nov 2017 17:12:13 +0100 + grok (1.20110708.1-4.3) unstable; urgency=medium * Non-maintainer upload. diff -Nru grok-1.20110708.1/debian/compat grok-1.20110708.1/debian/compat --- grok-1.20110708.1/debian/compat 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/compat 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -9 diff -Nru grok-1.20110708.1/debian/control grok-1.20110708.1/debian/control --- grok-1.20110708.1/debian/control 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/control 2021-10-14 19:51:00.000000000 +0000 @@ -1,23 +1,22 @@ Source: grok Section: misc -Priority: extra +Priority: optional Maintainer: Stig Sandbeck Mathisen Build-Depends: bison, ctags, - dctrl-tools, - debhelper (>= 9), - dpkg-dev (>= 1.16.1~), + debhelper-compat (= 13), flex, gperf, help2man, libevent-dev, libpcre3-dev, + libtirpc-dev, libtokyocabinet-dev, Standards-Version: 3.9.3 -Homepage: http://code.google.com/p/semicomplete/wiki/Grok -Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/grok.git -Vcs-Git: git://anonscm.debian.org/collab-maint/grok.git +Homepage: https://github.com/jordansissel/grok +Vcs-Browser: https://salsa.debian.org/debian/grok +Vcs-Git: https://salsa.debian.org/debian/grok.git Package: grok Architecture: any @@ -63,17 +62,4 @@ . Grok is simple software that allows you to easily parse logs and other files. With grok, you can turn unstructured log and event data - into structured data. - -Package: grok-dbg -Section: debug -Architecture: any -Depends: - ${misc:Depends}, - libgrok1 (= ${binary:Version}), -Description: debugging symbols for grok - This package contains the detached debugging symbols for grok. - . - Grok is simple software that allows you to easily parse logs and - other files. With grok, you can turn unstructured log and event data into structured data. diff -Nru grok-1.20110708.1/debian/copyright grok-1.20110708.1/debian/copyright --- grok-1.20110708.1/debian/copyright 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/copyright 2021-10-14 19:51:00.000000000 +0000 @@ -1,4 +1,4 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Files: * Copyright: 2007, Jordan Sissel diff -Nru grok-1.20110708.1/debian/patches/0001-Support-GNU-kFreeBSD-add-necessary-linker-flag.patch grok-1.20110708.1/debian/patches/0001-Support-GNU-kFreeBSD-add-necessary-linker-flag.patch --- grok-1.20110708.1/debian/patches/0001-Support-GNU-kFreeBSD-add-necessary-linker-flag.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/0001-Support-GNU-kFreeBSD-add-necessary-linker-flag.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,28 +0,0 @@ -From 0095570747229d4fef0c66595c97661f243cf4a0 Mon Sep 17 00:00:00 2001 -From: Stig Sandbeck Mathisen -Date: Fri, 12 Oct 2012 19:46:07 +0000 -Subject: [PATCH] Support GNU/kFreeBSD, add necessary linker flag - ---- - Makefile | 5 +++++ - 1 file changed, 5 insertions(+) - -diff --git a/Makefile b/Makefile -index a072e6d..7b9e45c 100644 ---- a/Makefile -+++ b/Makefile -@@ -31,6 +31,11 @@ ifeq ($(PLATFORM), GNULinux) - LDFLAGS+=-ldl - endif - -+# For GNU/kFreeBSD, we also need libdl -+ifeq ($(PLATFORM), GNUkFreeBSD) -+LDFLAGS+=-ldl -+endif -+ - # ############################################# - # You probably don't need to make changes below - --- -1.7.10.4 - diff -Nru grok-1.20110708.1/debian/patches/0002-Support-GNU-Hurd-add-necessary-linker-flag.patch grok-1.20110708.1/debian/patches/0002-Support-GNU-Hurd-add-necessary-linker-flag.patch --- grok-1.20110708.1/debian/patches/0002-Support-GNU-Hurd-add-necessary-linker-flag.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/0002-Support-GNU-Hurd-add-necessary-linker-flag.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,28 +0,0 @@ -From 89282af83ea08b5cefb1a1c6a1c2dfe218886e2d Mon Sep 17 00:00:00 2001 -From: Barry deFreese -Date: Sun, 14 Oct 2012 09:01:23 +0000 -Subject: [PATCH] Support GNU/Hurd, add necessary linker flag - ---- - Makefile | 5 +++++ - 1 file changed, 5 insertions(+) - -diff --git a/Makefile b/Makefile -index a072e6d..552360d 100644 ---- a/Makefile -+++ b/Makefile -@@ -31,6 +31,11 @@ ifeq ($(PLATFORM), GNULinux) - LDFLAGS+=-ldl - endif - -+# For GNU/Hurd, we need libdl for dlopen() -+ifeq ($(PLATFORM), GNU) -+LDFLAGS+=-ldl -+endif -+ - # ############################################# - # You probably don't need to make changes below - --- -1.7.10.4 - diff -Nru grok-1.20110708.1/debian/patches/debian-changes grok-1.20110708.1/debian/patches/debian-changes --- grok-1.20110708.1/debian/patches/debian-changes 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/patches/debian-changes 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,126 @@ +The Debian packaging of grok is maintained in git, using the merging workflow +described in dgit-maint-merge(7). There isn't a patch queue that can be +represented as a quilt series. + +A detailed breakdown of the changes is available from their canonical +representation - git commits in the packaging repository. For example, to see +the changes made by the Debian maintainer in the first upload of upstream +version 1.2.3, you could use: + + % git clone https://git.dgit.debian.org/grok + % cd grok + % git log --oneline 1.2.3..debian/1.2.3-1 -- . ':!debian' + +(If you have dgit, use `dgit clone grok`, rather than plain `git clone`.) + +A single combined diff, containing all the changes, follows. + +--- grok-1.20110708.1.orig/Makefile ++++ grok-1.20110708.1/Makefile +@@ -162,14 +162,14 @@ cleanver: + # Binary creation + grok: LDFLAGS+=-levent + grok: $(GROKOBJ) conf.tab.o conf.yy.o main.o grok_config.o +- $(CC) $(LDFLAGS) $^ -o $@ ++ $(CC) $^ $(LDFLAGS) -o $@ + + discogrok: $(GROKOBJ) discover_main.o +- $(CC) $(LDFLAGS) $^ -o $@ ++ $(CC) $^ $(LDFLAGS) -o $@ + + libgrok.$(LIBSUFFIX): + libgrok.$(LIBSUFFIX): $(GROKOBJ) +- $(CC) $(LDFLAGS) -fPIC $(DYNLIBFLAG) $(LIBNAMEFLAG) $^ -o $@ ++ $(CC) -fPIC $(DYNLIBFLAG) $(LIBNAMEFLAG) $^ $(LDFLAGS) -o $@ + + libgrok.$(VERLIBSUFFIX): libgrok.$(LIBSUFFIX); + ln -s $< $@ +@@ -213,7 +213,7 @@ grok_capture_xdr.h: grok_capture.x + rpcgen -h $< -o $@ + + %.c: %.gperf +- @if $(GPERF) --version | head -1 | egrep -v '3\.[0-9]+\.[0-9]+' ; then \ ++ @if $(GPERF) --version | head -1 | egrep -v '3\.(0\.[3-9]+|[1-9]+)' ; then \ + echo "We require gperf version >= 3.0.3" ; \ + exit 1; \ + fi +--- grok-1.20110708.1.orig/conf.tab.c ++++ grok-1.20110708.1/conf.tab.c +@@ -77,7 +77,7 @@ + #include "grok_input.h" + #include "grok_matchconf.h" + +-int yylineno; ++extern int yylineno; + void yyerror (YYLTYPE *loc, struct config *conf, char const *s) { + fprintf (stderr, "Syntax error: %s\n", s); + } +--- grok-1.20110708.1.orig/grok_matchconf_macro.h ++++ grok-1.20110708.1/grok_matchconf_macro.h +@@ -19,6 +19,7 @@ struct strmacro { + #endif + + /* this function is generated by gperf */ +-const struct strmacro *patname2macro(const char *str, unsigned int len); ++const struct strmacro *patname2macro (register const char *str, register size_t len); ++ + + #endif /* _GROK_MATCHCONF_MACRO_ */ +--- grok-1.20110708.1.orig/grok_pattern.c ++++ grok-1.20110708.1/grok_pattern.c +@@ -33,9 +33,9 @@ int grok_pattern_add(const grok_t *grok, + } + + int grok_pattern_find(const grok_t *grok, const char *name, size_t name_len, +- const char **regexp, size_t *regexp_len) { ++ const char **regexp, int *regexp_len) { + TCTREE *patterns = grok->patterns; +- *regexp = tctreeget(patterns, name, name_len, (int*) regexp_len); ++ *regexp = tctreeget(patterns, name, name_len, regexp_len); + + grok_log(grok, LOG_PATTERNS, "Searching for pattern '%s' (%s): %.*s", + name, *regexp == NULL ? "not found" : "found", *regexp_len, *regexp); +--- grok-1.20110708.1.orig/grok_pattern.h ++++ grok-1.20110708.1/grok_pattern.h +@@ -9,7 +9,7 @@ TCLIST *grok_pattern_name_list(const gro + int grok_pattern_add(const grok_t *grok, const char *name, size_t name_len, + const char *regexp, size_t regexp_len); + int grok_pattern_find(const grok_t *grok, const char *name, size_t name_len, +- const char **regexp, size_t *regexp_len); ++ const char **regexp, int *regexp_len); + int grok_patterns_import_from_file(const grok_t *grok, const char *filename); + int grok_patterns_import_from_string(const grok_t *grok, const char *buffer); + +--- grok-1.20110708.1.orig/grokre.c ++++ grok-1.20110708.1/grokre.c +@@ -12,8 +12,8 @@ + + /* global, static variables */ + +-#define CAPTURE_ID_LEN 4 +-#define CAPTURE_FORMAT "%04x" ++#define CAPTURE_ID_LEN 5 ++#define CAPTURE_FORMAT "_%04x" + + /* internal functions */ + static char *grok_pattern_expand(grok_t *grok); //, int offset, int length); +@@ -183,7 +183,7 @@ static char *grok_pattern_expand(grok_t + int start, end, matchlen; + const char *pattern_regex; + int patname_len; +- size_t regexp_len; ++ int regexp_len; + int pattern_regex_needs_free = 0; + + grok_log(grok, LOG_REGEXPAND, "% 20s: %.*s", "start of loop", +--- grok-1.20110708.1.orig/test/grok_pattern.test.c ++++ grok-1.20110708.1/test/grok_pattern.test.c +@@ -4,7 +4,7 @@ + void test_grok_pattern_add_and_find_work(void) { + INIT; + const char *regexp = NULL; +- size_t len = 0; ++ int len = 0; + + grok_pattern_add(&grok, "WORD", 5, "\\w+", 3); + grok_pattern_add(&grok, "TEST", 5, "TEST", 4); diff -Nru grok-1.20110708.1/debian/patches/fix_gcc10.patch grok-1.20110708.1/debian/patches/fix_gcc10.patch --- grok-1.20110708.1/debian/patches/fix_gcc10.patch 2020-04-25 19:55:43.000000000 +0000 +++ grok-1.20110708.1/debian/patches/fix_gcc10.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -Description: Fix FTBFS with GCC-10 - Fix multiple definitions of a variable by declaring it as extern - -Author: Sudip Mukherjee -Bug-Debian: https://bugs.debian.org/957309 - ---- - ---- grok-1.20110708.1.orig/conf.tab.c -+++ grok-1.20110708.1/conf.tab.c -@@ -77,7 +77,7 @@ - #include "grok_input.h" - #include "grok_matchconf.h" - --int yylineno; -+extern int yylineno; - void yyerror (YYLTYPE *loc, struct config *conf, char const *s) { - fprintf (stderr, "Syntax error: %s\n", s); - } diff -Nru grok-1.20110708.1/debian/patches/fix-gperf-version-detection.patch grok-1.20110708.1/debian/patches/fix-gperf-version-detection.patch --- grok-1.20110708.1/debian/patches/fix-gperf-version-detection.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/fix-gperf-version-detection.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,17 +0,0 @@ -From: SZALAY Attila -Date: Wed Aug 9 15:45:05 2017 -0400 -Subject: Fixed gperf version detection - ---- - ---- grok-1.20110708.1.orig/Makefile -+++ grok-1.20110708.1/Makefile -@@ -223,7 +213,7 @@ grok_capture_xdr.h: grok_capture.x - rpcgen -h $< -o $@ - - %.c: %.gperf -- @if $(GPERF) --version | head -1 | egrep -v '3\.[0-9]+\.[0-9]+' ; then \ -+ @if $(GPERF) --version | head -1 | egrep -v '3\.(0\.[3-9]+|[1-9]+)' ; then \ - echo "We require gperf version >= 3.0.3" ; \ - exit 1; \ - fi diff -Nru grok-1.20110708.1/debian/patches/fix-wrong-pointer-alias grok-1.20110708.1/debian/patches/fix-wrong-pointer-alias --- grok-1.20110708.1/debian/patches/fix-wrong-pointer-alias 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/fix-wrong-pointer-alias 1970-01-01 00:00:00.000000000 +0000 @@ -1,55 +0,0 @@ -From: Steve Langasek -Date: Fri, 21 Oct 2016 00:00:00 +0000 -X-Dgit-Generated: 1.20110708.1-4.1 7fc1ec5f57e2299be6b1248db82da42f569c6ab0 -Subject: fix wrong pointer alias - - ---- - ---- grok-1.20110708.1.orig/grok_pattern.c -+++ grok-1.20110708.1/grok_pattern.c -@@ -33,9 +33,9 @@ int grok_pattern_add(const grok_t *grok, - } - - int grok_pattern_find(const grok_t *grok, const char *name, size_t name_len, -- const char **regexp, size_t *regexp_len) { -+ const char **regexp, int *regexp_len) { - TCTREE *patterns = grok->patterns; -- *regexp = tctreeget(patterns, name, name_len, (int*) regexp_len); -+ *regexp = tctreeget(patterns, name, name_len, regexp_len); - - grok_log(grok, LOG_PATTERNS, "Searching for pattern '%s' (%s): %.*s", - name, *regexp == NULL ? "not found" : "found", *regexp_len, *regexp); ---- grok-1.20110708.1.orig/grok_pattern.h -+++ grok-1.20110708.1/grok_pattern.h -@@ -9,7 +9,7 @@ TCLIST *grok_pattern_name_list(const gro - int grok_pattern_add(const grok_t *grok, const char *name, size_t name_len, - const char *regexp, size_t regexp_len); - int grok_pattern_find(const grok_t *grok, const char *name, size_t name_len, -- const char **regexp, size_t *regexp_len); -+ const char **regexp, int *regexp_len); - int grok_patterns_import_from_file(const grok_t *grok, const char *filename); - int grok_patterns_import_from_string(const grok_t *grok, const char *buffer); - ---- grok-1.20110708.1.orig/grokre.c -+++ grok-1.20110708.1/grokre.c -@@ -183,7 +183,7 @@ static char *grok_pattern_expand(grok_t - int start, end, matchlen; - const char *pattern_regex; - int patname_len; -- size_t regexp_len; -+ int regexp_len; - int pattern_regex_needs_free = 0; - - grok_log(grok, LOG_REGEXPAND, "% 20s: %.*s", "start of loop", ---- grok-1.20110708.1.orig/test/grok_pattern.test.c -+++ grok-1.20110708.1/test/grok_pattern.test.c -@@ -4,7 +4,7 @@ - void test_grok_pattern_add_and_find_work(void) { - INIT; - const char *regexp = NULL; -- size_t len = 0; -+ int len = 0; - - grok_pattern_add(&grok, "WORD", 5, "\\w+", 3); - grok_pattern_add(&grok, "TEST", 5, "TEST", 4); diff -Nru grok-1.20110708.1/debian/patches/gperf-function-declaration.patch grok-1.20110708.1/debian/patches/gperf-function-declaration.patch --- grok-1.20110708.1/debian/patches/gperf-function-declaration.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/gperf-function-declaration.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -Description: update patname2macro() declaration for new gperf -Author: Steve Langasek - -Index: grok-1.20110708.1/grok_matchconf_macro.h -=================================================================== ---- grok-1.20110708.1.orig/grok_matchconf_macro.h -+++ grok-1.20110708.1/grok_matchconf_macro.h -@@ -19,6 +19,7 @@ - #endif - - /* this function is generated by gperf */ --const struct strmacro *patname2macro(const char *str, unsigned int len); -+const struct strmacro *patname2macro (register const char *str, register size_t len); -+ - - #endif /* _GROK_MATCHCONF_MACRO_ */ diff -Nru grok-1.20110708.1/debian/patches/move_ldflags.patch grok-1.20110708.1/debian/patches/move_ldflags.patch --- grok-1.20110708.1/debian/patches/move_ldflags.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/move_ldflags.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ -Description: LDFLAGS should be mentioned after source - ---- - ---- a/Makefile -+++ b/Makefile -@@ -172,14 +172,14 @@ cleanver: - # Binary creation - grok: LDFLAGS+=-levent - grok: $(GROKOBJ) conf.tab.o conf.yy.o main.o grok_config.o -- $(CC) $(LDFLAGS) $^ -o $@ -+ $(CC) $^ $(LDFLAGS) -o $@ - - discogrok: $(GROKOBJ) discover_main.o -- $(CC) $(LDFLAGS) $^ -o $@ -+ $(CC) $^ $(LDFLAGS) -o $@ - - libgrok.$(LIBSUFFIX): - libgrok.$(LIBSUFFIX): $(GROKOBJ) -- $(CC) $(LDFLAGS) -fPIC $(DYNLIBFLAG) $(LIBNAMEFLAG) $^ -o $@ -+ $(CC) -fPIC $(DYNLIBFLAG) $(LIBNAMEFLAG) $^ $(LDFLAGS) -o $@ - - libgrok.$(VERLIBSUFFIX): libgrok.$(LIBSUFFIX); - ln -s $< $@ diff -Nru grok-1.20110708.1/debian/patches/pcre-group-name.patch grok-1.20110708.1/debian/patches/pcre-group-name.patch --- grok-1.20110708.1/debian/patches/pcre-group-name.patch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/patches/pcre-group-name.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,33 +0,0 @@ -Description: [fix] grok is not working anymore with PCRE >= 8.34 - From 44ce9372a29319c01d4ac7f24287fb36315e0e34 Mon Sep 17 00:00:00 2001 - From: Guillaume Bour - Subject: [PATCH] [fix] grok is not working anymore with PCRE >= 8.34 because - the latter does not allow anymore a group name to start with digits (PCRE - Changelog version 8.34, point 36) - . - this commit fix the issue by prepending a '_' at the start of group - name. - . - grok (1.20110708.1-4.1) unstable; urgency=medium - . - * Non-maintainer upload. - * Apply fix from upstream to working with PCRE >= 8.34 - (Closes: #775062) -Author: Neil Williams -Bug-Debian: https://bugs.debian.org/775062 -Origin: upstream, https://github.com/jordansissel/grok/commit/44ce9372a29319c01d4ac7f24287fb36315e0e34.patch ---- - ---- grok-1.20110708.1.orig/grokre.c -+++ grok-1.20110708.1/grokre.c -@@ -12,8 +12,8 @@ - - /* global, static variables */ - --#define CAPTURE_ID_LEN 4 --#define CAPTURE_FORMAT "%04x" -+#define CAPTURE_ID_LEN 5 -+#define CAPTURE_FORMAT "_%04x" - - /* internal functions */ - static char *grok_pattern_expand(grok_t *grok); //, int offset, int length); diff -Nru grok-1.20110708.1/debian/patches/series grok-1.20110708.1/debian/patches/series --- grok-1.20110708.1/debian/patches/series 2020-04-25 19:56:14.000000000 +0000 +++ grok-1.20110708.1/debian/patches/series 2021-10-14 19:51:00.000000000 +0000 @@ -1,9 +1 @@ -# debian/source/git-patches exported from git by quilt-patches-deb-export-hook -0001-Support-GNU-kFreeBSD-add-necessary-linker-flag.patch -0002-Support-GNU-Hurd-add-necessary-linker-flag.patch -pcre-group-name.patch -fix-wrong-pointer-alias -fix-gperf-version-detection.patch -gperf-function-declaration.patch -move_ldflags.patch -fix_gcc10.patch +debian-changes diff -Nru grok-1.20110708.1/debian/rules grok-1.20110708.1/debian/rules --- grok-1.20110708.1/debian/rules 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/rules 2021-10-14 19:51:00.000000000 +0000 @@ -6,16 +6,30 @@ # dh-make output file, you may use that output file without restriction. # This special exception was added by Craig Small in version 0.37 of dh-make. -DEB_VERSION := $(shell dpkg-parsechangelog --format rfc822 | grep-dctrl -ensVersion -S .) - # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 -# Provide DEB_HOST_* and DEB_BUILD_* variables -include /usr/share/dpkg/architecture.mk +# Build using TI RPC on GNU/Linux since glibc SunRPC implementation was removed +# in glibc 2.32 +ifeq ($(DEB_HOST_ARCH_LIBC), gnu) + DEB_CFLAGS_MAINT_APPEND += -I/usr/include/tirpc + DEB_LDFLAGS_MAINT_APPEND += -ltirpc +endif + +# Build using -ldl on hurd and kfreebsd +ifneq ($(filter $(DEB_HOST_ARCH_OS),hurd kfreebsd),) + DEB_LDFLAGS_MAINT_APPEND += -ldl +endif + +# Add missing hardening flags +DEB_CFLAGS_MAINT_APPEND += -Wdate-time -D_FORTIFY_SOURCE=2 + +# Import build variables +DPKG_EXPORT_BUILDFLAGS = 1 +include /usr/share/dpkg/default.mk %: - dh $@ + dh $@ override_dh_auto_install: dh_auto_install @@ -42,4 +56,4 @@ sed -i s,patterns/base,/usr/share/grok/patterns/base, debian/grok/usr/share/doc/grok/examples/*.grok override_dh_strip: - dh_strip --dbg-package=grok-dbg + dh_strip --dbgsym-migration='grok-dbg (<< 1.20110708.1-5~)' diff -Nru grok-1.20110708.1/debian/source/git-patches grok-1.20110708.1/debian/source/git-patches --- grok-1.20110708.1/debian/source/git-patches 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/source/git-patches 1970-01-01 00:00:00.000000000 +0000 @@ -1,7 +0,0 @@ -# You probably need to pull the patches/* branches, in order for you to build. -# You also need the following git configuration: -# -# gitpkg.deb-export-hook=/usr/share/gitpkg/hooks/quilt-patches-deb-export-hook - -upstream/1.20110708.1..patches/kfreebsd_build_flags -upstream/1.20110708.1..patches/hurd_build_flags diff -Nru grok-1.20110708.1/debian/source/lintian-overrides grok-1.20110708.1/debian/source/lintian-overrides --- grok-1.20110708.1/debian/source/lintian-overrides 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/source/lintian-overrides 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,3 @@ +grok source: source-is-missing discogrok +grok source: source-is-missing libgrok.so + diff -Nru grok-1.20110708.1/debian/source/options grok-1.20110708.1/debian/source/options --- grok-1.20110708.1/debian/source/options 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/source/options 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,2 @@ +single-debian-patch +auto-commit diff -Nru grok-1.20110708.1/debian/source/patch-header grok-1.20110708.1/debian/source/patch-header --- grok-1.20110708.1/debian/source/patch-header 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/source/patch-header 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,17 @@ +The Debian packaging of grok is maintained in git, using the merging workflow +described in dgit-maint-merge(7). There isn't a patch queue that can be +represented as a quilt series. + +A detailed breakdown of the changes is available from their canonical +representation - git commits in the packaging repository. For example, to see +the changes made by the Debian maintainer in the first upload of upstream +version 1.2.3, you could use: + + % git clone https://git.dgit.debian.org/grok + % cd grok + % git log --oneline 1.2.3..debian/1.2.3-1 -- . ':!debian' + +(If you have dgit, use `dgit clone grok`, rather than plain `git clone`.) + +A single combined diff, containing all the changes, follows. + diff -Nru grok-1.20110708.1/debian/tests/control grok-1.20110708.1/debian/tests/control --- grok-1.20110708.1/debian/tests/control 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/tests/control 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,2 @@ +Test-Command: cd debian/tests && py.test-3 -v +Depends: @,python3-testinfra diff -Nru grok-1.20110708.1/debian/tests/grok/date.grok grok-1.20110708.1/debian/tests/grok/date.grok --- grok-1.20110708.1/debian/tests/grok/date.grok 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/tests/grok/date.grok 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,8 @@ +program { + load-patterns: "/usr/share/grok/patterns/base" + exec "date --iso-8601=seconds" + match { + pattern: "%{TIMESTAMP_ISO8601}" + reaction: "%{@JSON}" + } +} diff -Nru grok-1.20110708.1/debian/tests/grok/hosts.grok grok-1.20110708.1/debian/tests/grok/hosts.grok --- grok-1.20110708.1/debian/tests/grok/hosts.grok 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/tests/grok/hosts.grok 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,8 @@ +program { + load-patterns: "/usr/share/grok/patterns/base" + exec "getent hosts" + match { + pattern: "%{IP:address}\s+%{HOSTNAME:hostname}" + reaction: "%{@JSON}" + } +} diff -Nru grok-1.20110708.1/debian/tests/test_grok.py grok-1.20110708.1/debian/tests/test_grok.py --- grok-1.20110708.1/debian/tests/test_grok.py 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/tests/test_grok.py 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,15 @@ +import re +import sys + +sys.dont_write_bytecode = True + +def test_grok_date(host): + cmd = host.run("grok -f grok/date.grok") + assert cmd.rc == 0 + assert re.search(r"@MATCH", cmd.stdout, flags=re.MULTILINE) + +def test_grok_hosts(host): + cmd = host.run("grok -f grok/hosts.grok") + assert cmd.rc == 0 + assert re.search(r"localhost", cmd.stdout, flags=re.MULTILINE) + diff -Nru grok-1.20110708.1/debian/upstream/metadata grok-1.20110708.1/debian/upstream/metadata --- grok-1.20110708.1/debian/upstream/metadata 1970-01-01 00:00:00.000000000 +0000 +++ grok-1.20110708.1/debian/upstream/metadata 2021-10-14 19:51:00.000000000 +0000 @@ -0,0 +1,3 @@ +--- +Bug-Database: https://github.com/jordansissel/grok/issues +Bug-Submit: https://github.com/jordansissel/grok/issues/new diff -Nru grok-1.20110708.1/debian/watch grok-1.20110708.1/debian/watch --- grok-1.20110708.1/debian/watch 2020-04-25 19:39:45.000000000 +0000 +++ grok-1.20110708.1/debian/watch 2021-10-14 19:51:00.000000000 +0000 @@ -1,5 +1,3 @@ -version=3 -opts=\ -downloadurlmangle=s|.*[?]name=(.*?)&.*|http://semicomplete.googlecode.com/files/$1|,\ -filenamemangle=s|[^/]+[?]name=(.*?)&.*|$1| \ -http://code.google.com/p/semicomplete/downloads/detail[?]name=grok-(\d+\.\d+\.\d+).tar.gz&.* +version=4 +opts=filenamemangle=s/.+\/v?(\d\S+)\.tar\.gz/-$1\.tar\.gz/ \ + https://github.com/jordansissel/grok/tags .*/v?(\d\S+)\.tar\.gz