From 4bfde8f5b47895af68823fc8600d230813f4473d Mon Sep 17 00:00:00 2001 From: Willi Butz Date: Mon, 20 Mar 2017 22:09:59 +0100 Subject: [PATCH] martyr: fixed build, removed build.sh, added meta (see #23253) --- pkgs/development/libraries/martyr/builder.sh | 7 ------ pkgs/development/libraries/martyr/default.nix | 25 ++++++++++++++----- 2 files changed, 19 insertions(+), 13 deletions(-) delete mode 100644 pkgs/development/libraries/martyr/builder.sh diff --git a/pkgs/development/libraries/martyr/builder.sh b/pkgs/development/libraries/martyr/builder.sh deleted file mode 100644 index 3ee7fc012d97..000000000000 --- a/pkgs/development/libraries/martyr/builder.sh +++ /dev/null @@ -1,7 +0,0 @@ -source $stdenv/setup - -mkdir -p $out -unpackPhase -cd $name -$apacheAnt/bin/ant -cp -R ./* $out diff --git a/pkgs/development/libraries/martyr/default.nix b/pkgs/development/libraries/martyr/default.nix index 7fbd44b3fa4a..3b6102715391 100644 --- a/pkgs/development/libraries/martyr/default.nix +++ b/pkgs/development/libraries/martyr/default.nix @@ -1,11 +1,24 @@ -{stdenv, fetchurl, apacheAnt}: +{stdenv, fetchurl, ant, jdk}: -stdenv.mkDerivation { - name = "martyr-0.3.9"; - builder = ./builder.sh; +stdenv.mkDerivation rec { + name = "martyr-${version}"; + version = "0.3.9"; src = fetchurl { - url = "mirror://sourceforge/martyr/martyr-0.3.9.tar.gz"; + url = "mirror://sourceforge/martyr/${name}.tar.gz"; sha256 = "1ks8j413bcby345kmq1i7av8kwjvz5vxdn1zpv0p7ywxq54i4z59"; }; - inherit stdenv apacheAnt; + + buildInputs = [ ant jdk ]; + + buildPhase = "ant"; + + installPhase = '' + mkdir -p "$out/share/java" + cp -v *.jar "$out/share/java" + ''; + + meta = { + description = "Martyr is a Java framework around the IRC protocol to allow application writers easy manipulation of the protocol and client state"; + homepage = http://martyr.sourceforge.net/; + }; }