Assertion throws err message on fail in buildLuaPackage
This commit is contained in:
parent
164e68c7d3
commit
111b5aa38c
@ -2,22 +2,23 @@ lua:
|
||||
|
||||
{ buildInputs ? [], disabled ? false, ... } @ attrs:
|
||||
|
||||
assert !disabled;
|
||||
if disabled then
|
||||
throw "${attrs.name} not supported by interpreter lua-${lua.luaversion}"
|
||||
else
|
||||
lua.stdenv.mkDerivation ({
|
||||
|
||||
lua.stdenv.mkDerivation ({
|
||||
|
||||
preBuild = ''
|
||||
makeFlagsArray=(
|
||||
PREFIX=$out
|
||||
LUA_LIBDIR="$out/lib/lua/${lua.luaversion}"
|
||||
LUA_INC="-I${lua}/include");
|
||||
'';
|
||||
}
|
||||
//
|
||||
attrs
|
||||
//
|
||||
{
|
||||
name = "lua${lua.luaversion}-" + attrs.name;
|
||||
buildInputs = buildInputs ++ [ lua ];
|
||||
}
|
||||
)
|
||||
preBuild = ''
|
||||
makeFlagsArray=(
|
||||
PREFIX=$out
|
||||
LUA_LIBDIR="$out/lib/lua/${lua.luaversion}"
|
||||
LUA_INC="-I${lua}/include");
|
||||
'';
|
||||
}
|
||||
//
|
||||
attrs
|
||||
//
|
||||
{
|
||||
name = "lua${lua.luaversion}-" + attrs.name;
|
||||
buildInputs = buildInputs ++ [ lua ];
|
||||
}
|
||||
)
|
||||
|
@ -8,7 +8,6 @@
|
||||
{fetchurl, stdenv, lua}:
|
||||
|
||||
let self = _self; _self = with self; {
|
||||
|
||||
inherit (stdenv.lib) maintainers;
|
||||
|
||||
#define build lua package function
|
||||
|
Loading…
Reference in New Issue
Block a user