# Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI="4" JAVA_PKG_IUSE="doc source test" WANT_ANT_TASKS="ant-nodeps" inherit java-pkg-2 java-ant-2 MY_PV=${PV//./_} MY_P=${PN}-${MY_PV} DESCRIPTION="The XML Security project is aimed at providing implementation of security standards for XML." HOMEPAGE="http://santuario.apache.org/" #SRC_URI="http://xml.apache.org/security/dist/java-library/xml-security-src-${MY_PV}.zip" SRC_URI="http://archive.apache.org/dist/santuario/java-library/${MY_PV}/${PN}-src-${MY_PV}.zip" LICENSE="Apache-2.0" SLOT="1.5" KEYWORDS="~amd64" IUSE="doc examples" CDEPEND="dev-java/commons-logging dev-java/xalan" #jdk-1.6 already contains javax.security.xml.* RDEPEND=">=virtual/jre-1.6 ${CDEPEND}" DEPEND="${RDEPEND} >=virtual/jdk-1.6 app-arch/unzip test? ( dev-java/junit:4 ) ${CDEPEND}" S="${WORKDIR}/${MY_P}" JAVA_ANT_REWRITE_CLASSPATH="yes" EANT_GENTOO_CLASSPATH="commons-logging,xalan" EANT_TEST_GENTOO_CLASSPATH="${EANT_GENTOO_CLASSPATH},junit-4" EANT_DOC_TARGET="build.docs" java_prepare() { #jdk-1.6 already contains javax.security.xml.* rm -rv src/main/java/javax epatch "${FILESDIR}"/${P}-build.xml.patch } src_test() { #Caused by: java.security.InvalidKeyException: Illegal key size or default parameters rm -v src/test/java/org/apache/xml/security/test/encryption/{BaltimoreEncTest,XMLCipherTest}.java ANT_TASKS="ant-junit" java-pkg-2_src_test } src_install() { java-pkg_newjar build/xmlsec-${PV}.jar use source && java-pkg_dosrc src/main/java/org use examples && java-pkg_doexamples samples/ dodoc NOTICE use doc && java-pkg_dohtml -r build/docs/html/javadoc }