lua-users home
lua-l archive

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




On 3 Apr 2019, at 12:08, Simon Orde <SimonOrde@family-historian.co.uk> wrote:

Hi - Is this the right place to ask a LuaRocks question?  I’ve been trying to build various lua dlls using LuaRocks – for Lua5.3 and the VC runtime for Visual Studio 2017 (VCRUNTIME140.DLL).   I downloaded luawinmulti-master.zip and tried to follow the instructions.  I had one folder for the luawinmulti-master stuff and another target folder to build into.   I opened the Visual Studio 2017 Tools Command Prompt (where hopefully all the paths etc are set up as needed) and in the luawinmulti-master folder ran 
 
MAKE --53 install “D:\My\Lua”
 
to build into the target folder.  I set up environment variables as instructed (I think – not sure what the ‘rocktree’ references are about).  Still in the same command shell I ran

Not sure what environment variables you’re referring to. Only thing I can think of is the output of the LuaRocks installer. But you can ignore this, and instead use the supplied batch file `setlua.bat`, see https://github.com/Tieske/luawinmulti#usage
(LuaWinMulti install LuaRocks and does the hard work for you, so the intermediate output by LuaRocks can be ignored)


 
·         luarocks53 install luafilesystem                  (to build lfs.dll)
·         luarocks53 install luacom                              (to build lua.com.dll)

·         luarocks53 install md5                                    (to build des56.dll and md5\core.dll)

 
lfs.dll, des56.dll, and md5\core.dll all appear OK as far as I can see.  If I look at them in Dependencies (the app), they link to Lua53.dll and VCRUNTIME140.DLL.  But something is not right when I build luacom.dll.  For some reason, it shows in Dependencies linked to Lua5.1.dll and MSVCR80.dll.
 
I have tried all the variations I can think of but somehow luacom.dll always ends up linked to 5.1 and MSVCR80.dll.  Has anyone got any suggestions as to what I may be doing wrong?  I should add that I have never used LuaRocks before.

the rockspec relies on Make instead of the LuaRocks builtin build tools; https://github.com/davidm/luacom/blob/master/luacom-1.4-1.rockspec#L19
Essentially this means LuaRocks has less control over how it is build, and in this case it seems to work against you.

This is a really old library, the makefile has quite some references to 5.1 (https://github.com/davidm/luacom/blob/master/Makefile.win )

The good news, is that in the repo above, there also is a `Makefile53.win` so maybe you could use that? Just clone the repo, rename that file to `Makefile.win` and do `luarocks make` from the repo
(Make sure to do it from the VS command shell, and first call `setlua.bat 53`)

Have no Windows system myself…

Thijs


 
Simon