From 55ce36faee4a6a2eba7bd07196d424f37266b83c Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 29 Feb 2012 14:35:34 +0000 Subject: [PATCH] * Updated Leiningen to 1.7.0 (contributed by Phil Hagelberg; added a call to patchShebangs to fix the reference to /bin/bash). svn path=/nixpkgs/trunk/; revision=32698 --- .../tools/build-managers/leiningen/builder.sh | 2 ++ .../tools/build-managers/leiningen/default.nix | 13 ++++++------- .../tools/build-managers/leiningen/lein.patch | 16 ++++++---------- 3 files changed, 14 insertions(+), 17 deletions(-) diff --git a/pkgs/development/tools/build-managers/leiningen/builder.sh b/pkgs/development/tools/build-managers/leiningen/builder.sh index 65d318c8f1e..2ee86d86d77 100644 --- a/pkgs/development/tools/build-managers/leiningen/builder.sh +++ b/pkgs/development/tools/build-managers/leiningen/builder.sh @@ -15,6 +15,8 @@ cp -v $clojuresrc $out/lib patch --verbose $out_bin -p0 < $patches chmod -v 755 $out_bin +patchShebangs $out + echo "Testing out \"lein version\"..." $out_bin version echo "Success." diff --git a/pkgs/development/tools/build-managers/leiningen/default.nix b/pkgs/development/tools/build-managers/leiningen/default.nix index 61a0374bdad..efdb578a61b 100644 --- a/pkgs/development/tools/build-managers/leiningen/default.nix +++ b/pkgs/development/tools/build-managers/leiningen/default.nix @@ -2,17 +2,17 @@ stdenv.mkDerivation rec { pname = "leiningen"; - version = "1.6.2"; + version = "1.7.0"; name = "${pname}-${version}"; src = fetchurl { - url = "https://raw.github.com/technomancy/leiningen/stable/bin/lein-pkg"; - sha256 = "e177a493ed0c4a7874f1391d5cc72cc1e541e55ed3d6e075feec87b5da6f8277"; + url = "https://raw.github.com/technomancy/leiningen/1.7.0/bin/lein-pkg"; + sha256 = "1339f6ffc7bae3171174fc9eae990f5b9710ff2804038e931d531632c57f189c"; }; jarsrc = fetchurl { - url = "https://github.com/downloads/technomancy/leiningen/leiningen-1.6.2-standalone.jar"; - sha256 = "e35272556ece82d9a6a54b86266626da1b5f990ff556639dd7dd1025d6ed4226"; + url = "https://github.com/downloads/technomancy/leiningen/leiningen-1.7.0-standalone.jar"; + sha256 = "501eaa1c2a19ca4ffc2fde1776552cb513d69ee874abb547c40cee92156e50bf"; }; clojuresrc = fetchurl { @@ -30,7 +30,6 @@ stdenv.mkDerivation rec { homepage = https://github.com/technomancy/leiningen; description = "Project automation for Clojure"; license = "EPL"; - platforms = stdenv.lib.platforms.unix; }; -} \ No newline at end of file +} diff --git a/pkgs/development/tools/build-managers/leiningen/lein.patch b/pkgs/development/tools/build-managers/leiningen/lein.patch index 1a7157568e4..2edf1370ff4 100644 --- a/pkgs/development/tools/build-managers/leiningen/lein.patch +++ b/pkgs/development/tools/build-managers/leiningen/lein.patch @@ -1,15 +1,14 @@ ---- lein-pkg 2012-01-09 20:47:44.000000000 -0800 -+++ lein-pkg-nix 2012-01-09 20:45:01.000000000 -0800 -@@ -70,7 +70,7 @@ +--- lein-pkg 2012-02-28 15:26:40.000000000 -0800 ++++ lein-pkg-nix 2012-02-28 17:17:02.000000000 -0800 +@@ -71,30 +71,14 @@ LEIN_PLUGIN_PATH="$(echo "$DEV_PLUGINS" | tr \\n :)" LEIN_USER_PLUGIN_PATH="$(echo "$(unique_user_plugins)" | tr \\n :)" CLASSPATH="$CLASSPATH:$LEIN_PLUGIN_PATH:$LEIN_USER_PLUGIN_PATH:test/:src/:resources/" -CLOJURE_JAR="/usr/share/java/clojure-1.2.jar:/usr/share/java/asm3.jar:/usr/share/java/asm3-commons.jar" +CLOJURE_JAR="$(dirname $0)/../lib/*clojure-1.2.1.jar" - NULL_DEVICE=/dev/null # apply context specific CLASSPATH entries -@@ -78,23 +78,7 @@ + if [ -f .lein-classpath ]; then CLASSPATH="`cat .lein-classpath`:$CLASSPATH" fi @@ -26,11 +25,8 @@ - -# Do not use installed leiningen jar during self-compilation -if ! { [ "$1" = "compile" ] && -- grep -qsE 'defproject leiningen[[:space:]]+"[[:digit:].]+"' \ -- project.clj ;}; then +- grep -qsE 'defproject leiningen[[:space:]]+"[[:digit:].]+"' \ +- project.clj ;}; then - CLASSPATH="$CLASSPATH":/usr/share/java/leiningen-$LEIN_VERSION.jar -fi +CLASSPATH="$CLASSPATH:$(dirname $0)/../lib/*" - - if [ $DEBUG ]; then - echo $CLASSPATH