i2p: 0.9.41 -> 0.9.42

This commit is contained in:
Сухарик 2019-08-28 20:01:35 +03:00
parent 47391ab53b
commit 7f2b73d948
1 changed files with 17 additions and 8 deletions

View File

@ -1,13 +1,16 @@
{ stdenv, ps, coreutils, fetchurl, jdk, jre, ant, gettext, which }: { stdenv, ps, coreutils, fetchurl, jdk, jre, ant, gettext, which }:
let wrapper = stdenv.mkDerivation rec { let wrapper = stdenv.mkDerivation rec {
name = "wrapper-${version}"; pname = "wrapper";
version = "3.5.35"; version = "3.5.35";
src = fetchurl { src = fetchurl {
url = "https://wrapper.tanukisoftware.com/download/${version}/wrapper_${version}_src.tar.gz"; url = "https://wrapper.tanukisoftware.com/download/${version}/wrapper_${version}_src.tar.gz";
sha256 = "0mjyw9ays9v6lnj21pmfd3qdvd9b6rwxfmw3pg6z0kyf2jadixw2"; sha256 = "0mjyw9ays9v6lnj21pmfd3qdvd9b6rwxfmw3pg6z0kyf2jadixw2";
}; };
buildInputs = [ jdk ]; buildInputs = [ jdk ];
buildPhase = '' buildPhase = ''
export ANT_HOME=${ant} export ANT_HOME=${ant}
export JAVA_HOME=${jdk}/lib/openjdk/jre/ export JAVA_HOME=${jdk}/lib/openjdk/jre/
@ -16,6 +19,7 @@ let wrapper = stdenv.mkDerivation rec {
sed 's/ testsuite$//' -i src/c/Makefile-linux-x86-64.make sed 's/ testsuite$//' -i src/c/Makefile-linux-x86-64.make
${if stdenv.isi686 then "./build32.sh" else "./build64.sh"} ${if stdenv.isi686 then "./build32.sh" else "./build64.sh"}
''; '';
installPhase = '' installPhase = ''
mkdir -p $out/{bin,lib} mkdir -p $out/{bin,lib}
cp bin/wrapper $out/bin/wrapper cp bin/wrapper $out/bin/wrapper
@ -27,17 +31,22 @@ let wrapper = stdenv.mkDerivation rec {
in in
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "i2p-0.9.41"; pname = "i2p";
version = "0.9.42";
src = fetchurl { src = fetchurl {
url = "https://github.com/i2p/i2p.i2p/archive/${name}.tar.gz"; url = "https://download.i2p2.de/releases/${version}/i2psource_${version}.tar.bz2";
sha256 = "0adrj56i3pcc9ainj22akjrrvy73carz5jk29qa1h2b9q03di73b"; sha256 = "04y71hzkdpjzbac569rhyg1zfx37j0alggbl9gnkaqfbprb2nj1h";
}; };
buildInputs = [ jdk ant gettext which ]; buildInputs = [ jdk ant gettext which ];
patches = [ ./i2p.patch ]; patches = [ ./i2p.patch ];
buildPhase = '' buildPhase = ''
export JAVA_TOOL_OPTIONS="-Dfile.encoding=UTF8" export JAVA_TOOL_OPTIONS="-Dfile.encoding=UTF8"
ant preppkg-linux-only ant preppkg-linux-only
''; '';
installPhase = '' installPhase = ''
set -B set -B
mkdir -p $out/{bin,share} mkdir -p $out/{bin,share}
@ -61,13 +70,13 @@ stdenv.mkDerivation rec {
mv $out/man $out/share/ mv $out/man $out/share/
chmod +x $out/bin/* $out/i2psvc chmod +x $out/bin/* $out/i2psvc
rm $out/{osid,postinstall.sh,INSTALL-headless.txt} rm $out/{osid,postinstall.sh,INSTALL-headless.txt}
''; '';
meta = with stdenv.lib; { meta = with stdenv.lib; {
homepage = https://geti2p.net;
description = "Applications and router for I2P, anonymity over the Internet"; description = "Applications and router for I2P, anonymity over the Internet";
maintainers = [ maintainers.joelmo ]; homepage = "https://geti2p.net";
license = licenses.gpl2; license = licenses.gpl2;
platforms = [ "x86_64-linux" "i686-linux" ]; platforms = [ "x86_64-linux" "i686-linux" ];
maintainers = [ maintainers.joelmo ];
}; };
} }