git: a0f1ff5a4e31 - main - editors/pragtical: fix build on powerpc*
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 22 Jan 2025 11:27:49 UTC
The branch main has been updated by pkubaj:
URL: https://cgit.FreeBSD.org/ports/commit/?id=a0f1ff5a4e31fe2265bc09fcb4d2e8510c6222a1
commit a0f1ff5a4e31fe2265bc09fcb4d2e8510c6222a1
Author: Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2025-01-21 21:03:42 +0000
Commit: Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2025-01-22 11:27:03 +0000
editors/pragtical: fix build on powerpc*
1. On powerpc:
../src/api/utf8.c:854:22: error: use of undeclared identifier 'INT_MAX'
854 | if (pose - posi >= INT_MAX) /* (lua_Integer -> int) overflow? */
| ^
2. Also set USES=luajit to use luajit-openresty on powerpc64*.
---
editors/pragtical/Makefile | 2 +-
editors/pragtical/files/patch-src_api_utf8.c | 10 ++++++++++
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/editors/pragtical/Makefile b/editors/pragtical/Makefile
index 950259c57e89..290d294c8830 100644
--- a/editors/pragtical/Makefile
+++ b/editors/pragtical/Makefile
@@ -31,7 +31,7 @@ OPTIONS_DEFAULT= JIT
OPTIONS_SUB= yes
JIT_DESC= Use Lua JIT compiler
-JIT_LIB_DEPENDS= libluajit-5.1.so:lang/luajit-devel
+JIT_USES= luajit
JIT_USES_OFF= lua:54
JIT_MESON_OFF= -Djit=false
diff --git a/editors/pragtical/files/patch-src_api_utf8.c b/editors/pragtical/files/patch-src_api_utf8.c
new file mode 100644
index 000000000000..7a9b5c4cf424
--- /dev/null
+++ b/editors/pragtical/files/patch-src_api_utf8.c
@@ -0,0 +1,10 @@
+--- src/api/utf8.c.orig 2025-01-21 19:20:49 UTC
++++ src/api/utf8.c
+@@ -29,6 +29,7 @@
+ #include <lualib.h>
+
+ #include <assert.h>
++#include <limits.h>
+ #include <string.h>
+ #include <stdint.h>
+ #include <stdlib.h>