rockspec: we only need a bit32 module dependency for Lua 5.1.
Lua 5.2 has a builtin bit32 module, and Lua 5.3 provides a deprecated
bit32 module for backwards compatibility.
* luaposix-git-1.rockspec (dependencies): Remove unconditional bit32
dependency, and add it back only if the Lua environment is 5.1.
@@ -14,10 +14,17 @@ description = {
}
dependencies = {
- 'bit32',
'lua >= 5.1, < 5.4',
}
+do
+ -- We only want to install a bit32 module for Lua 5.1.
+ local _ENV={package=nil, dependencies=dependencies}
+ if package then
+ dependencies[#dependencies + 1] = 'bit32'
+ end
+end
+
source = {
url = 'http://github.com/luaposix/luaposix/archive/v' .. _MODREV .. '.zip',
dir = 'luaposix-' .. _MODREV,
