Version bump.
authorKrzysztof Pawlik <nelchael@gentoo.org>
Tue, 26 Dec 2006 01:49:46 +0000 (01:49 +0000)
committerKrzysztof Pawlik <nelchael@gentoo.org>
Tue, 26 Dec 2006 01:49:46 +0000 (01:49 +0000)
Package-Manager: portage-2.1.2_rc4-r1

www-servers/resin/ChangeLog
www-servers/resin/Manifest
www-servers/resin/files/3.1.0/resin-3.1.0-gentoo.patch [new file with mode: 0644]
www-servers/resin/files/3.1.0/resin.conf [new file with mode: 0644]
www-servers/resin/files/3.1.0/resin.init [new file with mode: 0644]
www-servers/resin/files/digest-resin-3.1.0 [new file with mode: 0644]
www-servers/resin/resin-3.1.0.ebuild [new file with mode: 0644]

index 10d7d311ffebd81412c69f87dafe7e38387cd5d1..88b22a83f23f872dd674b9975de302eb569e43f3 100644 (file)
@@ -1,6 +1,13 @@
 # ChangeLog for www-servers/resin
 # Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/www-servers/resin/ChangeLog,v 1.30 2006/11/24 21:52:37 nelchael Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-servers/resin/ChangeLog,v 1.31 2006/12/26 01:49:46 nelchael Exp $
+
+*resin-3.1.0 (26 Dec 2006)
+
+  26 Dec 2006; Krzysiek Pawlik <nelchael@gentoo.org>
+  +files/3.1.0/resin.conf, +files/3.1.0/resin-3.1.0-gentoo.patch,
+  +files/3.1.0/resin.init, +resin-3.1.0.ebuild:
+  Version bump.
 
   24 Nov 2006; Krzysiek Pawlik <nelchael@gentoo.org> -files/3.0.8/21resin,
   -files/3.0.8/resin.conf, -files/3.0.8/resin.init,
index f0ce6b2134b4f919b7788ca7416228de1cda8b8d..26ce0ec3bf6c6654f02e6f654f979d78d36e0a2e 100644 (file)
@@ -41,9 +41,22 @@ AUX 3.0.22/resin.init 817 RMD160 c65d1c0260163242631cae4b4536aac4b923c2d7 SHA1 e
 MD5 cfe5d87efbe6b8cafbe3581d72816d6d files/3.0.22/resin.init 817
 RMD160 c65d1c0260163242631cae4b4536aac4b923c2d7 files/3.0.22/resin.init 817
 SHA256 a4309f92c7b46b3adc717baaecc97aa80ffd4562d6f27d757cdfdac2ee49852e files/3.0.22/resin.init 817
+AUX 3.1.0/resin-3.1.0-gentoo.patch 6340 RMD160 a7945c5edff0c041e3fbcaab0a2125265086a813 SHA1 d7899a942369ffd6ebe29b94e69b8848fa944c46 SHA256 fb7daf247ed4866c5767b8173a26053f24ad69d453b8e4b82a6766b10a6b451f
+MD5 8cb00aa0c25e3db7e92d39afc6f46da5 files/3.1.0/resin-3.1.0-gentoo.patch 6340
+RMD160 a7945c5edff0c041e3fbcaab0a2125265086a813 files/3.1.0/resin-3.1.0-gentoo.patch 6340
+SHA256 fb7daf247ed4866c5767b8173a26053f24ad69d453b8e4b82a6766b10a6b451f files/3.1.0/resin-3.1.0-gentoo.patch 6340
+AUX 3.1.0/resin.conf 505 RMD160 569fdef0de2b9c7ad1ff4cec453591bc2643ca57 SHA1 2b0f2ba1edf8f438d28515c52ce69a3150b8420c SHA256 63a038b93fb41ab869f0a749539b2ab50c2935da7bcdd32696defc8cc48c78d6
+MD5 9aed30c2989de54d9d83ef4788145f7f files/3.1.0/resin.conf 505
+RMD160 569fdef0de2b9c7ad1ff4cec453591bc2643ca57 files/3.1.0/resin.conf 505
+SHA256 63a038b93fb41ab869f0a749539b2ab50c2935da7bcdd32696defc8cc48c78d6 files/3.1.0/resin.conf 505
+AUX 3.1.0/resin.init 746 RMD160 4972b125fa1fbee350cc6da598c96cfb98511bd2 SHA1 d598aab72ab840df0b736aadb830100efd9b15a7 SHA256 374b30a11f214ea77191fbe762742833d97413c3d7096142f6c4899162d7bbbf
+MD5 3969abd9f16123e9934a1938cc551db7 files/3.1.0/resin.init 746
+RMD160 4972b125fa1fbee350cc6da598c96cfb98511bd2 files/3.1.0/resin.init 746
+SHA256 374b30a11f214ea77191fbe762742833d97413c3d7096142f6c4899162d7bbbf files/3.1.0/resin.init 746
 DIST resin-2.1.17.tar.gz 3239401 RMD160 5fcf2e7680bfad1531cf75d384dcd8f15c19f639 SHA1 2d45e885874122931e63d7c59baed50a75f60618 SHA256 70c681d45f34b1992fbdfb2024970c52a6be20b8cd23855903630e1476a89b92
 DIST resin-3.0.21-src.tar.gz 5401440 RMD160 1f4d90a28aa772a4dc14259816325285ffea1957 SHA1 00a928d470f69f39c1fac511356b6d368ade54e5 SHA256 c9de627433fbe3ec940507fd604a4a2409e70a16342994ffab881a51f8db1055
 DIST resin-3.0.22-src.tar.gz 5467522 RMD160 093cdcfa8bcd14a30ff54cc9cb8001ace10bbfc6 SHA1 23d4f2fd233033adb0b08f8fcdcb81a1f0aab3fe SHA256 0da5617b6867a0d40e59d2dfe2518158567506fea2c1273d56290c146a64849a
+DIST resin-3.1.0-src.tar.gz 5708227 RMD160 6e347dc2810b328eddeafb39886bfe146c65f409 SHA1 2f3f7c5d6003424f2f1afc27f38f9f36cc312466 SHA256 735af3cd4ed9962631969d2da4ddea26ab28c3d0fd96d0e831e5a2058ef77440
 EBUILD resin-2.1.17.ebuild 2977 RMD160 1a2aa63fa6d79e1e34cfaf4803993b3f513188a0 SHA1 eea21775ba7c4dc99ee471b18a0a3114108f739f SHA256 6b9e63e50e6c1658e2fe614a4c76f9ce64e8dc5fbbc4a431c050383a5342c009
 MD5 69eaf963bc4fe22b3a0dbcd58d545771 resin-2.1.17.ebuild 2977
 RMD160 1a2aa63fa6d79e1e34cfaf4803993b3f513188a0 resin-2.1.17.ebuild 2977
@@ -56,10 +69,14 @@ EBUILD resin-3.0.22.ebuild 3640 RMD160 61d992563c06ec48a1afffe455d64a21b9b6d9f9
 MD5 6ae67018be5d40d7e647f388235dbea7 resin-3.0.22.ebuild 3640
 RMD160 61d992563c06ec48a1afffe455d64a21b9b6d9f9 resin-3.0.22.ebuild 3640
 SHA256 a3cdf5098c7e80649c7b711efa0ce3909579224d488bae0b4ef2c85409aecfa1 resin-3.0.22.ebuild 3640
-MISC ChangeLog 7125 RMD160 de168a78fae2f3d22a6fb2ca0a5a344e9fc5168b SHA1 30aa90876ed0cef2ec24f1550b9cf7385668962a SHA256 ae7c1d444ac5c9378c758b9b657e33097b6ada1bcd9bc4da06f268435f0c262f
-MD5 f4fdfa2c666b3c904c9541924ad9a68e ChangeLog 7125
-RMD160 de168a78fae2f3d22a6fb2ca0a5a344e9fc5168b ChangeLog 7125
-SHA256 ae7c1d444ac5c9378c758b9b657e33097b6ada1bcd9bc4da06f268435f0c262f ChangeLog 7125
+EBUILD resin-3.1.0.ebuild 3419 RMD160 fd2b1b315a453d856fcbbed7dfb9c1aa2861e86b SHA1 f992e1399345a0784f85be66d362d5be01c5ab11 SHA256 5ba8f8651adb8fe8f054f5b469b2e38dfa2010eca8db94cc4d3d42c3823c3e0a
+MD5 4777e3ed6fde6990f9898a60b2d1fd80 resin-3.1.0.ebuild 3419
+RMD160 fd2b1b315a453d856fcbbed7dfb9c1aa2861e86b resin-3.1.0.ebuild 3419
+SHA256 5ba8f8651adb8fe8f054f5b469b2e38dfa2010eca8db94cc4d3d42c3823c3e0a resin-3.1.0.ebuild 3419
+MISC ChangeLog 7337 RMD160 df93bbac11fd43040a72f0efd02a03efff704589 SHA1 8fc92c4f028fdae16991309595622c08bf05d442 SHA256 cef8949138a83eff45d67c4fa7a440ad2b3beaa900fc12ab4040bdb0de53ed7a
+MD5 a185b0bc90fb9b7175819b1a36ae7ca5 ChangeLog 7337
+RMD160 df93bbac11fd43040a72f0efd02a03efff704589 ChangeLog 7337
+SHA256 cef8949138a83eff45d67c4fa7a440ad2b3beaa900fc12ab4040bdb0de53ed7a ChangeLog 7337
 MISC metadata.xml 229 RMD160 a9b4042458f9aae459c108c2917745af68bd1d45 SHA1 087c10f53259e3702a47b6c43c4365fd16d8c201 SHA256 79bb370ed491d8c5f4c42086fcbd3affc893943b56254f98b5a9c9f369792884
 MD5 2696a2548331ef205bf10abad6802180 metadata.xml 229
 RMD160 a9b4042458f9aae459c108c2917745af68bd1d45 metadata.xml 229
@@ -73,10 +90,13 @@ SHA256 a41462d28571aee053b0bb80907636bc065420f0422b8c3e6661ac5986f2f39d files/di
 MD5 1df6f758925c19f33df250705d01755e files/digest-resin-3.0.22 253
 RMD160 bd3fd0cce1c7cccefb0440cd6520d7d58f3625eb files/digest-resin-3.0.22 253
 SHA256 22df3f8469cc556d0c7f3e0238eb0a7bfc0ebf2f64fdf30fee739e286e1505cb files/digest-resin-3.0.22 253
+MD5 486b2f59227ff5e961aee6f6a7482362 files/digest-resin-3.1.0 250
+RMD160 29b90fa098e07020808bc9bb0156c404b6e012b3 files/digest-resin-3.1.0 250
+SHA256 8af0d2e1d33ccff5b8ef7c6cfc0097f92c557d9179a3c1145ea103f7c40a1171 files/digest-resin-3.1.0 250
 -----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.5 (GNU/Linux)
+Version: GnuPG v1.4.6 (GNU/Linux)
 
-iD8DBQFFZ2mwgo/w9rxVVVERAlKOAJ0dRuvRPztlQCkdjk2bncTJMIFCzwCeOMBH
-i2O1Ij1cPNm2CYfn0d7HcMg=
-=ETlx
+iD8DBQFFkH/jgo/w9rxVVVERAuKvAJ4sQy27BirF4zgfkMrfQCnpdr9/XgCcCKfM
+4caCPkrjGe8b+lRgxH2q5O8=
+=Uh60
 -----END PGP SIGNATURE-----
diff --git a/www-servers/resin/files/3.1.0/resin-3.1.0-gentoo.patch b/www-servers/resin/files/3.1.0/resin-3.1.0-gentoo.patch
new file mode 100644 (file)
index 0000000..0f55b63
--- /dev/null
@@ -0,0 +1,181 @@
+diff -Nru resin-3.1.0.vanilla/Makefile.in resin-3.1.0/Makefile.in
+--- resin-3.1.0.vanilla/Makefile.in    2006-12-26 01:39:34.000000000 +0100
++++ resin-3.1.0/Makefile.in    2006-12-26 01:40:38.000000000 +0100
+@@ -8,20 +8,20 @@
+ install       :
+       (cd modules/c/src; $(MAKE) install)
+-      if test $(PREFIX) != `pwd`; then \
+-        mkdir -p $(PREFIX)/lib; \
+-        mkdir -p $(PREFIX)/libexec; \
+-        cp -r libexec/* $(PREFIX)/libexec; \
+-        cp lib/*.jar $(PREFIX)/lib; \
+-        mkdir -p $(PREFIX)/bin; \
+-        cp bin/* $(PREFIX)/bin; \
+-        mkdir -p $(PREFIX)/webapps; \
+-        cp -r webapps/* $(PREFIX)/webapps; \
+-        mkdir -p $(PREFIX)/conf; \
+-        cp conf/resin.conf $(PREFIX)/conf/resin.conf.orig; \
+-        cp conf/app-default.xml $(PREFIX)/conf/app-default.xml.orig; \
+-        if test ! -r $(PREFIX)/conf/resin.conf; then \
+-          cp conf/resin.conf $(PREFIX)/conf/resin.conf; \
+-          cp conf/app-default.xml $(PREFIX)/conf/app-default.xml; \
++      if test $(DESTDIR)$(PREFIX) != `pwd`; then \
++        mkdir -p $(DESTDIR)$(PREFIX)/lib; \
++        mkdir -p $(DESTDIR)$(PREFIX)/libexec; \
++        cp -r libexec/* $(DESTDIR)$(PREFIX)/libexec; \
++        cp lib/*.jar $(DESTDIR)$(PREFIX)/lib; \
++        mkdir -p $(DESTDIR)$(PREFIX)/bin; \
++        cp bin/* $(DESTDIR)$(PREFIX)/bin; \
++        mkdir -p $(DESTDIR)$(PREFIX)/webapps; \
++        cp -r webapps/* $(DESTDIR)$(PREFIX)/webapps; \
++        mkdir -p $(DESTDIR)$(PREFIX)/conf; \
++        cp conf/resin.conf $(DESTDIR)$(PREFIX)/conf/resin.conf.orig; \
++        cp conf/app-default.xml $(DESTDIR)$(PREFIX)/conf/app-default.xml.orig; \
++        if test ! -r $(DESTDIR)$(PREFIX)/conf/resin.conf; then \
++          cp conf/resin.conf $(DESTDIR)$(PREFIX)/conf/resin.conf; \
++          cp conf/app-default.xml $(DESTDIR)$(PREFIX)/conf/app-default.xml; \
+         fi; \
+       fi
+diff -Nru resin-3.1.0.vanilla/build.xml resin-3.1.0/build.xml
+--- resin-3.1.0.vanilla/build.xml      2006-12-26 01:39:34.000000000 +0100
++++ resin-3.1.0/build.xml      2006-12-26 01:53:05.000000000 +0100
+@@ -7,7 +7,6 @@
+   <property name="modules" location="${basedir}/modules"/>
+   <property name="src" location="${basedir}/src"/>
+-  <property name="ext" location="${basedir}/modules/ext"/>
+   <property name="doc" location="${basedir}/doc"/>
+   <property name="build" location="${install}/build"/>
+@@ -17,14 +16,12 @@
+   <property name="javac.verbose" value="off"/>
+-  <property name="javac.debug" value="on"/>
++  <property name="javac.debug" value="off"/>
+   <property name="javac.optimize" value="off"/>
+   <property name="javac.deprecation" value="off"/>
+   <property name="javac.nowarn" value="on"/>
+   <property name="javac.memoryMaximumSize" value="256m"/>
+-  <property name="javac.source" value="1.5"/>
+-
+   <property name="jar.compress" value="false"/>
+   <!--
+   <property name="jar.index" value="true"/>
+@@ -66,14 +63,13 @@
+   </target>
+   <target name="compile" 
+-          depends="init, jaxrpc, ejb, jpa, j2ee-deploy, j2ee-management, jca, jms, jsdk, jstl, jta, portlet, script, resin-util, quercus, resin, ecmascript, webutil, deploy, conf, ext, jsf">
++          depends="init, jaxrpc, ejb, jpa, j2ee-deploy, j2ee-management, jca, jms, jsdk, jstl, jta, portlet, script, resin-util, quercus, resin, ecmascript, webutil, deploy, conf, jsf">
+   </target>
+   <target name="ant" depends="init">
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="ant"/>
+       <param name="module.jar" value="resin-ant.jar"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -81,7 +77,6 @@
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="ejb"/>
+       <param name="module.jar" value="ejb-15.jar"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -89,7 +84,6 @@
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="jpa"/>
+       <param name="module.jar" value="jpa-15.jar"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -111,7 +105,6 @@
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="jaxrpc"/>
+       <param name="module.jar" value="jaxrpc-15.jar"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -233,7 +226,6 @@
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="resin"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+   
+@@ -258,14 +250,12 @@
+   <target name="webutil" depends="init, resin">
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="webutil"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+   <target name="quercus-dev" depends="init">
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="quercus"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -274,7 +264,6 @@
+   <target name="ecmascript" depends="init">
+     <antcall target="module" inheritRefs="true">
+       <param name="module.name" value="ecmascript"/>
+-      <param name="javac.source" value="1.5"/>
+     </antcall>
+   </target>
+@@ -306,16 +295,15 @@
+            verbose="${javac.verbose}" 
+            debug="${javac.debug}" optimize="${javac.optimize}"
+            deprecation="${javac.deprecation}" nowarn="${javac.nowarn}"
+-           source="${javac.source}"
+            excludes="**/.svn/**"
+            memoryMaximumSize="${javac.memoryMaximumSize}">
+       <classpath>
+         <dirset dir="${modules}">
+           <include name="*/classes"/>
+        </dirset>
+-        <fileset dir="${ext}">
+-          <include name="**/*.jar"/>
+-        </fileset>
++       <fileset dir="lib/">
++           <include name="*.jar"/>
++       </fileset>
+       </classpath>
+     </javac>
+@@ -385,13 +373,6 @@
+     </copy>
+   </target>
+-  <target name="ext" depends="init, resin">
+-    <copy todir="${install}/lib" preservelastmodified="true">
+-      <fileset dir="${ext}">
+-      </fileset>
+-    </copy>
+-  </target>
+-
+   <target name="webapps" depends="init, doc, quercus">
+   </target>
+@@ -527,9 +508,6 @@
+           <dirset dir="${modules}">
+             <include name="*/classes"/>
+           </dirset>
+-          <fileset dir="${modules}/ext">
+-            <include name="**/*.jar"/>
+-          </fileset>
+         </classpath>
+       </java>
diff --git a/www-servers/resin/files/3.1.0/resin.conf b/www-servers/resin/files/3.1.0/resin.conf
new file mode 100644 (file)
index 0000000..b3c2182
--- /dev/null
@@ -0,0 +1,15 @@
+# JVM Runtime
+# Using the default setting, it will determine your JVM from the system-vm
+# set using java-config.
+# See java-config(1) manual page for assistance in determining this value.
+
+# You can override this value with whatever JDK 1.5 you want.
+# For a list of valid values for GENTOO_VM see output of
+#   java-config -L
+#GENTOO_VM=sun-jdk-1.5
+
+# Where your Resin is installed
+RESIN_HOME=/usr/lib/resin
+
+# The CLASSPATH for Resin to use, plus any others you need.
+CLASSPATH=$(java-config -p resin)
diff --git a/www-servers/resin/files/3.1.0/resin.init b/www-servers/resin/files/3.1.0/resin.init
new file mode 100644 (file)
index 0000000..ed7095e
--- /dev/null
@@ -0,0 +1,23 @@
+#!/sbin/runscript
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/www-servers/resin/files/3.1.0/resin.init,v 1.1 2006/12/26 01:49:46 nelchael Exp $
+
+depend() {
+       need net
+       use dns logger mysql postgresql
+}
+
+start()        {
+       export JAVA_HOME=$(java-config --select-vm=${GENTOO_VM} -O)
+       ebegin "Starting Resin"
+       su - resin -c "${JAVA_HOME}/bin/java -Dresin.home=${RESIN_HOME} -cp ${CLASSPATH} -jar /usr/share/resin/lib/resin.jar start"
+       eend $?
+}
+
+stop() {
+       export JAVA_HOME=$(java-config --select-vm=${GENTOO_VM} -O)
+       ebegin "Stopping Resin"
+       su - resin -c "${JAVA_HOME}/bin/java -Dresin.home=${RESIN_HOME} -jar /usr/share/resin/lib/resin.jar stop"
+       eend $?
+}
diff --git a/www-servers/resin/files/digest-resin-3.1.0 b/www-servers/resin/files/digest-resin-3.1.0
new file mode 100644 (file)
index 0000000..82f68ed
--- /dev/null
@@ -0,0 +1,3 @@
+MD5 bee26233a9bf67935c75fbb8136e9001 resin-3.1.0-src.tar.gz 5708227
+RMD160 6e347dc2810b328eddeafb39886bfe146c65f409 resin-3.1.0-src.tar.gz 5708227
+SHA256 735af3cd4ed9962631969d2da4ddea26ab28c3d0fd96d0e831e5a2058ef77440 resin-3.1.0-src.tar.gz 5708227
diff --git a/www-servers/resin/resin-3.1.0.ebuild b/www-servers/resin/resin-3.1.0.ebuild
new file mode 100644 (file)
index 0000000..4d12eb0
--- /dev/null
@@ -0,0 +1,151 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/www-servers/resin/resin-3.1.0.ebuild,v 1.1 2006/12/26 01:49:46 nelchael Exp $
+
+inherit java-pkg-2 java-ant-2 eutils flag-o-matic
+
+DESCRIPTION="A fast Servlet 2.5 and JSP 2.0 engine."
+HOMEPAGE="http://www.caucho.com"
+SRC_URI="http://www.caucho.com/download/${P}-src.tar.gz"
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="admin doc source"
+
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+
+RDEPEND="=virtual/jdk-1.5*
+       >=dev-java/iso-relax-20050331"
+DEPEND="${RDEPEND}
+       dev-java/aopalliance
+       >=dev-java/sun-javamail-1.4
+       >=dev-java/sun-jaf-1.1
+       dev-java/ant-core
+       dev-libs/openssl"
+
+RESIN_HOME="/usr/lib/resin"
+
+# Rewrites build.xml in documentation
+JAVA_PKG_BSFIX="off"
+
+src_unpack() {
+
+       unpack ${A}
+       epatch "${FILESDIR}/${PV}/${P}-gentoo.patch"
+
+       java-ant_bsfix_one "${S}/build.xml"
+
+}
+
+pkg_setup() {
+
+       enewgroup resin
+       enewuser resin -1 /bin/bash ${RESIN_HOME} resin
+
+}
+
+src_compile() {
+
+       append-flags -fPIC -DPIC
+
+       chmod 755 ${S}/configure
+       econf --prefix=${RESIN_HOME} || die "econf failed"
+
+       einfo "Building libraries..."
+       # Broken with -jn where n > 1
+       emake -j1 || die "emake failed"
+
+       mkdir ${S}/lib
+       cd ${S}/lib
+       java-pkg_jar-from sun-jaf
+       java-pkg_jar-from sun-javamail
+       java-pkg_jar-from iso-relax
+       java-pkg_jar-from aopalliance-1
+       ln -s $(java-config --jdk-home)/lib/tools.jar
+       cd ${S}
+
+       einfo "Building jars..."
+       eant || die "ant failed"
+
+       if use doc; then
+               einfo "Building docs..."
+               eant doc || die "ant doc failed"
+       fi
+
+}
+
+src_install() {
+
+       make DESTDIR=${D} install || die
+
+       dodir /etc/
+       mv ${D}/${RESIN_HOME}/conf ${D}/etc/resin
+       dosym /etc/resin ${RESIN_HOME}/conf
+
+       keepdir /var/log/resin
+       keepdir /var/log/resin
+       keepdir /var/run/resin
+
+       dosym /var/log/resin ${RESIN_HOME}/logs
+       dosym /var/log/resin ${RESIN_HOME}/log
+
+       dodoc README ${S}/conf/*.conf
+
+       newinitd ${FILESDIR}/${PV}/resin.init resin
+       newconfd ${FILESDIR}/${PV}/resin.conf resin
+
+       rm -f ${S}/lib/tools.jar
+       java-pkg_dojar ${S}/lib/*.jar
+       rm -fr ${D}/${RESIN_HOME}/lib
+       dosym /usr/share/resin/lib ${RESIN_HOME}/lib
+
+       dodir /var/lib/resin/webapps
+       mv ${D}/${RESIN_HOME}/webapps/* ${D}/var/lib/resin/webapps
+       rm -rf ${D}/${RESIN_HOME}/webapps
+       dosym /var/lib/resin/webapps ${RESIN_HOME}/webapps
+
+       dosym /etc/resin/resin.conf /etc/resin/resin.xml
+
+       use admin && {
+               cp -a ${S}/php ${D}/${RESIN_HOME}/ || die "cp failed"
+       }
+
+       use source && {
+               einfo "Zipping source..."
+               java-pkg_dosrc ${S}/modules/*/src/* 2> /dev/null
+       }
+
+       einfo "Removing unneeded files..."
+       rm -fr ${D}/${RESIN_HOME}/bin
+       rm -f ${D}/etc/resin/*.orig
+
+       einfo "Fixing permissions..."
+       chown -R resin:resin ${D}${RESIN_HOME}
+       chown -R resin:resin ${D}/etc/resin
+       chown -R resin:resin ${D}/var/log/resin
+       chown -R resin:resin ${D}/var/lib/resin
+       chown -R resin:resin ${D}/var/run/resin
+
+       chmod 755 ${D}${RESIN_HOME}/bin/*
+       chmod 644 ${D}/etc/conf.d/resin
+       chmod 755 ${D}/etc/init.d/resin
+       chmod 750 ${D}/var/lib/resin
+       chmod 750 ${D}/var/run/resin
+       chmod 750 ${D}/etc/resin
+
+}
+
+pkg_postinst() {
+
+       einfo
+       einfo " User and group 'resin' have been added."
+       einfo
+       einfo " By default, Resin runs on port 8080.  You can change this"
+       einfo " value by editing /etc/conf/resin.conf."
+       einfo
+       einfo " webapps directory was moved to /var/lib/resin/webapps"
+       einfo
+       einfo " Most options has been moved from /etc/conf.d/resin to"
+       einfo " /etc/resin/resin.conf."
+       einfo
+
+}