diff options
author | Matthew Wild <mwild1@gmail.com> | 2010-01-28 18:10:20 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2010-01-28 18:10:20 +0000 |
commit | 7086dd06fe621c3369388bb4a1ac9ef1deaa7635 (patch) | |
tree | 3e91e10871f6a093b3adc768a10d794e2b522e8e /util | |
parent | 27ff687531a5e9c1cbc991b2fa53829089e2a254 (diff) | |
download | prosody-7086dd06fe621c3369388bb4a1ac9ef1deaa7635.tar.gz prosody-7086dd06fe621c3369388bb4a1ac9ef1deaa7635.zip |
util.dependencies: Load luarocks.loader/luarocks.require
Diffstat (limited to 'util')
-rw-r--r-- | util/dependencies.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/util/dependencies.lua b/util/dependencies.lua index 13f88f79..72a7cafe 100644 --- a/util/dependencies.lua +++ b/util/dependencies.lua @@ -10,6 +10,11 @@ module("dependencies", package.seeall) function softreq(...) local ok, lib = pcall(require, ...); if ok then return lib; else return nil, lib; end end +-- Required to be able to find packages installed with luarocks +if not softreq "luarocks.loader" then -- LuaRocks 2.x + softreq "luarocks.require"; -- LuaRocks <1.x +end + function missingdep(name, sources, msg) print(""); print("**************************"); |