From: Alexandru Ardelean Date: Tue, 26 May 2026 11:15:12 +0000 (+0300) Subject: luasocket: add Lua 5.4 variant X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=2eaaed5cdfcf32a3c7b550d705fd7ca3e2860e73;p=openwrt-packages.git 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 --- diff --git a/lang/lua/luasocket/Makefile b/lang/lua/luasocket/Makefile index 973192ec7..6443f8ce2 100644 --- a/lang/lua/luasocket/Makefile +++ b/lang/lua/luasocket/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luasocket PKG_VERSION:=3.1.0 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE_PROTO:=git PKG_SOURCE_VERSION:=v$(PKG_VERSION) @@ -44,6 +44,13 @@ define Package/luasocket5.3 VARIANT:=lua-53 endef +define Package/luasocket5.4 + $(Package/luasocket/default) + TITLE:=LuaSocket 5.4 + DEPENDS:=+liblua5.4 + VARIANT:=lua-54 +endef + ifeq ($(BUILD_VARIANT),lua-51) LUA_VERSION=5.1 endif @@ -52,6 +59,10 @@ ifeq ($(BUILD_VARIANT),lua-53) LUA_VERSION=5.3 endif +ifeq ($(BUILD_VARIANT),lua-54) + LUA_VERSION=5.4 +endif + define Package/luasocket/default/description LuaSocket is the most comprehensive networking support @@ -60,6 +71,7 @@ define Package/luasocket/default/description endef Package/luasocket/description = $(Package/luasocket/default/description) Package/luasocket5.3/description = $(Package/luasocket/default/description) +Package/luasocket5.4/description = $(Package/luasocket/default/description) define Build/Configure endef @@ -95,6 +107,15 @@ define Package/luasocket5.3/install install endef +define Package/luasocket5.4/install + $(MAKE) -C $(PKG_BUILD_DIR)/src \ + DESTDIR="$(1)" \ + prefix=/usr \ + LUAV=$(LUA_VERSION) \ + install +endef + $(eval $(call BuildPackage,luasocket)) $(eval $(call BuildPackage,luasocket5.3)) +$(eval $(call BuildPackage,luasocket5.4))