libvips / lua-vips

Lua binding for the libvips image processing library
MIT License
125 stars 10 forks source link

Use Github actions for installing Lua/Luarocks, check all Lua versions #67

Closed rolandlo closed 7 months ago

rolandlo commented 7 months ago

Addresses https://github.com/libvips/lua-vips/pull/66#issuecomment-2004307133

The tests don't succeed with Lua 5.1 and Lua 5.2 yet, but maybe there is a simple fix.

RiskoZoSlovenska commented 7 months ago

The 5.1 failure occurs due to luaffi-tkl's use of luaL_tolstring (which is undefined in Lua 5.1) and needs to be fixed upstream. The 5.2 failure occurs due to luaffi-tkl's use of bitwise operators (which were added to Lua in 5.3) in its bit.lua and also needs to be fixed upstream.

RiskoZoSlovenska commented 7 months ago

BTW, while we're at it, it might be good to also bump the busted and luacheck versions in the Makefile.

rolandlo commented 7 months ago

The 5.1 failure occurs due to luaffi-tkl's use of luaL_tolstring (which is undefined in Lua 5.1) and needs to be fixed upstream.

I agree. Seems like luaL_tostring can simply be replaced by lua_tostring.

The 5.2 failure occurs due to luaffi-tkl's use of bitwise operators (which were added to Lua in 5.3) in its bit.lua and also needs to be fixed upstream.

Here I think we can simply install luabitop for versions 5.1 and 5.2. It removes <prefix>/share/lua/5.2/bit.lua and replaces it by <prefix>/lib/lua/5.2/bit.so

rolandlo commented 7 months ago

Here I think we can simply install luabitop for versions 5.1 and 5.2. It removes <prefix>/share/lua/5.2/bit.lua and replaces it by <prefix>/lib/lua/5.2/bit.so

That works so locally, but not in the CI pipeline. I have reported the two issues upstream and they will be addressed. It just takes some time.