41 Commits
Author SHA1 Message Date
Mirko Vogt fe3a534718 lua: install a pkg-config file for Lua 5.4
Lua stopped shipping a pkg-config file after 5.1; the 5.2, 5.3 and 5.4
release tarballs contain none. Distributions add one to their Lua
packages instead: Debian's liblua5.4-dev ships lua5.4.pc, lua-5.4.pc
and lua54.pc, Alpine's lua5.4-dev ships lua5.4.pc and lua-5.4.pc. Build
systems of Lua consumers look Lua 5.4 up under these names. The package
stages no pkg-config file so far, so such builds cannot find
liblua5.4; the only Lua pkg-config file in the staging directory is
lua.pc of the lua package (5.1.5).

Stage lua5.4.pc, generated from a template with the package version,
and lua-5.4.pc and lua54.pc as links to it. It points to the headers in
/usr/include/lua5.4 and to liblua5.4, and lists libm and libdl as
private libraries for static linking, as the upstream Makefile links
them on Linux.

Of the packages that look up one of these names through pkg-config,
libinput disables its Lua plugin support explicitly in the previous
commit. tio looks up lua-5.4 before lua but depends on lua (5.1), so it
links liblua5.4 without depending on it until the next commit moves it
to Lua 5.4. The others select their Lua version explicitly, look up lua
(5.1) first, build without the feature using Lua, or depend on lua5.4
already.

Assisted-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Mirko Vogt <mirko-openwrt@nanl.de>
2026-10-06 10:40:22 +03:00
Alexandru Ardelean 5432f90a1f lua: drop the lua5.4 LUA_ROOT patch
luaconf.h builds the module search paths out of LUA_ROOT, which upstream
hardcodes to /usr/local, where nothing installs on OpenWrt. LUA_ROOT is
defined unconditionally, but the two macros it feeds, LUA_PATH_DEFAULT
and LUA_CPATH_DEFAULT, are both guarded with #if !defined and are the
only users of it, so set them in TARGET_CFLAGS and drop the patch.

The resulting paths are the ones the patch produced, so the interpreter
behaves exactly as before.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-10-06 10:40:22 +03:00
Alexandru Ardelean 6c5a3c4d78 lua: use LUA_INSTALL_DIR in cqueues, lua-ffi and luaossl
The three Lua variants of each package install the same files, differing
only in the destination directory, so define LUA_INSTALL_DIR next to the
other per-variant settings and share a single install recipe. Same idiom
as luafilesystem, luasec and luaexpat. No packaged path changes.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-10-06 10:40:22 +03:00
Jianhui Zhao 3f87f7ae83 luaossl: fix Lua 5.4 module installation paths
Commit 3fe92e63f5 moved the default Lua 5.4 module search paths
from /usr/local to /usr. luaossl still staged and packaged its Lua 5.4
modules under /usr/local/lib/lua/5.4, outside the default search paths.

Set lua54path and lua54cpath to /usr/lib/lua/5.4 and update the package
install rules to match. Bump PKG_RELEASE to 3 so the corrected package
is offered as an upgrade. Keep Lua 5.1 and Lua 5.3 paths unchanged.

Fixes: 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of /usr/local")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-10-05 12:01:29 +03:00
Jianhui Zhao 76ed3f94ad cqueues: fix Lua 5.4 module installation paths
Commit 3fe92e63f5 moved the default Lua 5.4 module search paths
from /usr/local to /usr. cqueues still staged and packaged its Lua 5.4
modules under /usr/local/lib/lua/5.4, outside the default search paths.

Set lua54path and lua54cpath to /usr/lib/lua/5.4 and update the package
install rules to match. Bump PKG_RELEASE to 3 so the corrected package
is offered as an upgrade. Keep Lua 5.1 and Lua 5.3 paths unchanged.

Fixes: 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of /usr/local")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-10-05 12:01:29 +03:00
Jianhui Zhao 16757d0c2a lua-ffi: fix Lua 5.4 module installation path
Commit 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of
/usr/local") changed LUA_ROOT to /usr/, moving the default Lua 5.4
module search paths out of /usr/local. The Lua 5.4 variant of lua-ffi
still installed ffi.so under /usr/local/lib/lua/5.4, so require("ffi")
could no longer find it with the default search paths.

Install ffi.so under /usr/lib/lua/5.4 to match the new default search
path. Bump PKG_RELEASE to 2 so the corrected package is offered as an
upgrade. Keep the Lua 5.1 and Lua 5.3 installation paths unchanged.

Fixes: 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of /usr/local")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-10-05 12:01:29 +03:00
Jianhui Zhao b5ec1052da lua-cjson: fix Lua 5.4 module installation path
Commit 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of
/usr/local") changed LUA_ROOT to /usr/, moving the default Lua 5.4
module search paths out of /usr/local. The Lua 5.4 variant of lua-cjson
still installed cjson.so under /usr/local/lib/lua/5.4, so require("cjson")
could no longer find it with the default search paths.

Install cjson.so under /usr/lib/lua/5.4 to match the new default search
path. Bump PKG_RELEASE to 6 so the corrected package is offered as an
upgrade. Keep the Lua 5.1 and Lua 5.3 installation paths unchanged.

Fixes: 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of /usr/local")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-10-05 12:01:29 +03:00
Jianhui Zhao afb69d99c7 lua-eco: align module installation with Lua 5.4 search paths
Commit 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of
/usr/local") changed LUA_ROOT to /usr/, moving the default Lua 5.4
module search paths out of /usr/local. lua-eco still installed its Lua
and native modules under /usr/local/lib/lua/5.4, so require() could no
longer find them with the default search paths.

Install modules from the main package and all subpackages under
/usr/lib/lua/5.4, which is searched for both .lua and .so files.
Define LUA_INSTALL_DIR once and use it throughout the install rules so
future directory changes only need one update. Bump PKG_RELEASE to 2
so the corrected packages are offered as upgrades.

Fixes: 3fe92e63f5 ("lua: look for lua5.4 modules under /usr instead of /usr/local")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-10-05 12:01:29 +03:00
Alexandru Ardelean 30de4961d3 luasql: update to 2.7.0
Refresh PKG_HASH from the tag tarball. Upstream moved from
keplerproject to lunarmodules and the 2.7.0 tag has no leading v;
point PKG_SOURCE_URL and the homepage URL at lunarmodules.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-09-08 10:52:20 +03:00
Josef Schlehofer 578758e1f6 luajit2: update to 2026-07-31
Also refresh 020-riscv64-support.patch from the current state of
openresty/luajit2#236. The previous snapshot defined
asm_tail_prep(ASMState *as), but since openresty/luajit2 commit
68354f44 the callers pass a second TraceNo argument, so the riscv64
build failed with:

  lj_asm.c:2559:5: error: too many arguments to function 'asm_tail_prep'

The refreshed patch carries the upstream adaptation and restores the
build. The other four patches apply unchanged.

Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
2026-08-15 12:26:13 +02:00
Josef Schlehofer a6b248d6b8 luajit2: fix build and runtime on powerpc
luajit2 currently fails to link for powerpc: lj_vm.o emits PLT calls
that force BSS-PLT, which the inline-PLT relocations emitted by GCC 12
and newer do not support. Add the same GOT-based fix that
lang/lua/luajit has carried as 060-ppc-musl.patch since 2019.

With that in place the package builds, but ipairs() and pairs() turn
out to be broken on 32-bit big-endian soft-float targets. Both are
regressions in luajit2's PPC64 patch and do not affect upstream
LuaJIT. To be submitted to openresty/luajit2 as well.

Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
2026-08-15 11:29:16 +02:00
Alexandru Ardelean 60f5e4b230 luasec: add Lua 5.4 variant
Add luasec5.4 (Lua 5.4 + luasocket5.4 + libopenssl) next to existing
luasec (Lua 5.1, default). Installs ssl.so / ssl.lua / ssl/https.lua
under /usr/lib/lua/5.4/.

Needed for the prosody 13.x upgrade.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-31 09:46:08 +03:00
Alexandru Ardelean 2eaaed5cdf luasocket: add Lua 5.4 variant
Add luasocket5.4 next to the existing luasocket (Lua 5.1) and
luasocket5.3 variants, installed via the upstream makefile's
'make install LUAV=5.4'.

That makefile defaults to prefix=/usr/local on linux, which is where
the luasocket5.3 variant still installs, so pass prefix=/usr explicitly
to land in /usr/share/lua/5.4 and /usr/lib/lua/5.4 like the other Lua
5.4 module packages.

Needed for the prosody 13.x upgrade.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-31 09:46:08 +03:00
Alexandru Ardelean 59977dc387 luaexpat: add Lua 5.4 variant
Add luaexpat5.4, parallel to existing luaexpat (Lua 5.1, default).
Builds against the Lua 5.4 headers under /usr/include/lua5.4 and
installs to /usr/lib/lua/5.4/. Same pattern as the luasocket 5.3
variant already shipped.

Needed for the prosody 13.x upgrade.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-31 09:46:08 +03:00
Alexandru Ardelean 27152e6f34 luafilesystem: add Lua 5.4 variant
Lua 5.1 is EOL and many downstream packages need 5.2+. Mirror the
luasocket multi-variant pattern: keep luafilesystem (Lua 5.1, default)
and add luafilesystem5.4 which builds the same source against
liblua5.4 and installs to /usr/lib/lua/5.4/.

Needed for the prosody 13.x upgrade (Lua 5.1 unsupported upstream).

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-31 09:46:08 +03:00
Alexandru Ardelean 3fe92e63f5 lua: look for lua5.4 modules under /usr instead of /usr/local
luaconf.h hardcodes LUA_ROOT to "/usr/local/", and nothing in this
package overrides it for the target build, so the interpreter only ever
searches /usr/local/{share,lib}/lua/5.4. Nothing installs there on
OpenWrt, which leaves every Lua 5.4 module package unreachable:

  # lua5.4 -e 'require "lfs"'
  lua5.4: module 'lfs' not found:
          no file '/usr/local/share/lua/5.4/lfs.lua'
          no file '/usr/local/lib/lua/5.4/lfs.so'
          [...]
  # find / -name lfs.so
  /usr/lib/lua/5.4/lfs.so

Point LUA_ROOT at /usr. LUA_LDIR and LUA_CDIR are derived from it and
keep the version suffix, so the search paths become /usr/share/lua/5.4
and /usr/lib/lua/5.4 - exactly where the Lua 5.4 module packages
install. The core lua (5.1) package carries an equivalent patch.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-31 09:46:08 +03:00
Alexandru Ardelean dfb4bd477a lua-eco: fix LUA_ECO_CRASH_BACKTRACE recursive dependency
LUA_ECO_CRASH_BACKTRACE declared "depends on PACKAGE_lua-eco" while
lua-eco's DEPENDS carries "+LUA_ECO_CRASH_BACKTRACE:libunwind", which the
generator turns into "select libunwind if LUA_ECO_CRASH_BACKTRACE". kconfig
then sees lua-eco and the symbol depending on each other:

  error: recursive dependency detected!
    symbol LUA_ECO_CRASH_BACKTRACE depends on PACKAGE_lua-eco
    symbol PACKAGE_lua-eco depends on LUA_ECO_CRASH_BACKTRACE

Drop the redundant guard; the option only affects lua-eco's own build, so
nothing is pulled in when lua-eco itself is not selected.

Fixes: https://github.com/openwrt/packages/pull/30098#issuecomment-5113528752
Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-07-30 14:23:00 +03:00
Jianhui Zhao b7defd3980 lua-eco: update to 4.1.4
Add the new cli module as a separate subpackage.

Expose the optional C crash backtrace diagnostics through
CONFIG_LUA_ECO_CRASH_BACKTRACE. Depend on libunwind when enabled.
Keep the option unavailable on musl/powerpc, where OpenWrt's
libunwind package is not supported.

changelog: https://github.com/zhaojh329/lua-eco/compare/v4.0.0...v4.1.4

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-07-28 09:57:37 +03:00
Jianhui Zhao e1ec189d45 lua-eco: add CONFIG_ prefix to PKG_CONFIG_DEPENDS options
Options listed in PKG_CONFIG_DEPENDS must start with
CONFIG_ prefix.

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-07-11 23:07:44 +08:00
Jianhui Zhao b666073649 lua-ffi: update to 1.3.0
changelog: https://github.com/zhaojh329/lua-ffi/releases/tag/v1.3.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-06-15 11:39:51 +03:00
Seo Suchan 5504291b81 luajit2: update test-version.sh to actual test
old just disabled version test, but as LuaJIt 2.1. part is stable.
So we can use that for test if luajit2 itself able to run.

Fixes: c7ca6d46f7 luajit2: ("add test-version.sh")
Suggested-by: Josef Schlehofer <pepe.schlehofer@gmail.com>

Signed-off-by: Seo Suchan <tjtncks@gmail.com>
2026-06-09 12:14:09 +02:00
Seo Suchan c7ca6d46f7 luajit2: add test-version.sh
luajit2 use build number at -v, but releases are named by date

Signed-off-by: Seo Suchan <tjtncks@gmail.com>
2026-06-07 20:21:09 +02:00
Jianhui Zhao 9f5146f678 lua-eco: update to 4.0.0
changelog: https://github.com/zhaojh329/lua-eco/releases/tag/v4.0.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-05-11 14:39:57 +03:00
Yanase Yuki b0d8a3d384 treewide: cleanup URLs
This commit converts plain HTTP URLs to HTTPS, and updates
old or outdated URLs.

Signed-off-by: Yanase Yuki <dev@zpc.st>
2026-05-08 22:28:27 +02:00
Jianhui Zhao 5e70ed855f lua-ffi: update to 1.2.0
changelog: https://github.com/zhaojh329/lua-ffi/releases/tag/v1.2.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-05-07 18:36:34 +03:00
Alexandru Ardelean a3d2536eb0 lua-openssl: fix Lua detection with CMake 4.3
FindLuaJIT.cmake uses NO_DEFAULT_PATH and only searches hardcoded
luajit-specific paths, so it never finds regular Lua. However if
LUAJIT_INCLUDE_DIRS and LUAJIT_LIBRARY are pre-set in the CMake
cache, find_path/find_library skip their searches, the module sets
LUAJIT_FOUND=ON and also sets LUA_INCLUDE_DIR/LUA_LIBRARIES from
those values, and the if(NOT LUAJIT_FOUND) guard skips the broken
find_package(Lua REQUIRED) call that fails under CMake 4.3.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-05-04 19:26:53 +03:00
Alexandru Ardelean 8238e4ddfa lua-openssl: fix CMake Lua detection in build
The CMakeLists.txt first tries FindLuaJIT.cmake which uses
NO_DEFAULT_PATH with hardcoded host paths, so it always fails in
cross-compilation. The fallback find_package(Lua REQUIRED) may also
fail to find a flat sysroot layout where lua.h lives at
/usr/include/lua.h rather than a versioned subdirectory.

Explicitly pass LUA_INCLUDE_DIR and LUA_LIBRARY to CMake to bypass
both finders, and depend on +liblua (the library package) instead of
+lua to ensure Build/InstallDev runs and Lua headers are present in
the staging directory before this package builds.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-04-30 17:42:26 +03:00
Amnon Paz b1a49e6ca3 lua-openssl: update to 0.11.1
Update Makefile with the version
Remove LuaJIT fix patch - No longer needed
Add "ts-time-cb-signature" patch - Fixes build on various platforms

Signed-off-by: Amnon Paz <pazamnon@gmail.com>
2026-04-26 09:43:24 +03:00
Alexandru Ardelean 8d3c004213 treewide: set me where PKG_MAINTAINER empty
Seems a lot of packages are just getting abandoned by people.
Will pick these up and see them through.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-04-16 21:48:36 +03:00
Jianhui Zhao c5e7174785 lua-eco: update to 3.17.0
changelog: https://github.com/zhaojh329/lua-eco/releases/tag/v3.17.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-04-03 22:22:04 +03:00
Jianhui Zhao d85f1065a5 lua-eco: update to 3.16.0
changelog: https://github.com/zhaojh329/lua-eco/releases/tag/v3.16.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2026-03-28 20:59:35 +02:00
Javier Marcet 1b59cb61a7 luajit2: update to v2.1-20260227
For changes, see tagged commit:
https://github.com/openresty/luajit2/releases/tag/v2.1-20260227

Signed-off-by: Javier Marcet <javier@marcet.info>
2026-03-13 20:00:49 +02:00
Yanase Yuki 670f4c023e lua-lzlib: remove package
This software seems no longer maintained.
The latest upstream commit is 11 years ago,
and upstream repo has been archived.
No package depends on this.

Signed-off-by: Yanase Yuki <dev@zpc.st>
2026-01-09 13:04:41 +01:00
W. Michael Petullo 75c6dc2a7c luafilesystem: update to 1.9.0
This upstream release adds support for Lua 5.5.

Signed-off-by: W. Michael Petullo <mike@flyn.org>
2026-01-09 10:54:56 +01:00
George Sapkin de64f871b0 treewide: fix spelling and grammar in Makefiles
Fix spelling and grammar in package definitions, configs, comments and
other strings.

Signed-off-by: George Sapkin <george@sapk.in>
2025-12-31 09:12:36 +02:00
Josef Schlehofer 47525f3300 luajit2: add riscv64 support
This adds support RISC-V64 to luajit2 by backporting
https://redirect.github.com/openresty/luajit2/pull/236

Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
2025-12-29 12:46:10 +01:00
Christian Marangi 600672b655 lua-ev: add pending patch for CMake >= 4.0 support
Add pending patch for CMake >= 4.0 support. This seems to come from an
OpenSUSE PR and generally modernize the CMake file also increasing the
minimum version for CMake.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-11-25 10:38:04 +01:00
Christian Marangi 1e1cc2d134 lzmq: add patch for CMake >= 4.0 support
Add patch for lzmq for CMake >= 4.0 support.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-11-23 23:48:59 +01:00
Christian Marangi 7b0f7cf705 lualanes: bump to version 3.17.2 and backport CMake >= 4.0 support
Bump lualanes to version 3.17.2 and backport upstream patch for CMake >=
4.0 support.

Apply minor modification to the backport patch as the project moved to
C++ but the 3.17.2 version is still C based.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-11-23 15:16:25 +01:00
Jianhui Zhao 0c79e46f4e lua-eco: update to 3.14.0
A new module `net` added since this version.

changelog: https://github.com/zhaojh329/lua-eco/releases/tag/v3.14.0

Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2025-11-18 06:26:00 +02:00
Alexandru Ardelean 7eebedcdfc lua: move Lua packages under lang/lua sub-folder
There are roughly 50 Lua packages.
It's about time we consider a proposal for moving all of them
under a lang/lua sub-folder.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2025-11-17 08:46:33 +02:00