git: 893b259a87a7 - main - devel/gcli: fix build with liblowdown-1.4.0
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 29 Dec 2024 12:20:21 UTC
The branch main has been updated by fuz:
URL: https://cgit.FreeBSD.org/ports/commit/?id=893b259a87a7ba8b66c0047b9b52ceae56deb7d1
commit 893b259a87a7ba8b66c0047b9b52ceae56deb7d1
Author: Robert Clausecker <fuz@FreeBSD.org>
AuthorDate: 2024-12-28 13:14:58 +0000
Commit: Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2024-12-29 12:19:56 +0000
devel/gcli: fix build with liblowdown-1.4.0
Upstream has broken the API in this minor update.
Event: 38C3
---
devel/gcli/Makefile | 1 +
devel/gcli/files/patch-src_cmd_cmd.c | 15 +++++++++++++++
2 files changed, 16 insertions(+)
diff --git a/devel/gcli/Makefile b/devel/gcli/Makefile
index 723fd96b0227..ba4cec0045d9 100644
--- a/devel/gcli/Makefile
+++ b/devel/gcli/Makefile
@@ -1,5 +1,6 @@
PORTNAME= gcli
DISTVERSION= 2.5.0
+PORTREVISION= 1
CATEGORIES= devel net
MASTER_SITES= https://herrhotzenplotz.de/gcli/releases/gcli-${DISTVERSION}/
diff --git a/devel/gcli/files/patch-src_cmd_cmd.c b/devel/gcli/files/patch-src_cmd_cmd.c
new file mode 100644
index 000000000000..8e82202932c2
--- /dev/null
+++ b/devel/gcli/files/patch-src_cmd_cmd.c
@@ -0,0 +1,15 @@
+--- src/cmd/cmd.c.orig 2024-12-28 13:13:41 UTC
++++ src/cmd/cmd.c
+@@ -179,9 +179,9 @@ gcli_pretty_print(char const *input, int indent, int m
+ if (!gcli_config_have_colours(g_clictx))
+ opts.oflags |= (LOWDOWN_TERM_NOANSI|LOWDOWN_TERM_NOCOLOUR);
+
+- opts.vmargin = 1;
+- opts.hmargin = indent - 4; /* somehow there's always 4 spaces being emitted by lowdown */
+- opts.cols = maxlinelen;
++ opts.term.vmargin = 1;
++ opts.term.hmargin = indent - 4; /* somehow there's always 4 spaces being emitted by lowdown */
++ opts.term.cols = maxlinelen;
+
+ if ((doc = lowdown_doc_new(&opts)) == NULL)
+ err(1, NULL);