about summary refs log tree commit diff
path: root/pkgs/development/tools/misc/luarocks
diff options
context:
space:
mode:
authorMichael Raskin <7c6f434c@mail.ru>2019-03-06 11:53:25 +0100
committerMichael Raskin <7c6f434c@mail.ru>2019-03-06 11:54:21 +0100
commit73a82dcc44800dfbd205031b61ff8bbb3720e421 (patch)
tree74d3a25526f828041f38f9897dd96d3f847843e2 /pkgs/development/tools/misc/luarocks
parent51174e7b7b464519f65cd878c0c668b4325fb2d1 (diff)
downloadnixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar.gz
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar.bz2
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar.lz
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar.xz
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.tar.zst
nixlib-73a82dcc44800dfbd205031b61ff8bbb3720e421.zip
luarocks: switch to a less intrusive update-walker metadata style
Diffstat (limited to 'pkgs/development/tools/misc/luarocks')
-rw-r--r--pkgs/development/tools/misc/luarocks/default.nix30
1 files changed, 14 insertions, 16 deletions
diff --git a/pkgs/development/tools/misc/luarocks/default.nix b/pkgs/development/tools/misc/luarocks/default.nix
index ad50e7e8e6df..3bbee6ee5e40 100644
--- a/pkgs/development/tools/misc/luarocks/default.nix
+++ b/pkgs/development/tools/misc/luarocks/default.nix
@@ -8,26 +8,17 @@
 }:
 
 let
-  s = # Generated upstream information
-  rec {
-    baseName="luarocks";
-    version="2.4.4";
-    name="${baseName}-${version}";
-    hash="0d7rl60dwh52qh5pfsphgx5ypp7k190h9ri6qpr2yx9kvqrxyf1r";
-    url="http://luarocks.org/releases/luarocks-2.4.4.tar.gz";
-    sha256="0d7rl60dwh52qh5pfsphgx5ypp7k190h9ri6qpr2yx9kvqrxyf1r";
-  };
-  buildInputs = [
-    lua curl makeWrapper which unzip
-  ];
 in
 
-stdenv.mkDerivation {
-  inherit (s) name version;
-  inherit buildInputs;
+stdenv.mkDerivation rec {
+  pname="luarocks";
+  version="2.4.4";
+
   src = fetchurl {
-    inherit (s) url sha256;
+    url="http://luarocks.org/releases/luarocks-${version}.tar.gz";
+    sha256="0d7rl60dwh52qh5pfsphgx5ypp7k190h9ri6qpr2yx9kvqrxyf1r";
   };
+
   patches = [ ./darwin.patch ];
   preConfigure = ''
     lua -e "" || {
@@ -41,6 +32,11 @@ stdenv.mkDerivation {
         configureFlags="$configureFlags --with-lua-include=$lua_inc"
     fi
   '';
+
+  buildInputs = [
+    lua curl makeWrapper which
+  ];
+
   postInstall = ''
     sed -e "1s@.*@#! ${lua}/bin/lua$LUA_SUFFIX@" -i "$out"/bin/*
     for i in "$out"/bin/*; do
@@ -73,5 +69,7 @@ stdenv.mkDerivation {
     license = licenses.mit ;
     maintainers = with maintainers; [raskin teto];
     platforms = platforms.linux ++ platforms.darwin;
+    downloadPage = "http://luarocks.org/releases/";
+    updateWalker = true;
   };
 }