Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/lua: fix BR2_PACKAGE_LUA_32BITS for Lua5.4
@ 2026-06-29  7:24 daniel
  0 siblings, 0 replies; only message in thread
From: daniel @ 2026-06-29  7:24 UTC (permalink / raw)
  To: buildroot; +Cc: Francois Perrad, Daniel Kipshagen

From: Daniel Kipshagen <daniel@kipshagen.com>

Lua 5.4 changed the way 32 bit lua is configured to define LUA_32BITS as
0 by default instead of leaving it commented out (see commit
dee6433a89b088a1f8da9531a92a2a2693e5dac7 in lua project),
which broke the sed in lua.mk. This resulted in lua5.4 not being
compiled as 32 bit.

This patch updates the sed to replace both versions of luaconf.h
so that 32 bit is configured. Tested with luaconf.h from lua 5.3
and 5.4.

Signed-off-by: Daniel Kipshagen <daniel@kipshagen.com>
---
 package/lua/lua.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/package/lua/lua.mk b/package/lua/lua.mk
index 269eafe4bb..bbff2f2e70 100644
--- a/package/lua/lua.mk
+++ b/package/lua/lua.mk
@@ -67,7 +67,9 @@ endif
 
 ifeq ($(BR2_PACKAGE_LUA_32BITS),y)
 define LUA_32BITS_LUACONF
-	$(SED) 's/\/\* #define LUA_32BITS \*\//#define LUA_32BITS/' $(@D)/src/luaconf.h
+	$(SED)  -e 's@/\* #define LUA_32BITS \*/@#define LUA_32BITS 1@' \
+		-e 's@#define LUA_32BITS[[:space:]]\+0@#define LUA_32BITS 1@' \
+		$(@D)/src/luaconf.h
 endef
 
 LUA_POST_PATCH_HOOKS += LUA_32BITS_LUACONF
-- 
2.33.1.windows.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-06-29  7:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-29  7:24 [Buildroot] [PATCH] package/lua: fix BR2_PACKAGE_LUA_32BITS for Lua5.4 daniel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox