%define javahome /usr/lib/jvm/jdk-gcj Name: xmlunit Version: 1.6 Release: 1mamba Summary: XMLUnit for Java Group: Development/Tools Vendor: openmamba Distribution: openmamba Packager: Automatic Build System URL: http://xmlunit.sourceforge.net/ Source0: http://downloads.sourceforge.net/sourceforge/xmlunit/xmlunit-%{version}-src.zip #Source1: http://repo1.maven.org/maven2/xmlunit/xmlunit/%{version}/xmlunit-%{version}.pom Patch: xmlunit-1.3-docbook_xml.patch License: BSD BuildRequires: apache-ant BuildRequires: apache-ivy BuildRequires: java-gcj-compat BuildRequires: java-junit3 BuildRequires: jpackage-utils BuildRequires: xalan-j2 BuildRequires: xerces-j2 BuildRequires: xml-commons-apis BuildRequires: dblatex BuildRequires: docbook-xsl Requires: java-junit3 Requires: xalan-j2 Requires: xml-commons-apis BuildRoot: %{_tmppath}/%{name}-%{version}-root %description XMLUnit extends JUnit and NUnit to enable unit testing of XML. It compares a control XML document to a test document or the result of a transformation, validates documents, and compares the results of XPath expressions. %package javadoc Group: Documentation Summary: Javadoc for %{name} %description javadoc XMLUnit compares a control XML document to a test document or the result of a transformation, validates documents, and compares the results of XPath expressions. This package contains javadoc for %{name}. %package manual Group: Documentation Summary: Manual for %{name} %description manual XMLUnit compares a control XML document to a test document or the result of a transformation, validates documents, and compares the results of XPath expressions. This package contains documentation for %{name}. %prep %setup -q %patch0 -p0 for j in $(find . -name "*.jar"); do rm -rf $j done cat > build.properties << EOF junit.lib=$(build-classpath junit-3.8.2) xmlxsl.lib=$(build-classpath xalan-j2 xerces-j2 xml-commons-jaxp-1.3-apis) test.report.dir=test EOF # FIXME # users-guide-pdf: # [apply] Build the listings... # [apply] XSLT stylesheets DocBook - LaTeX 2e (0.2.10) # [apply] =================================================== # [apply] Processing Revision History # [apply] Build XMLUnit-Java.pdf # [apply] Error: cannot import name TexModule # [apply] Result: 1 cp userguide/XMLUnit-Java.pdf src/user-guide/ sed -i 's/\r//g' README.txt KEYS LICENSE.txt %build export JAVA_HOME=%javahome export CLASSPATH=$(build-classpath junit-3.8.2 xalan-j2 xerces-j2 xalan-j2-serialize \ xml-commons-jaxp-1.3-apis ant/ant-junit ant/ant-trax ant/ant-stylebook) ant -Dbuild.compiler=modern jar docs javadocs %install [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" mkdir -p %{buildroot}%{_javadir} mkdir -p %{buildroot}%{_datadir}/maven2/poms install -m 0644 build/lib/xmlunit-%{version}.jar \ %{buildroot}%{_javadir}/ %add_to_maven_depmap xmlunit xmlunit %{version} JPP xmlunit install -m 644 build/lib/xmlunit-%{version}.pom %{buildroot}%{_datadir}/maven2/poms/JPP-xmlunit.pom ( cd %{buildroot}%{_javadir} for jar in *-%{version}.jar; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"` done ) mkdir -p %{buildroot}%{_javadocdir}/xmlunit-%{version} cp -pr build/doc/api/* %{buildroot}%{_javadocdir}/xmlunit-%{version} ln -s xmlunit-%{version} %{buildroot}%{_javadocdir}/xmlunit rm -rf build/doc/api sed -i "s|api/index.html|%{_javadocdir}/xmlunit-%{version}/index.html|" build/doc/index.html #%{_bindir}/aot-compile-rpm %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %post %update_maven_depmap %postun %update_maven_depmap %files %defattr(-,root,root) %{_javadir}/xmlunit-%{version}.jar %{_javadir}/xmlunit.jar %{_datadir}/maven2/poms %{_mavendepmapfragdir} %doc KEYS LICENSE.txt README.txt %files javadoc %defattr(-,root,root) %{_javadocdir}/xmlunit-%{version} %{_javadocdir}/xmlunit %files manual %defattr(-,root,root) %doc build/doc/userguide %changelog * Thu Jan 29 2015 Automatic Build System 1.6-1mamba - automatic update by autodist * Fri Sep 20 2013 Automatic Build System 1.5-1mamba - automatic update by autodist * Sat Feb 09 2013 Automatic Build System 1.4-1mamba - automatic version update by autodist * Thu Mar 24 2011 gil 1.3-3mamba - rebuilt with java-gcj-compat support * Sat Jan 08 2011 gil 1.3-2mamba - rebuilt devel * Sat Jan 02 2010 gil 1.3-1mamba - update to 1.3 * Mon Jun 29 2009 gil 1.2-2mamba - add maven 2 pom * Wed Mar 04 2009 gil 1.2-1mamba - package created by autospec