[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: LuaRocks installation (Ubuntu Linux)
- From: Hisham <h@...>
- Date: Tue, 24 Jul 2018 14:25:24 -0300
On 24 July 2018 at 10:46, Dirk Laurie <email@example.com> wrote:
> I have an opportunity to add LuaRocks from scratch on a machine that
> did not yet have even Lua.
> I did the following on an Ubuntu 16.04 laptop recently handed down to me:
> 1. Downloaded Lua 5.3.5 into a local directory, built it (I needed to
> do that twice, installing libreadline-dev in between), installed it
> (it goes to /usr/local by default).
This is the expected behavior, because Linux applications installed by
hand should install into /usr/local.
> 2. Installed luarocks via the APT tool. This installs luarocks 2.2.0,
> and also lua 5.1,
Which is unfortunately quite out-of-date. Please nag the maintainers
of your favorite distro for updated LuaRocks versions. :)
> in /usr, not /usr/local.
Again, this is expected behavior, because Linux applications installed
via package manager should install into /usr.
> It came as a bit of a shock that a two-year old distro still installs
> 5.1 as default lua.
Please nag the maintainers of your favorite distro for updated Lua versions. :)
> 1. How do I get Luarocks to install 5.3 versions?
Install it from source, the same way you installed Lua (as a general
guideline, using the same installation method for your Lua and your
LuaRocks should result in compatible combinations.)
> 2. Can one install Luarocks 3.0.0 via an older Luarocks?
Unfortunately not, because this is a major release with some bigger
However, future LuaRocks 3.x will be installable from LuaRocks 3.0
(provided you install it as a rock using "make bootstrap" — there is
also a standard "make install" rule which installs it as a regular
non-rock application, which is useful for distro maintainers)
> It came as a bit of a shock that a two-year old distro still installs 5.1 as default lua.
That is indeed unfortunate. The good news is that a single LuaRocks
3.0 installation can manage packages for any Lua/LuaJIT
version/installation (using flags --lua-version and --lua-dir), no
matter what Lua version LuaRocks itself is using to run (this is one
of those big architectural changes!). So in the future such mismatches
will no longer be a hassle.
Hope this helps!