diff options
author | Thomas Sachau <tommy@gentoo.org> | 2009-02-02 21:25:58 +0000 |
---|---|---|
committer | Thomas Sachau <tommy@gentoo.org> | 2009-02-02 21:25:58 +0000 |
commit | 8d94deea2a8b81ef13fd87bfc6c8d19e92860a6b (patch) | |
tree | d56e86d7b18a2a6a4bf2a3cb499d75f6299dafc9 /net-p2p | |
parent | Bump to 0.11.8. Translation updates. (diff) | |
download | gentoo-2-8d94deea2a8b81ef13fd87bfc6c8d19e92860a6b.tar.gz gentoo-2-8d94deea2a8b81ef13fd87bfc6c8d19e92860a6b.tar.bz2 gentoo-2-8d94deea2a8b81ef13fd87bfc6c8d19e92860a6b.zip |
Initial commit. Fixes bug 128783
(Portage version: 2.2_rc23/cvs/Linux x86_64)
Diffstat (limited to 'net-p2p')
-rw-r--r-- | net-p2p/freenet/ChangeLog | 11 | ||||
-rw-r--r-- | net-p2p/freenet/files/ext.patch | 67 | ||||
-rw-r--r-- | net-p2p/freenet/files/freenet | 18 | ||||
-rw-r--r-- | net-p2p/freenet/files/freenet.old | 18 | ||||
-rw-r--r-- | net-p2p/freenet/files/wrapper1.conf | 60 | ||||
-rw-r--r-- | net-p2p/freenet/freenet-0.7_p1204-r1.ebuild | 82 | ||||
-rw-r--r-- | net-p2p/freenet/metadata.xml | 13 |
7 files changed, 269 insertions, 0 deletions
diff --git a/net-p2p/freenet/ChangeLog b/net-p2p/freenet/ChangeLog new file mode 100644 index 000000000000..dabf657d2dad --- /dev/null +++ b/net-p2p/freenet/ChangeLog @@ -0,0 +1,11 @@ +# ChangeLog for net-p2p/freenet +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-p2p/freenet/ChangeLog,v 1.48 2009/02/02 21:25:58 tommy Exp $ + +*freenet-0.7_p1204-r1 (02 Feb 2009) + + 02 Feb 2009; Thomas Sachau (Tommy[D]) <tommy@gentoo.org> +files/ext.patch, + +files/freenet, +files/freenet.old, +files/wrapper1.conf, + +freenet-0.7_p1204-r1.ebuild: + Initial commit. Fixes bug 128783 + diff --git a/net-p2p/freenet/files/ext.patch b/net-p2p/freenet/files/ext.patch new file mode 100644 index 000000000000..a98e7f846bcb --- /dev/null +++ b/net-p2p/freenet/files/ext.patch @@ -0,0 +1,67 @@ +diff -ur freenet-old/build.xml freenet/build.xml +--- freenet/build.xml 2009-02-01 15:23:22.000000000 +0100 ++++ freenet/build.xml.new 2009-02-01 15:24:16.000000000 +0100 +@@ -53,19 +53,9 @@ + </exec> + </target> + +- <target name="get-extjar" depends="env" unless="freenet-ext.present" +- description="Download some external libraries which Freenet relies on"> +- <mkdir dir="${lib}"/> +- <get src="http://downloads.freenetproject.org/alpha/freenet-ext.jar" +- dest="${freenet-ext.location}" +- verbose="true" +- usetimestamp="true"/> +- <property name="freenet-ext.present" value="true"/> +- </target> +- + <!-- ================================================== --> + +- <target name="compile" depends="get-extjar, generate-CSSTokenizerFilter"> ++ <target name="compile" depends="generate-CSSTokenizerFilter"> + <!-- Create the time stamp --> + <tstamp/> + +diff -ur freenet-old/src/freenet/node/NodeStarter.java freenet/src/freenet/node/NodeStarter.java +--- freenet-old/src/freenet/node/NodeStarter.java 2008-10-28 21:40:50.000000000 +0100 ++++ freenet/src/freenet/node/NodeStarter.java 2008-10-28 21:39:14.000000000 +0100 +@@ -162,37 +162,8 @@ + } + + private void getExtBuild() { +- try { +- extBuildNumber = ExtVersion.buildNumber; +- extRevisionNumber = ExtVersion.cvsRevision; +- String builtWithMessage = "freenet.jar built with freenet-ext.jar Build #" + extBuildNumber + " r" + extRevisionNumber; +- Logger.normal(this, builtWithMessage); +- System.out.println(builtWithMessage); +- extBuildNumber = ExtVersion.buildNumber(); +- if(extBuildNumber == -42) { +- extBuildNumber = ExtVersion.extBuildNumber(); +- extRevisionNumber = ExtVersion.extRevisionNumber(); +- } +- if(extBuildNumber == 0) { +- String buildMessage = "extBuildNumber is 0; perhaps your freenet-ext.jar file is corrupted?"; +- Logger.error(this, buildMessage); +- System.err.println(buildMessage); +- extBuildNumber = -1; +- } +- if(extRevisionNumber == null) { +- String revisionMessage = "extRevisionNumber is null; perhaps your freenet-ext.jar file is corrupted?"; +- Logger.error(this, revisionMessage); +- System.err.println(revisionMessage); +- extRevisionNumber = "INVALID"; +- } +- } catch(Throwable t) { +- // Compatibility code ... will be removed +- Logger.error(this, "Unable to get the version of your freenet-ext file : it's probably corrupted!"); +- System.err.println("Unable to get the version of your freenet-ext file : it's probably corrupted!"); +- System.err.println(t.getMessage()); +- extRevisionNumber = "INVALID"; +- extBuildNumber = -1; +- } ++ extRevisionNumber = ""; ++ extBuildNumber = RECOMMENDED_EXT_BUILD_NUMBER; + } + + /** diff --git a/net-p2p/freenet/files/freenet b/net-p2p/freenet/files/freenet new file mode 100644 index 000000000000..f276ee4ea0f4 --- /dev/null +++ b/net-p2p/freenet/files/freenet @@ -0,0 +1,18 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +start() { + start-stop-daemon --start --chuid freenet --exec /bin/sh /var/freenet/run.sh start 2>/dev/null + eend 0 +} + +status() { + start-stop-daemon --start --chuid freenet --exec /bin/sh /var/freenet/run.sh status 2>/dev/null + eend 0 +} + +stop() { + start-stop-daemon --start --chuid freenet --exec /bin/sh /var/freenet/run.sh stop 2>/dev/null + eend 0 +} diff --git a/net-p2p/freenet/files/freenet.old b/net-p2p/freenet/files/freenet.old new file mode 100644 index 000000000000..d0df97e471ba --- /dev/null +++ b/net-p2p/freenet/files/freenet.old @@ -0,0 +1,18 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +start() { + start-stop-daemon --start --chuid freenet --exec /var/freenet/run.sh start 2>/dev/null + eend 0 +} + +status() { + start-stop-daemon --start --chuid freenet --exec /var/freenet/run.sh status 2>/dev/null + eend 0 +} + +stop() { + start-stop-daemon --start --chuid freenet --exec /var/freenet/run.sh stop 2>/dev/null + eend 0 +} diff --git a/net-p2p/freenet/files/wrapper1.conf b/net-p2p/freenet/files/wrapper1.conf new file mode 100644 index 000000000000..2e505757fc88 --- /dev/null +++ b/net-p2p/freenet/files/wrapper1.conf @@ -0,0 +1,60 @@ +wrapper.java.command=java +wrapper.working.dir=/var/freenet/ +wrapper.java.mainclass=freenet.node.NodeStarter +wrapper.java.classpath.1=/usr/share/freenet/lib/freenet.jar +wrapper.java.classpath.2=/usr/share/java-service-wrapper/lib/wrapper.jar +wrapper.java.classpath.3=/usr/share/db-je-3.3/lib/je.jar +wrapper.java.classpath.4=/usr/share/fec/lib/fec.jar +wrapper.java.classpath.5=/usr/share/ant-core/lib/ant.jar +wrapper.java.classpath.6=/usr/share/lzma/lib/lzma.jar +wrapper.java.classpath.7=/usr/share/lzmajio/lib/lzmajio.jar +wrapper.java.classpath.8=/usr/share/mersennetwister/lib/mersennetwister.jar +wrapper.java.classpath.9=/usr/share/db4o-jdk5/lib/db4o-jdk5.jar +wrapper.java.classpath.10=/usr/share/db4o-jdk12/lib/db4o-jdk12.jar +wrapper.java.classpath.11=/usr/share/db4o-jdk11/lib/db4o-jdk11.jar +wrapper.java.library.path.1=/usr/lib +wrapper.java.initmemory=60 +wrapper.java.maxmemory=128 +wrapper.java.additional.1=-Dnetworkaddress.cache.ttl=0 +wrapper.java.additional.2=-Dnetworkaddress.cache.negative.ttl=0 +wrapper.java.additional.3=-enableassertions:freenet +# You might want to set the following line if you have changed java.maxmemory +wrapper.java.additional.4=-XX:MaxPermSize=256M + +wrapper.app.parameter.1=freenet.ini +wrapper.console.format=PM +wrapper.console.loglevel=INFO +wrapper.logfile=wrapper.log +wrapper.logfile.format=LPTM +wrapper.logfile.loglevel=INFO +wrapper.logfile.maxsize=2M +wrapper.logfile.maxfiles=3 +wrapper.syslog.loglevel=NONE +wrapper.console.title=Freenet 0.7 +wrapper.jvm_exit.timeout=120 +wrapper.restart.reload_configuration=TRUE +wrapper.filter.trigger.1=java.lang.OutOfMemoryError +wrapper.filter.action.1=RESTART + +# Name of the service +wrapper.ntservice.name=freenet-darknet + +# Display name of the service +wrapper.ntservice.displayname=Freenet 0.7 darknet + +# Description of the service +wrapper.ntservice.description=The Free Network Project daemon + +# Service dependencies. Add dependencies as needed starting from 1 +wrapper.ntservice.dependency.1= + +# Mode in which the service is installed. AUTO_START or DEMAND_START +wrapper.ntservice.starttype=AUTO_START + +# Allow the service to interact with the desktop. +wrapper.ntservice.interactive=false + +wrapper.ntservice.process_priority=BELOW_NORMAL + +# Start services with a different user than SYSTEM +# SEE http://wrapper.tanukisoftware.org/doc/english/prop-ntservice-account.html BEFORE PROCEEDING ! diff --git a/net-p2p/freenet/freenet-0.7_p1204-r1.ebuild b/net-p2p/freenet/freenet-0.7_p1204-r1.ebuild new file mode 100644 index 000000000000..6e4773d4ce45 --- /dev/null +++ b/net-p2p/freenet/freenet-0.7_p1204-r1.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-p2p/freenet/freenet-0.7_p1204-r1.ebuild,v 1.1 2009/02/02 21:25:58 tommy Exp $ + +EAPI=1 +inherit eutils java-pkg-2 java-ant-2 multilib + +DESCRIPTION="An encrypted network without censorship" +HOMEPAGE="http://www.freenetproject.org/" +SRC_URI="mirror://gentoo/${P}.tar.bz2" + +LICENSE="as-is GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="freemail" + +CDEPEND="dev-db/db-je:3.3 + dev-java/fec + dev-java/java-service-wrapper + dev-java/db4o-jdk11 + dev-java/db4o-jdk12 + dev-java/db4o-jdk5 + dev-java/ant-core + dev-java/lzma + dev-java/lzmajio + dev-java/mersennetwister" +DEPEND=">=virtual/jdk-1.5 + ${CDEPEND}" +RDEPEND=">=virtual/jre-1.5 + net-libs/nativebiginteger + ${CDEPEND}" +PDEPEND="net-libs/NativeThread + freemail? ( dev-java/bcprov )" +S=${WORKDIR}/${PN} + +EANT_BUILD_TARGET="dist" +EANT_GENTOO_CLASSPATH="ant-core db4o-jdk5 db4o-jdk12 db4o-jdk11 db-je-3.3 fec java-service-wrapper lzma lzmajio mersennetwister" + +pkg_setup() { + java-pkg-2_pkg_setup + enewgroup freenet + enewuser freenet -1 -1 /var/freenet freenet +} + +src_unpack() { + unpack ${A} + cd "${S}" + cp "${FILESDIR}"/wrapper1.conf freenet-wrapper.conf || die + epatch "${FILESDIR}"/ext.patch + sed -i -e "s:=/usr/lib:=/usr/$(get_libdir):g" freenet-wrapper.conf || die "sed failed" + use freemail && echo "wrapper.java.classpath.12=/usr/share/bcprov/lib/bcprov.jar" >> freenet-wrapper.conf + java-ant_rewrite-classpath +} + +src_install() { + java-pkg_newjar lib/freenet-cvs-snapshot.jar ${PN}.jar + if has_version =sys-apps/baselayout-2*; then + doinitd "${FILESDIR}"/freenet + else + newinitd "${FILESDIR}"/freenet.old freenet + fi + dodoc AUTHORS README || die + insinto /etc + doins freenet-wrapper.conf || die + insinto /var/freenet + doins seednodes.fref run.sh || die + fperms +x /var/freenet/run.sh + dosym java-service-wrapper/libwrapper.so /usr/$(get_libdir)/libwrapper.so +} + +pkg_postinst () { + elog "1. Start freenet with /etc/init.d/freenet start." + elog "2. Open localhost:8888 in your browser for the web interface." +} + +pkg_postrm() { + if [ -z has_version ]; then + elog "If you dont want to use freenet any more" + elog "and dont want to keep your identity/other stuff" + elog "remember to do 'rm -rf /var/freenet' to remove everything" + fi +} diff --git a/net-p2p/freenet/metadata.xml b/net-p2p/freenet/metadata.xml new file mode 100644 index 000000000000..7e1dc8cae26c --- /dev/null +++ b/net-p2p/freenet/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer> + <email>tommy@gentoo.org</email> + <name>Thomas Sachau (Tommy[D])</name> + </maintainer> + <herd>net-p2p</herd> + <use> + <flag name='freemail'>Add Freemail support</flag> + </use> +</pkgmetadata> + |