Can anybody give me help on how to compile dartkable with lua support?
(asked this already in a separate thread but it was a tangential question so perhaps it’s worth repeating my question)
I have installed and compiled lua 5.3 directly from source (followed directions here, “installing from source”: https://www.lua.org/start.html#installing), so now I have the bin, libraries and include files all under /usr/local (that’s in the path).
However when compiling darktable directly from git master I get this message like it’s not finding lua:
-- Checking for one of the modules 'lua53;lua5.3;lua-5.3;lua'
-- Lua support: System library for lua 5.3 not found (to use darktable's version use - -DDONT_USE_INTERNAL_LUA=Off)
I’m also unable to use the flag --DDONT_USE_INTERNAL_LUA as suggested – tried as an argument to ./build.sh but didn’t work.
Sorry guys for not having given more info. I’m on Linux, Ubuntu 18.10.
@wpferguson : yes I did install the lua binary and everything else that got compiled with make linux and then `sudo make install. The binaries are in /usr/local/bin now.
The ubuntu package relies on an external lua interpreter, i.e. the lua5.3 package. The only binary built with the internal lua interpreter enabled is windows, AFAIK.
When compiling darktable, on linux, the build process searches for a lua installation and uses that, if found. You can change the CMakeLists.txt file and enable the internal lua interpreter, which will cause it to get built into the binary.
I’m running ubuntu 18.04. I installed the lua5.3 package using apt-get. I installed darktable from Pascal’s PPA. The lua scripts work fine.
I’ve also downloaded the latest git and compiled it. It builds with lua support enabled automatically and, again, lua scripts work fine.
So I have tried installing lua with apt: sudo apt install lua5.3, the binary gets installed in /usr/bin (while the installation building from source had it insgtalled in /usr/local/bin): no news, darktable still won’t find the damned binary.
And to reply to @darix no I don’t think dartable looks for liblua, it actually searches for one of the following binaries: LUA53 lua53 lua5.3 lua-5.3 lua (as I can see in darktable/cmake/modules/FindLua53.cmake).
Anyway I’ve solved the issue following @wpferguson suggestion, i.e. I edited CMakeLists.txt file and enabled the internal lua interpreter by changing to ON this option:
option(USE_LUA "Build lua scripting support" ON)
(I know you guys know it already but I thought to leave a trace for somebody else that may have similar problems in the future).
Well doh! I did not realize the packages here are updated so frequently! So yes I could’ve spared all the hassle of going through git pull then compiling etc, thanks for reminding me this!
normally they will be triggered on each git push. we have some lags right now but I hope to fix those tomorrow evening. right now they are up2date with HEAD.
Sorry I didn’t make it clear I was having trouble compiling the darktable master for Linux Mint with Lua support until I realised that I need to install the dev version of Lua.
I was just adding the information for other who might stumble as I had done.