gh-actions-lua icon indicating copy to clipboard operation
gh-actions-lua copied to clipboard

C module loading on windows appears to be broken

Open leso-kn opened this issue 2 years ago • 0 comments

Loading native C modules is currently broken on windows as:

  1. The lua library is not present at a location where it can be seen by lua at runtime
  2. lua.exe is linked statically (not against luaxx.dll) causing "multiple lua VMs" in some occasions (e.g. when trying to load luasocket on Lua 5.2)

Example log when trying to load luasocket:

D:/a/luasocket/luasocket/.lua/bin\lua.exe: error loading module 'socket.core' from file 'C:\Users\runneradmin\AppData\Roaming/luarocks/lib/lua/5.2/socket\core.dll':
	The specified module could not be found.


stack traceback:
	[C]: in ?
	[C]: in function 'require'
	...radmin\AppData\Roaming/luarocks/share/lua/5.2/socket.lua:12: in main chunk
	[C]: in function 'require'
	mimetest.lua:1: in main chunk
	[C]: in ?
D:/a/luasocket/luasocket/.lua/bin\lua.exe: error loading module 'socket.core' from file 'C:\Users\runneradmin\AppData\Roaming/luarocks/lib/lua/5.2/socket\core.dll':
	The specified module could not be found.

leso-kn avatar Oct 27 '23 17:10 leso-kn