Update to Lua 5.3.5
Closed this issue · 6 comments
swaldhoer commented
Download: Lua 5.3.5
- Update sources
- Change build instructions for FreeBSD
- Change build instructions for macOS (nothing to do)
swaldhoer commented
diff --git a/Makefile5.3.4 b/Makefile5.3.5
index d71c75c..64c78f7 100644
--- a/Makefile5.3.4
+++ b/Makefile5.3.5
@@ -102,7 +102,7 @@ c89:
freebsd:
- $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX" SYSLIBS="-Wl,-E -lreadline"
+ $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX -DLUA_USE_READLINE -I/usr/include/edit" SYSLIBS="-Wl,-E -ledit" CC="cc"
generic: $(ALL)
@@ -110,7 +110,7 @@ linux:
$(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX" SYSLIBS="-Wl,-E -ldl -lreadline"
macosx:
- $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_MACOSX" SYSLIBS="-lreadline" CC=cc
+ $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_MACOSX" SYSLIBS="-lreadline"
mingw:
$(MAKE) "LUA_A=lua53.dll" "LUA_T=lua.exe" \
swaldhoer commented
The diff of the Makefile
shows that the setup for FreeBSD is wrong in the original sources. FreeBSD defines LUA_USE_LINUX
and this implicitly redefines LUA_USE_READLINE
:
luaconf.h
#if defined(LUA_USE_LINUX)
#define LUA_USE_POSIX
#define LUA_USE_DLOPEN /* needs an extra library: -ldl */
#define LUA_USE_READLINE /* needs some extra libraries */
#endif
swaldhoer commented
swaldhoer commented
Running full tests on version 5.3.4
works locally (not on cirrus, not sure why). Running full tests fails in main.lua line 239 (https://github.com/swaldhoer/native-lua/runs/212079729).
Building the official release with make, leads to the same error, therefore there must be something wrong on the official build instructions.
swaldhoer commented
The Makefile bug is known https://www.lua.org/bugs.html#5.3.5-1.