# Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit java-pkg #S=${WORKDIR}/${P} S=${WORKDIR}/${P}-src DESCRIPTION="EL is the JSP 2.0 Expression Language Interpreter from Apache." HOMEPAGE="http://jakarta.apache.org/commons/el.html" SRC_URI="http://apache.rmplc.co.uk/dist/jakarta/commons/el/source/${P}-src.tar.gz" LICENSE="Apache-1.1" SLOT= KEYWORDS="~x86" IUSE="jikes doc" DEPEND=">=virtual/jdk-1.4 >=dev-java/servletapi-2.4" RDEPEND=">=virtual/jdk-1.4" src_unpack() { unpack "${P}-src.tar.gz" cd "${S}" mv build.properties build.properties.old # Anyone want to make this pipeline nicer by making it one sed regex be my guest echo "servlet-api.jar=`java-config --classpath=servletapi | sed s/:/"\n"/ | cat | line`" >> build.properties echo "jsp-api.jar=`java-config --classpath=servletapi | sed s/:/"\n"/ | tac | line`" >> build.properties einfo "servlet-api.jar found at `java-config --classpath=servletapi | sed s/:/"\n"/ | cat | line`" einfo "jsp-api.jar found at `java-config --classpath=servletapi | sed s/:/"\n"/ | tac | line`" echo "junit.jar = `java-config --classpath=junit`" >> build.properties echo "servletapi.build.notrequired = true" >> build.properties echo "jspapi.build.notrequired = true" >> build.properties #At present we need this patch to fix two bugs #Bug 1 is that the build tries to get ../LICENSE instead on ./LICENSE.txt #Bug 2 is that javadoc compilation is b0rked so it needs to be avoided epatch ${FILESDIR}/commons-el-1.0-Fix-build.patch } src_compile() { local buildopts if [ -n "`use jikes`" ] ; then buildopts="${buildopts} -Dbuild.compiler=jikes" fi ANT_OPTS=${buildopts} ant dist } src_install () { cd dist java-pkg_dojar ${PN}.jar || die "Unable to install" dodoc LICENSE.txt RELEASE-NOTES.txt dohtml STATUS.html PROPOSAL.html use doc && einfo "This build cant produce any additional documents at present as the javadoc task is broken" }