lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Carl Yogehnburg wrote:
> compiled luasocket with lua52.dll and lua52.lib
> 
> now lua interpreter asks for lua52.dll when I type "local socket =
> require("socket.core")"
> 
> when I put lua52.dll near the exe, I receive the same multiple lua vms
> detected error.
> 
> I guess I'm doing something blatantly wrong here but couldn't figure it out.

I've mainly worked with MinGW when compiling Lua applications on
windows, so I don't know the exact options for MSVC.

On Windows you need to make sure that both the application that opens
the Lua state and the library are using the same Lua-DLL.  The advice
for Unix systems to include Lua statically in your application does not
work for Windows.

If both your application as well as the library are using the same DLL
and none include the Lua functions themselves, it should work.

Best regards,

David Kolf