[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] LuaRocks 3.0.0beta1 for Unix
- From: Matthew Wild <mwild1@...>
- Date: Fri, 6 Jul 2018 13:04:28 +0100
Hi, sorry for the delayed response, I was travelling yesterday.
On 5 July 2018 at 15:01, Hisham <h@hisham.hm> wrote:
> On 5 July 2018 at 10:00, Matthew Wild <mwild1@gmail.com> wrote:
>> It looks like path.rocks_dir() is passed nil, and cfg.root_dir is nil
>> also. Is this expected behaviour?
>
> Definitely not!
>
> Let's try to diagnose this:
>
> * Did you install using `make; sudo make install` or `sudo make bootstrap`?
I ran make and sudo make install
> * Did it create a config file /usr/local/etc/luarocks/config-5.4.lua?
Yes:
<<<<<<<<<<
-- LuaRocks configuration
rocks_trees = {
{ name = "user", root = home .. "/.luarocks" },
{ name = "system", root = "/usr/local" },
}
lua_interpreter = "lua5.4"
variables = {
LUA_DIR = "/usr/local",
LUA_BINDIR = "/usr/local/bin",
}
<<<<<<<<<<
> * Also, could you paste the /usr/local/bin/luarocks launcher script?
>
> Also, the installer failed to create the versioned `luarocks-5.4`
> symlink, right? Just noticed that.
Ah right, indeed, it created /usr/local/bin/luarocks (no suffix) after
the 'make install'. I ran that and it confirmed it was using Lua 5.4
so I simply moved it manually to /usr/local/bin/luarocks-5.4.
The launcher seems (to me) to be as expected, content follows:
<<<<<<<<<<
#!/usr/local/bin/lua5.4
package.loaded['luarocks.core.hardcoded'] = { SYSCONFDIR =
[[/usr/local/etc/luarocks]] }
package.path=[[/usr/local/share/lua/5.4/?.lua;]] .. package.path
local loader = require("luarocks.loader")
local cmd = require("luarocks.cmd")
local description = "LuaRocks main command-line interface"
local commands = {
help = "luarocks.cmd.help",
init = "luarocks.cmd.init",
pack = "luarocks.cmd.pack",
unpack = "luarocks.cmd.unpack",
build = "luarocks.cmd.build",
install = "luarocks.cmd.install",
search = "luarocks.cmd.search",
list = "luarocks.cmd.list",
remove = "luarocks.cmd.remove",
make = "luarocks.cmd.make",
download = "luarocks.cmd.download",
path = "luarocks.cmd.path",
show = "luarocks.cmd.show",
new_version = "luarocks.cmd.new_version",
lint = "luarocks.cmd.lint",
write_rockspec = "luarocks.cmd.write_rockspec",
purge = "luarocks.cmd.purge",
doc = "luarocks.cmd.doc",
upload = "luarocks.cmd.upload",
config = "luarocks.cmd.config",
which = "luarocks.cmd.which",
test = "luarocks.cmd.test",
}
cmd.run_command(description, commands, "luarocks.cmd.external", ...)
<<<<<<<<<<
Regards,
Matthew