From b1332dca0fd9fed96b5273e495c2d4350bfde89a Mon Sep 17 00:00:00 2001 From: Rob Vermaas Date: Tue, 19 Oct 2010 13:43:29 +0000 Subject: svn path=/nixpkgs/trunk/; revision=24366 --- pkgs/build-support/release/ant-build.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs/build-support') diff --git a/pkgs/build-support/release/ant-build.nix b/pkgs/build-support/release/ant-build.nix index e761205f663f..4c8d5fbac75e 100644 --- a/pkgs/build-support/release/ant-build.nix +++ b/pkgs/build-support/release/ant-build.nix @@ -10,7 +10,7 @@ , ... } @ args: let - antFlags = "-f ${buildfile} " + stdenv.lib.concatMapStrings ({name, value}: "-D${name}=${value}" ) antProperties ; + antFlags = "-f ${buildfile} " + stdenv.lib.concatMapStrings ({name, value}: "-D${name}=${value} " ) antProperties ; in stdenv.mkDerivation ( -- cgit 1.4.1 From 5a7fa1d061fc6bf4abbb89a15a70a7c819167526 Mon Sep 17 00:00:00 2001 From: Rob Vermaas Date: Wed, 20 Oct 2010 08:23:52 +0000 Subject: antBuild: minor changes svn path=/nixpkgs/trunk/; revision=24376 --- pkgs/build-support/release/ant-build.nix | 10 ++++++++-- pkgs/build-support/release/default.nix | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'pkgs/build-support') diff --git a/pkgs/build-support/release/ant-build.nix b/pkgs/build-support/release/ant-build.nix index 4c8d5fbac75e..f6882de54d0a 100644 --- a/pkgs/build-support/release/ant-build.nix +++ b/pkgs/build-support/release/ant-build.nix @@ -1,5 +1,6 @@ { src -, stdenv +, pkgs +, stdenv ? pkgs.stdenv , name , antTargets ? [] , jars ? [] @@ -7,6 +8,9 @@ , antProperties ? [] , antBuildInputs ? [] , buildfile ? "build.xml" +, ant ? pkgs.ant +, jre ? pkgs.jre +, hydraAntLogger ? pkgs.hydraAntLogger , ... } @ args: let @@ -79,11 +83,13 @@ stdenv.mkDerivation ( ''; } - // removeAttrs args ["antProperties"] // + // removeAttrs args ["antProperties" "buildInputs" "pkgs"] // { name = name + (if src ? version then "-" + src.version else ""); + buildInputs = [ant jre] ++ stdenv.lib.optional (args ? buildInputs) args.buildInputs ; + postHook = '' ensureDir $out/nix-support echo "$system" > $out/nix-support/system diff --git a/pkgs/build-support/release/default.nix b/pkgs/build-support/release/default.nix index b7a362aa9f92..2cf2b1f8d6d9 100644 --- a/pkgs/build-support/release/default.nix +++ b/pkgs/build-support/release/default.nix @@ -15,7 +15,7 @@ rec { } // args); antBuild = args: import ./ant-build.nix ( - { inherit stdenv; + { inherit pkgs; } // args); mvnBuild = args: import ./maven-build.nix ( -- cgit 1.4.1 From 0df15241ca861e1abb366191759f548c20644898 Mon Sep 17 00:00:00 2001 From: Rob Vermaas Date: Wed, 20 Oct 2010 12:30:03 +0000 Subject: fixes to ant-build svn path=/nixpkgs/trunk/; revision=24383 --- pkgs/build-support/release/ant-build.nix | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'pkgs/build-support') diff --git a/pkgs/build-support/release/ant-build.nix b/pkgs/build-support/release/ant-build.nix index f6882de54d0a..779841aec6ac 100644 --- a/pkgs/build-support/release/ant-build.nix +++ b/pkgs/build-support/release/ant-build.nix @@ -15,10 +15,12 @@ let antFlags = "-f ${buildfile} " + stdenv.lib.concatMapStrings ({name, value}: "-D${name}=${value} " ) antProperties ; + lib = stdenv.lib; in stdenv.mkDerivation ( { + inherit jre ant; showBuildStats = true; postPhases = @@ -48,14 +50,18 @@ stdenv.mkDerivation ( done ''; - generateWrappersPhase = '' + generateWrappersPhase = + let + cp = w: "-cp ${lib.optionalString (w ? classPath) w.classPath}${lib.optionalString (w ? mainClass) ":$out/lib/java/${w.jar}"}"; + in + '' header "Generating jar wrappers" '' + (stdenv.lib.concatMapStrings (w: '' cat >> $out/bin/${w.name} <