gup: simplify build expression

+18 -30
-16
pkgs/development/tools/build-managers/gup/build.nix
··· 1 - # NOTE: this file is copied from the upstream repository for this package. 2 - # Please submit any changes you make here to https://github.com/timbertson/gup/ 3 - 4 - { stdenv, lib, python, which, pychecker ? null }: 5 - { src, version, meta ? {} }: 6 - stdenv.mkDerivation { 7 - inherit src meta; 8 - name = "gup-${version}"; 9 - buildInputs = lib.remove null [ python which pychecker ]; 10 - SKIP_PYCHECKER = pychecker == null; 11 - buildPhase = "make python"; 12 - installPhase = '' 13 - mkdir $out 14 - cp -r python/bin $out/bin 15 - ''; 16 - }
+18 -14
pkgs/development/tools/build-managers/gup/default.nix
··· 1 - { stdenv, fetchFromGitHub, lib, python, which }: 2 - let 1 + { stdenv, fetchFromGitHub, lib, python, which, pychecker ? null }: 2 + stdenv.mkDerivation rec { 3 3 version = "0.7.0"; 4 4 src = fetchFromGitHub { 5 5 sha256 = "1pwnmlq2pgkkln9sgz4wlb9dqlqw83bkf105qljnlvggc21zm3pv"; ··· 7 7 repo = "gup"; 8 8 owner = "timbertson"; 9 9 }; 10 - in 11 - import ./build.nix 12 - { inherit stdenv lib python which; } 13 - { inherit src version; 14 - meta = { 15 - inherit (src.meta) homepage; 16 - description = "A better make, inspired by djb's redo"; 17 - license = stdenv.lib.licenses.lgpl2Plus; 18 - maintainers = [ stdenv.lib.maintainers.timbertson ]; 19 - platforms = stdenv.lib.platforms.all; 20 - }; 21 - } 10 + name = "gup-${version}"; 11 + buildInputs = lib.remove null [ python which pychecker ]; 12 + SKIP_PYCHECKER = pychecker == null; 13 + buildPhase = "make python"; 14 + installPhase = '' 15 + mkdir $out 16 + cp -r python/bin $out/bin 17 + ''; 18 + meta = { 19 + inherit (src.meta) homepage; 20 + description = "A better make, inspired by djb's redo"; 21 + license = stdenv.lib.licenses.lgpl2Plus; 22 + maintainers = [ stdenv.lib.maintainers.timbertson ]; 23 + platforms = stdenv.lib.platforms.all; 24 + }; 25 + }