From 6fda86789fdf1ea216fab0a80cb2e6f3f9769967 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Thu, 29 Jan 2026 18:53:43 +0100 Subject: [PATCH] luaPackages.readline: move out of overrides --- pkgs/development/lua-modules/overrides.nix | 47 ------------------- .../lua-modules/readline/default.nix | 45 ++++++++++++++++++ pkgs/top-level/lua-packages.nix | 2 + 3 files changed, 47 insertions(+), 47 deletions(-) create mode 100644 pkgs/development/lua-modules/readline/default.nix diff --git a/pkgs/development/lua-modules/overrides.nix b/pkgs/development/lua-modules/overrides.nix index fd95c001628a..65901e802f4f 100644 --- a/pkgs/development/lua-modules/overrides.nix +++ b/pkgs/development/lua-modules/overrides.nix @@ -937,53 +937,6 @@ in ''; }; - readline = final.callPackage ( - { - buildLuarocksPackage, - fetchurl, - luaAtLeast, - luaOlder, - luaposix, - }: - # upstream broken, can't be generated, so moved out from the generated set - buildLuarocksPackage { - pname = "readline"; - version = "3.2-0"; - knownRockspec = - (fetchurl { - url = "mirror://luarocks/readline-3.2-0.rockspec"; - sha256 = "1r0sgisxm4xd1r6i053iibxh30j7j3rcj4wwkd8rzkj8nln20z24"; - }).outPath; - src = fetchurl { - # the rockspec url doesn't work because 'www.' is not covered by the certificate so - # I manually removed the 'www' prefix here - url = "http://pjb.com.au/comp/lua/readline-3.2.tar.gz"; - sha256 = "1mk9algpsvyqwhnq7jlw4cgmfzj30l7n2r6ak4qxgdxgc39f48k4"; - }; - - luarocksConfig.variables = rec { - READLINE_INCDIR = "${readline.dev}/include"; - HISTORY_INCDIR = READLINE_INCDIR; - }; - unpackCmd = '' - unzip "$curSrc" - tar xf *.tar.gz - ''; - - propagatedBuildInputs = [ - luaposix - readline.out - ]; - - meta = { - homepage = "https://pjb.com.au/comp/lua/readline.html"; - description = "Interface to the readline library"; - license.fullName = "MIT/X11"; - broken = (luaOlder "5.1") || (luaAtLeast "5.5"); - }; - } - ) { }; - rocks-dev-nvim = prev.rocks-dev-nvim.overrideAttrs { # E5113: Error while calling lua chunk [...] pl.path requires LuaFileSystem diff --git a/pkgs/development/lua-modules/readline/default.nix b/pkgs/development/lua-modules/readline/default.nix new file mode 100644 index 000000000000..ef2a04267fe2 --- /dev/null +++ b/pkgs/development/lua-modules/readline/default.nix @@ -0,0 +1,45 @@ +{ + buildLuarocksPackage, + fetchurl, + luaAtLeast, + luaOlder, + luaposix, + readline, +}: +# upstream broken, can't be generated, so moved out from the generated set +buildLuarocksPackage { + pname = "readline"; + version = "3.2-0"; + knownRockspec = + (fetchurl { + url = "mirror://luarocks/readline-3.2-0.rockspec"; + sha256 = "1r0sgisxm4xd1r6i053iibxh30j7j3rcj4wwkd8rzkj8nln20z24"; + }).outPath; + src = fetchurl { + # the rockspec url doesn't work because 'www.' is not covered by the certificate so + # I manually removed the 'www' prefix here + url = "http://pjb.com.au/comp/lua/readline-3.2.tar.gz"; + sha256 = "1mk9algpsvyqwhnq7jlw4cgmfzj30l7n2r6ak4qxgdxgc39f48k4"; + }; + + luarocksConfig.variables = rec { + READLINE_INCDIR = "${readline.dev}/include"; + HISTORY_INCDIR = READLINE_INCDIR; + }; + unpackCmd = '' + unzip "$curSrc" + tar xf *.tar.gz + ''; + + propagatedBuildInputs = [ + luaposix + readline.out + ]; + + meta = { + homepage = "https://pjb.com.au/comp/lua/readline.html"; + description = "Interface to the readline library"; + license.fullName = "MIT/X11"; + broken = (luaOlder "5.1") || (luaAtLeast "5.5"); + }; +} diff --git a/pkgs/top-level/lua-packages.nix b/pkgs/top-level/lua-packages.nix index fc17bc35f2bd..ce44a1a21147 100644 --- a/pkgs/top-level/lua-packages.nix +++ b/pkgs/top-level/lua-packages.nix @@ -253,6 +253,8 @@ rec { inherit (pkgs) zenity; }; + readline = callPackage ../development/lua-modules/readline { inherit (pkgs) readline; }; + vicious = callPackage ( { fetchFromGitHub }: stdenv.mkDerivation rec {