Merge pull request #55680 from teto/lua_whitelist

Lua: autogenerate some more packages
This commit is contained in:
Michael Raskin 2019-02-13 13:44:35 +00:00 committed by GitHub
commit 96479afd7f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 129 additions and 152 deletions

View File

@ -7,12 +7,17 @@ fifo
inspect
lgi
lpeg_patterns
lpty
lrexlib-gnu,
lrexlib-posix,
ltermbox,
lua-cmsgpack,
lua_cliargs,
lua-iconv,
lua-term,
luabitop,
luaevent,
luacheck
luaffi,http://luarocks.org/dev,
luuid,
penlight,

1 ansicolors,
7 inspect
8 lgi
9 lpeg_patterns
10 lpty
11 lrexlib-gnu,
12 lrexlib-posix,
13 ltermbox,
14 lua-cmsgpack,
15 lua_cliargs,
16 lua-iconv,
17 lua-term,
18 luabitop,
19 luaevent,
20 luacheck
21 luaffi,http://luarocks.org/dev,
22 luuid,
23 penlight,

View File

@ -190,6 +190,26 @@ lpeg_patterns = buildLuarocksPackage {
};
};
};
lpty = buildLuarocksPackage {
pname = "lpty";
version = "1.2.2-1";
src = fetchurl {
url = https://luarocks.org/lpty-1.2.2-1.src.rock;
sha256 = "1vxvsjgjfirl6ranz6k4q4y2dnxqh72bndbk400if22x8lqbkxzm";
};
disabled = ( luaOlder "5.1");
propagatedBuildInputs = [lua ];
buildType="make";
meta = {
homepage = "http://www.tset.de/lpty/";
description="A simple facility for lua to control other programs via PTYs.";
license = {
fullName = "MIT";
};
};
};
lrexlib-gnu = buildLuarocksPackage {
pname = "lrexlib-gnu";
version = "2.9.0-1";
@ -300,6 +320,26 @@ lua_cliargs = buildLuarocksPackage {
};
};
};
lua-iconv = buildLuarocksPackage {
pname = "lua-iconv";
version = "7-3";
src = fetchurl {
url = https://luarocks.org/lua-iconv-7-3.src.rock;
sha256 = "03xibhcqwihyjhxnzv367q4bfmzmffxl49lmjsq77g0prw8v0q83";
};
disabled = ( luaOlder "5.1");
propagatedBuildInputs = [lua ];
buildType="builtin";
meta = {
homepage = "http://ittner.github.com/lua-iconv/";
description="Lua binding to the iconv";
license = {
fullName = "MIT/X11";
};
};
};
lua-term = buildLuarocksPackage {
pname = "lua-term";
version = "0.7-1";
@ -326,6 +366,76 @@ lua-term = buildLuarocksPackage {
};
};
};
luaevent = buildLuarocksPackage {
pname = "luaevent";
version = "0.4.6-1";
src = fetchurl {
url = https://luarocks.org/luaevent-0.4.6-1.src.rock;
sha256 = "0chq09nawiz00lxd6pkdqcb8v426gdifjw6js3ql0lx5vqdkb6dz";
};
disabled = ( luaOlder "5.1");
propagatedBuildInputs = [lua ];
buildType="builtin";
meta = {
homepage = "https://github.com/harningt/luaevent";
description="libevent binding for Lua";
license = {
fullName = "MIT";
};
};
};
luabitop = buildLuarocksPackage {
pname = "luabitop";
version = "1.0.2-3";
knownRockspec = ( fetchurl {
url = https://luarocks.org/luabitop-1.0.2-3.rockspec;
sha256 = "07y2h11hbxmby7kyhy3mda64w83p4a6p7y7rzrjqgc0r56yjxhcc";
}).outPath;
src = fetchgit ( removeAttrs (builtins.fromJSON ''{
"url": "git://github.com/LuaDist/luabitop.git",
"rev": "81bb23b0e737805442033535de8e6d204d0e5381",
"date": "2013-02-18T16:36:42+01:00",
"sha256": "0lsc556hlkddjbmcdbg7wc2g55bfy743p8ywdzl8x7kk847r043q",
"fetchSubmodules": true
}
'') ["date"]) ;
disabled = ( luaOlder "5.1") || ( luaAtLeast "5.3");
propagatedBuildInputs = [lua ];
buildType="builtin";
meta = {
homepage = "http://bitop.luajit.org/";
description="Lua Bit Operations Module";
license = {
fullName = "MIT/X license";
};
};
};
luacheck = buildLuarocksPackage {
pname = "luacheck";
version = "0.23.0-1";
src = fetchurl {
url = https://luarocks.org/luacheck-0.23.0-1.src.rock;
sha256 = "0akj61c7k1na2mggsckvfn9a3ljfp4agnmr9gp3mac4vin99a1cl";
};
disabled = ( luaOlder "5.1") || ( luaAtLeast "5.4");
propagatedBuildInputs = [lua argparse luafilesystem ];
buildType="builtin";
meta = {
homepage = "https://github.com/mpeterv/luacheck";
description="A static analyzer and a linter for Lua";
license = {
fullName = "MIT";
};
};
};
luaffi = buildLuarocksPackage {
pname = "luaffi";
version = "scm-1";

View File

@ -45,6 +45,20 @@ with super;
lrexlib-gnu = super.lrexlib-gnu.override({
buildInputs = [ pkgs.gnulib ];
});
luaevent = super.luaevent.override({
buildInputs = with pkgs; [ libevent.dev libevent ];
propagatedBuildInputs = [ luasocket ];
extraConfig = ''
variables={
EVENT_INCDIR="${pkgs.libevent.dev}/include";
EVENT_LIBDIR="${pkgs.libevent}/lib";
}
'';
disabled= luaOlder "5.1" || luaAtLeast "5.4" || isLuaJIT;
});
lua-iconv = super.lua-iconv.override({
buildInputs = [ pkgs.libiconv ];
});
luv = super.luv.overrideAttrs(oa: {
propagatedBuildInputs = oa.propagatedBuildInputs ++ [ pkgs.libuv ];
});

View File

@ -167,43 +167,6 @@ with self; {
};
};
luabitop = buildLuaPackage rec {
version = "1.0.2";
name = "bitop-${version}";
src = fetchurl {
url = "http://bitop.luajit.org/download/LuaBitOp-${version}.tar.gz";
sha256 = "16fffbrgfcw40kskh2bn9q7m3gajffwd2f35rafynlnd7llwj1qj";
};
buildFlags = stdenv.lib.optionalString stdenv.isDarwin "macosx";
disabled = isLua53;
postPatch = stdenv.lib.optionalString stdenv.isDarwin ''
substituteInPlace Makefile --replace 10.4 10.5
'';
preBuild = ''
makeFlagsArray=(
${stdenv.lib.optionalString stdenv.cc.isClang "CC=$CC"}
INCLUDES="-I${lua}/include"
LUA="${lua}/bin/lua");
'';
installPhase = ''
mkdir -p $out/lib/lua/${lua.luaversion}
install -p bit.so $out/lib/lua/${lua.luaversion}
'';
meta = with stdenv.lib; {
description = "C extension module for Lua which adds bitwise operations on numbers";
homepage = "http://bitop.luajit.org";
license = licenses.mit;
maintainers = with maintainers; [ ];
};
};
http = buildLuaPackage rec {
version = "0.2";
name = "http-${version}";
@ -236,36 +199,6 @@ with self; {
};
};
luacheck = buildLuaPackage rec {
pname = "luacheck";
version = "0.20.0";
name = "${pname}-${version}";
src = fetchFromGitHub {
owner = "mpeterv";
repo = "luacheck";
rev = "${version}";
sha256 = "0ahfkmqcjhlb7r99bswy1sly6d7p4pyw5f4x4fxnxzjhbq0c5qcs";
};
propagatedBuildInputs = [ lua ];
# No Makefile.
dontBuild = true;
installPhase = ''
${lua}/bin/lua install.lua $out
'';
meta = with stdenv.lib; {
description = "A tool for linting and static analysis of Lua code";
homepage = https://github.com/mpeterv/luacheck;
license = licenses.mit;
maintainers = with maintainers; [ vyp ];
platforms = platforms.unix;
};
};
luacyrussasl = buildLuaPackage rec {
version = "1.1.0";
name = "lua-cyrussasl-${version}";
@ -295,37 +228,6 @@ with self; {
};
};
luaevent = buildLuaPackage rec {
version = "0.4.4";
name = "luaevent-${version}";
src = fetchFromGitHub {
owner = "harningt";
repo = "luaevent";
rev = "v${version}";
sha256 = "1krzxr0jkv3gmhpckp02byhdd9s5dd0hpyqc8irc8i79dd8x0p53";
};
preBuild = ''
makeFlagsArray=(
INSTALL_DIR_LUA="$out/share/lua/${lua.luaversion}"
INSTALL_DIR_BIN="$out/lib/lua/${lua.luaversion}"
LUA_INC_DIR="${lua}/include"
);
'';
buildInputs = [ libevent ];
propagatedBuildInputs = [ luasocket ];
meta = with stdenv.lib; {
homepage = http://luaforge.net/projects/luaevent/;
description = "Binding of libevent to Lua";
license = licenses.mit;
maintainers = with maintainers; [ koral ];
};
};
luaexpat = buildLuaPackage rec {
version = "1.3.0";
name = "expat-${version}";
@ -482,60 +384,6 @@ with self; {
};
};
lpty = buildLuaPackage rec {
version = "1.2.1";
name = "lpty-${version}";
src = fetchurl {
url = "http://www.tset.de/downloads/lpty-${version}-1.tar.gz";
sha256 = "0rgvbpymcgdkzdwfag607xfscs9xyqxg0dj0qr5fv906mi183gs6";
};
preBuild = ''
makeFlagsArray=(
INST_LIBDIR="$out/lib/lua/${lua.luaversion}"
INST_LUADIR="$out/share/lua/${lua.luaversion}"
LUA_BINDIR="${lua}/bin"
LUA_INCDIR="-I${lua}/include"
LUA_LIBDIR="-L${lua}/lib"
);
'';
meta = with stdenv.lib; {
description = "PTY control for Lua";
homepage = "http://www.tset.de/lpty";
license = licenses.mit;
maintainers = with maintainers; [ vyp ];
platforms = platforms.linux;
};
};
lua-iconv = buildLuaPackage rec {
name = "lua-iconv-${version}";
version = "7";
src = fetchFromGitHub {
owner = "ittner";
repo = "lua-iconv";
rev = name;
sha256 = "0rd76966qlxfp8ypkyrbif76nxnm1acclqwfs45wz3972jsk654i";
};
preBuild = ''
makeFlagsArray=(
INSTALL_PATH="$out/lib/lua/${lua.luaversion}"
);
'';
meta = with stdenv.lib; {
description = "Lua bindings for POSIX iconv";
homepage = "https://ittner.github.io/lua-iconv/";
license = licenses.mit;
maintainers = with maintainers; [ richardipsum ];
platforms = platforms.unix;
};
};
luasec = buildLuaPackage rec {
name = "sec-0.6";