Blob Blame History Raw
Name:           apache-mime4j
Version:        0.6.1
Release:        2%{?dist}
Summary:        Apache JAMES Mime4j

Group:          Development/Libraries
License:        ASL 2.0
URL:            http://james.apache.org/mime4j
Source0:        http://apache.skknet.net//james/mime4j/apache-mime4j-0.6.1-src.tar.gz
BuildArch: noarch

BuildRequires: apache-commons-logging
BuildRequires: log4j
BuildRequires: junit
BuildRequires: apache-commons-io
BuildRequires: apache-james-project
BuildRequires: javacc-maven-plugin
Requires: apache-commons-logging
Requires: log4j
Requires: apache-commons-io

%description
Java stream based MIME message parser

%package javadoc
Group:          Documentation
Summary:        Javadoc for %{name}
Requires:       jpackage-utils

%description javadoc
API documentation for %{name}.


%prep
%setup -q 
rm -fr stage

%build
mvn-rpmbuild install 

%install
# jars
install -d -m 0755 %{buildroot}%{_javadir}
install -m 644 target/%{name}-%{version}.jar   %{buildroot}%{_javadir}/%{name}.jar

# poms
install -d -m 755 %{buildroot}%{_mavenpomdir}
install -pm 644 pom.xml \
    %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom

%add_maven_depmap JPP-%{name}.pom %{name}.jar

# javadoc
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}
cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}/
rm -rf target/site/api*

%files
%doc LICENSE.txt NOTICE.txt RELEASE_NOTES.txt
%{_javadir}/*
%{_mavenpomdir}/*
%{_mavendepmapfragdir}/*

%files javadoc
%doc LICENSE.txt
%{_javadocdir}/%{name}

%changelog
* Wed Nov 30 2011 Alexander Kurtakov <akurtako@redhat.com> 0.6.1-2
- Adapt to current guidelines.

* Wed Feb 23 2011 Alexander Kurtakov <akurtako@redhat.com> 0.6.1-1
- Initial package.