Name: beanio Version: 2.0.6 Release: 1%{?dist} Summary: Java library for marshalling and unmarshalling bean objects Group: Development/Libraries License: ASL 2.0 URL: http://www.beanio.org/ Source0: http://beanio.googlecode.com/files/%{name}-%{version}.zip # disable jarjar and maven-ant-tasks support # disable objectweb-asm4 embedded copy # use system libraries # add aqute-bnd wrap task, for OSGi manifest Patch0: %{name}-2.0.6-build.patch # add objectweb-asm4 as deps Patch1: %{name}-2.0.2-pom.patch BuildRequires: java-devel BuildRequires: java-javadoc BuildRequires: ant BuildRequires: aqute-bnd # main deps BuildRequires: objectweb-asm4 # test deps # BuildRequires: emma BuildRequires: junit Requires: objectweb-asm4 Requires: java BuildArch: noarch %description BeanIO is an open source Java framework for marshalling and unmarshalling Java beans, or plain old java objects (POJO's), from a large flat file, stream, or simple String object. BeanIO is configured using an XML mapping file, and currently supports XML, CSV, delimited, and fixed length file formats. %package javadoc Group: Documentation Summary: Javadoc for %{name} %description javadoc This package contains javadoc for %{name}. %prep %setup -q # cleanup find . -name "*.class" -delete find . -name "*.jar" -delete rm -r docs/* %patch0 -p0 %patch1 -p0 # require unavailable and old springframework libraies # package org.springframework.batch.item rm -r {src,test}/org/beanio/spring # java 7 temp fix ^ sed -i "s|private void print(String indent) {|protected void print(String indent) {|" \ src/org/beanio/internal/util/TreeNode.java sed -i 's/\r//' LICENSE.txt NOTICE.txt %build ant package test-junit %install mkdir -p %{buildroot}%{_javadir} install -m 644 %{name}.jar %{buildroot}%{_javadir}/%{name}.jar mkdir -p %{buildroot}%{_mavenpomdir} install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom %add_maven_depmap mkdir -p %{buildroot}%{_javadocdir}/%{name} cp -pr target/docs/api/* %{buildroot}%{_javadocdir}/%{name} %files %{_javadir}/%{name}.jar %{_mavenpomdir}/JPP-%{name}.pom %{_mavendepmapfragdir}/%{name} %doc LICENSE.txt NOTICE.txt %files javadoc %{_javadocdir}/%{name} %doc LICENSE.txt NOTICE.txt %changelog * Sat May 25 2013 gil cattaneo 2.0.6-1 - 2.0.6 * Mon Oct 15 2012 gil cattaneo 2.0.2-1 - initial rpm