From 3fcd7415a742a87c3a3937f51df65679bb7e6210 Mon Sep 17 00:00:00 2001 From: Luka Blaskovic Date: Thu, 6 Aug 2020 13:33:38 +0000 Subject: [PATCH 1/2] luajit_2_0, luajit_2_1: 2.1.0-2020-03-20 -> 2.1.0-2020-08-05 --- pkgs/development/interpreters/luajit/2.0.nix | 6 +++--- pkgs/development/interpreters/luajit/2.1.nix | 6 +++--- pkgs/development/interpreters/luajit/default.nix | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/pkgs/development/interpreters/luajit/2.0.nix b/pkgs/development/interpreters/luajit/2.0.nix index 3f0fa7303ebb..e96a7c604c70 100644 --- a/pkgs/development/interpreters/luajit/2.0.nix +++ b/pkgs/development/interpreters/luajit/2.0.nix @@ -1,10 +1,10 @@ { self, callPackage, lib }: callPackage ./default.nix { inherit self; - version = "2.0.5-2020-03-20"; - rev = "e613105"; + version = "2.0.5-2020-08-05"; + rev = "2211f6f"; isStable = true; - sha256 = "0k843z90s4hi0qhri6ixy8sv21nig8jwbznpqgqg845ji530kqj7"; + sha256 = "01adxmknq2xyb3w9sn8ilnar8181h7ksd9i80yrsbwzix5lwkn6m"; extraMeta = { # this isn't precise but it at least stops the useless Hydra build platforms = with lib; filter (p: p != "aarch64-linux") (platforms.linux ++ platforms.darwin); diff --git a/pkgs/development/interpreters/luajit/2.1.nix b/pkgs/development/interpreters/luajit/2.1.nix index b5a7894e98d9..f08bbd0e9724 100644 --- a/pkgs/development/interpreters/luajit/2.1.nix +++ b/pkgs/development/interpreters/luajit/2.1.nix @@ -1,8 +1,8 @@ { self, callPackage }: callPackage ./default.nix { inherit self; - version = "2.1.0-2020-03-20"; - rev = "9143e86"; + version = "2.1.0-2020-08-05"; + rev = "10ddae7"; isStable = false; - sha256 = "1zw1yr0375d6jr5x20zvkvk76hkaqamjynbswpl604w6r6id070b"; + sha256 = "1lmjs0gz9vgbhh5f45jvvibpj7f3sz81r8cz4maln9yhc67f2zmk"; } diff --git a/pkgs/development/interpreters/luajit/default.nix b/pkgs/development/interpreters/luajit/default.nix index 9bc76c44937f..9658186b9c09 100644 --- a/pkgs/development/interpreters/luajit/default.nix +++ b/pkgs/development/interpreters/luajit/default.nix @@ -104,6 +104,6 @@ stdenv.mkDerivation rec { homepage = "http://luajit.org"; license = licenses.mit; platforms = platforms.linux ++ platforms.darwin; - maintainers = with maintainers; [ thoughtpolice smironov vcunat andir ]; + maintainers = with maintainers; [ thoughtpolice smironov vcunat andir lblasc ]; } // extraMeta; } From 7c365103d7c51a72ab03bd2526eae56efd718661 Mon Sep 17 00:00:00 2001 From: Luka Blaskovic Date: Sun, 9 Aug 2020 07:26:07 +0000 Subject: [PATCH 2/2] luajit.pkgs.luaexpat: fix redefinition of luaL_setfuncs() --- pkgs/development/lua-modules/luaexpat.patch | 36 +++++++++++++++++++++ pkgs/development/lua-modules/overrides.nix | 3 ++ 2 files changed, 39 insertions(+) create mode 100644 pkgs/development/lua-modules/luaexpat.patch diff --git a/pkgs/development/lua-modules/luaexpat.patch b/pkgs/development/lua-modules/luaexpat.patch new file mode 100644 index 000000000000..3dd609108426 --- /dev/null +++ b/pkgs/development/lua-modules/luaexpat.patch @@ -0,0 +1,36 @@ +diff --git a/src/lxplib.c b/src/lxplib.c +index 1c972db..5712611 100644 +--- a/src/lxplib.c ++++ b/src/lxplib.c +@@ -590,7 +590,7 @@ static void set_info (lua_State *L) { + /* + ** Adapted from Lua 5.2.0 + */ +-static void luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup) { ++static void compat_luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup) { + luaL_checkstack(L, nup, "too many upvalues"); + for (; l->name != NULL; l++) { /* fill the table with given functions */ + int i; +@@ -602,6 +602,8 @@ static void luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup) { + } + lua_pop(L, nup); /* remove upvalues */ + } ++#else ++#define compat_luaL_setfuncs(L, reg, nup) luaL_setfuncs(L, reg, nup) + #endif + + +@@ -612,11 +614,11 @@ int luaopen_lxp (lua_State *L) { + lua_pushvalue(L, -2); + lua_rawset(L, -3); + +- luaL_setfuncs (L, lxp_meths, 0); ++ compat_luaL_setfuncs (L, lxp_meths, 0); + lua_pop (L, 1); /* remove metatable */ + + lua_newtable (L); +- luaL_setfuncs (L, lxp_funcs, 0); ++ compat_luaL_setfuncs (L, lxp_funcs, 0); + set_info (L); + return 1; + } diff --git a/pkgs/development/lua-modules/overrides.nix b/pkgs/development/lua-modules/overrides.nix index 26260872e18a..03fcc933013f 100644 --- a/pkgs/development/lua-modules/overrides.nix +++ b/pkgs/development/lua-modules/overrides.nix @@ -204,6 +204,9 @@ with super; externalDeps = [ { name = "EXPAT"; dep = pkgs.expat; } ]; + patches = [ + ./luaexpat.patch + ]; }); # TODO Somehow automatically amend buildInputs for things that need luaffi