%global tzversion tzdata2012h Name: joda-time Version: 2.1 Release: %mkrel 2.%{tzversion}.2 Summary: Java date and time API Group: Development/Java License: ASL 2.0 URL: http://joda-time.sourceforge.net Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}-dist.tar.gz Source1: ftp://ftp.iana.org/tz/releases/%{tzversion}.tar.gz BuildArch: noarch BuildRequires: java-devel >= 1:1.6.0 BuildRequires: jpackage-utils BuildRequires: maven BuildRequires: joda-convert Requires: java >= 1:1.6.0 Requires: jpackage-utils Requires: joda-convert %description Joda-Time provides a quality replacement for the Java date and time classes. The design allows for multiple calendar systems, while still providing a simple API. The 'default' calendar is the ISO8601 standard which is used by XML. The Gregorian, Julian, Buddhist, Coptic, Ethiopic and Islamic systems are also included, and we welcome further additions. Supporting classes include time zone, duration, format and parsing. %package javadoc Summary: Javadoc for %{name} Group: Documentation Requires: jpackage-utils %description javadoc This package contains the API documentation for %{name}. %prep %setup -q -n %{name}-%{version} sed -i 's/\r//' LICENSE.txt sed -i 's/\r//' RELEASE-NOTES.txt sed -i 's/\r//' ToDo.txt # all java binaries must be removed from the sources find . -name '*.jar' -exec rm -f '{}' \; # replace internal tzdata rm -f src/main/java/org/joda/time/tz/src/* tar -xzf %{SOURCE1} -C src/main/java/org/joda/time/tz/src/ %build mvn-rpmbuild \ -Dmaven.test.failure.ignore=true \ install javadoc:javadoc %install # jars install -d -m 0755 %{buildroot}%{_javadir} install -pm 644 target/%{name}-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar # pom 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}/ %files %doc LICENSE.txt RELEASE-NOTES.txt ToDo.txt %{_javadir}/* %{_mavenpomdir}/* %{_mavendepmapfragdir}/* %files javadoc %doc LICENSE.txt %{_javadocdir}/%{name} %changelog * Sat Jan 12 2013 umeabot <umeabot> 2.1-2.tzdata2012h.2.mga3 + Revision: 355513 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Mon Dec 03 2012 dmorgan <dmorgan> 2.1-2.tzdata2012h.1.mga3 + Revision: 325924 - New version - Build with maven - Adapt to new guidelines - Fix copying SOURCE2 - Fix copying SOURCE2 + gil <gil> - add toolchains.xml maven-toolchains-plugin cfg file - add maven-toolchains-plugin support, removed patch0 * Thu Apr 28 2011 dmorgan <dmorgan> 1.6.2-5.tzdata2011f.2.mga1 + Revision: 92543 - Rebuild after bootstrapping - imported package joda-time