Commit e8dbe285 authored by Matthieu Coudron's avatar Matthieu Coudron
Browse files

luaPackages.readline: moved out from the generated set

parent 9429b569
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -100,7 +100,6 @@ penlight,https://github.com/lunarmodules/Penlight.git,,,,,alerque
plenary.nvim,https://github.com/nvim-lua/plenary.nvim.git,,,,5.1,
rapidjson,https://github.com/xpol/lua-rapidjson.git,,,,,
rest.nvim,,,,,5.1,teto
readline,,,,,,
say,https://github.com/Olivine-Labs/say.git,,,,,
serpent,,,,,,lockejan
sqlite,,,,,,
+29 −6
Original line number Diff line number Diff line
@@ -322,7 +322,7 @@ with prev;
    externalDeps = [
      { name = "EVENT"; dep = libevent; }
    ];
    disabled = luaOlder "5.1" || luaAtLeast "5.4";
    meta.broken = luaOlder "5.1" || luaAtLeast "5.4";
  });

  luaexpat = prev.luaexpat.overrideAttrs (_: {
@@ -514,8 +514,21 @@ with prev;
    '';
  });

  readline = prev.readline.overrideAttrs (oa: {
    propagatedBuildInputs = oa.propagatedBuildInputs ++ [ readline.out ];
  readline = final.callPackage({ buildLuarocksPackage, fetchurl, luaAtLeast, luaOlder, lua, luaposix }:
  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";
    };

    extraVariables = rec {
      READLINE_INCDIR = "${readline.dev}/include";
      HISTORY_INCDIR = READLINE_INCDIR;
@@ -524,9 +537,19 @@ with prev;
      unzip "$curSrc"
      tar xf *.tar.gz
    '';
    # Without this, source root is wrongly set to ./readline-2.6/doc
    sourceRoot = "readline-${lib.versions.majorMinor oa.version}";
  });

    disabled = (luaOlder "5.1") || (luaAtLeast "5.5");
    propagatedBuildInputs = [ lua luaposix
      readline.out
    ];

    meta = {
      homepage = "http://pjb.com.au/comp/lua/readline.html";
      description = "Interface to the readline library";
      license.fullName = "MIT/X11";
    };
  })) {};


  sqlite = prev.sqlite.overrideAttrs (drv: {