<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/0e4063fe980f8cc6fa0c8a946c163ddfbeaa414f">https://github.com/macports/macports-ports/commit/0e4063fe980f8cc6fa0c8a946c163ddfbeaa414f</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 0e4063fe980f8cc6fa0c8a946c163ddfbeaa414f
</span>Author: Ryan Schmidt <ryandesign@macports.org>
AuthorDate: Thu Jan 20 12:55:26 2022 -0600
<span style='display:block; white-space:pre;color:#404040;'> grok: Fix implicit declaration of functions
</span>---
sysutils/grok/Portfile | 4 ++++
sysutils/grok/files/bison.patch | 32 ++++++++++++++++++++++++++++++++
sysutils/grok/files/implicit.patch | 26 ++++++++++++++++++++++++++
sysutils/grok/files/semicolon.patch | 14 ++++++++++++++
4 files changed, 76 insertions(+)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/sysutils/grok/Portfile b/sysutils/grok/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 4d9edf9330f..06f2f38ee87 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/sysutils/grok/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/sysutils/grok/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -35,7 +35,10 @@ depends_lib port:libevent \
</span> port:tokyocabinet
patchfiles Makefile.patch \
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ bison.patch \
</span> gperf3.1.patch \
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ implicit.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ semicolon.patch \
</span> pcre8.34.patch
post-patch {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -51,6 +54,7 @@ post-patch {
</span> build.env "GPERF=${prefix}/bin/gperf"
platform darwin 8 {
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Presumed necessary. Documentation says it works with gmake 3.81; Tiger has 3.80.
</span> depends_build-append \
port:gmake
build.cmd ${prefix}/bin/gmake
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/sysutils/grok/files/bison.patch b/sysutils/grok/files/bison.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..0edba043350
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/sysutils/grok/files/bison.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,32 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Fix:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+conf.tab.c:1302:1: error: conflicting types for 'yyparse'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+grok's #include order is messed up. conf.y includes conf.tab.h (which
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+uses the type struct config) before it includes grok_config.h (which
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+defines the type). C requires declaration before use, so it should
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+include the files in the other order. Some compilers will go ahead and
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+compile anyway, depending on their flags; others won't.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://lists.gnu.org/archive/html/bug-bison/2022-01/msg00013.html
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- conf.lex.orig 2011-10-28 02:17:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ conf.lex 2022-01-20 09:33:55.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1,7 +1,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ %{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <string.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#include "conf.tab.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "grok_config.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include "conf.tab.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "stringhelper.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ %}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- conf.y.orig 2011-10-28 02:17:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ conf.y 2022-01-20 09:25:45.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2,8 +2,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <stdio.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <string.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#include "conf.tab.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "grok_config.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include "conf.tab.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "grok_input.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "grok_matchconf.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/sysutils/grok/files/implicit.patch b/sysutils/grok/files/implicit.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..06c8a5ad9d8
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/sysutils/grok/files/implicit.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,26 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Fix:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+error: implicit declaration of function 'conf_new_patternfile' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://github.com/jordansissel/grok/pull/40
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+error: implicit declaration of function 'yylex' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://github.com/jordansissel/grok/issues/39
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- grok_config.h.orig 2011-10-28 02:17:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ grok_config.h 2022-01-17 03:06:49.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -21,6 +21,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ void conf_init(struct config *conf);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ void conf_new_program(struct config *conf);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++void conf_new_patternfile(struct config *conf);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ void conf_new_input(struct config *conf);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ void conf_new_input_process(struct config *conf, char *cmd);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ void conf_new_input_file(struct config *conf, char *filename);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- conf.y.orig 2011-10-28 02:17:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ conf.y 2022-01-20 12:46:24.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -12,6 +12,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ fprintf (stderr, "Syntax error: %s\n", s);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++int yylex (YYSTYPE *lvalp, YYLTYPE *llocp);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define DEBUGMASK(val) ((val > 0) ? ~0 : 0)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ %}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/sysutils/grok/files/semicolon.patch b/sysutils/grok/files/semicolon.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..224d332a135
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/sysutils/grok/files/semicolon.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,14 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Fix:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+conf.y:132:87: error: expected ';' after expression
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://github.com/jordansissel/grok/pull/41
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- conf.y.orig 2022-01-17 03:08:32.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ conf.y 2022-01-17 03:09:50.000000000 -0600
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -129,7 +129,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ | match_block_statement
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ match_block_statement: /* empty */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- | "pattern" ':' QUOTEDSTRING { conf_new_match_pattern(conf, $3) }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ | "pattern" ':' QUOTEDSTRING { conf_new_match_pattern(conf, $3); }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ | "reaction" ':' QUOTEDSTRING { CURMATCH.reaction = $3; }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ | "reaction" ':' "none" { CURMATCH.no_reaction = 1; }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ | "shell" ':' QUOTEDSTRING { CURMATCH.shell = $3; }
</span></pre><pre style='margin:0'>
</pre>