Name: tiger-types Version: 1.4 Release: 1%{?dist} Summary: Type arithmetic library for Java5 Group: Development/Libraries License: CDDL or GPLv2 with exceptions Url: http://java.net/projects/tiger-types # svn export https://svn.java.net/svn/tiger-types~svn/tags/tiger-types-1.4 # tar czf tiger-types-1.4-src-svn.tar.gz tiger-types-1.4 Source0: %{name}-%{version}-src-svn.tar.gz # wget -O glassfish-LICENSE.txt https://svn.java.net/svn/glassfish~svn/tags/legal-1.1/src/main/resources/META-INF/LICENSE.txt # tiger-types package don't include the license file Source1: glassfish-LICENSE.txt BuildRequires: java-devel BuildRequires: jpackage-utils BuildRequires: jvnet-parent BuildRequires: junit BuildRequires: maven-local BuildRequires: maven-compiler-plugin BuildRequires: maven-enforcer-plugin BuildRequires: maven-jar-plugin BuildRequires: maven-javadoc-plugin BuildRequires: maven-resources-plugin BuildRequires: maven-surefire-plugin BuildRequires: maven-surefire-provider-junit4 Requires: jvnet-parent Requires: java Requires: jpackage-utils BuildArch: noarch %description Tiger-types is a type arithmetic library for Java5. %package javadoc Group: Documentation Summary: Javadoc for %{name} %description javadoc This package contains javadoc for %{name}. %prep %setup -q # add OSGi support required by glassfish hk2 %pom_add_plugin org.apache.felix:maven-bundle-plugin . ' *;scope=provided;inline=true org.jvnet.tiger_types.* true osgi-bundle package bundle ' # removed some warning %pom_xpath_inject "pom:build/pom:plugins/pom:plugin[pom:artifactId ='maven-compiler-plugin']" "org.apache.maven.plugins2.5.1" %pom_xpath_inject "pom:reporting/pom:plugins/pom:plugin[pom:artifactId ='maven-javadoc-plugin']" "org.apache.maven.plugins2.9" # Unneeded %pom_remove_plugin :maven-idea-plugin %pom_remove_plugin :maven-release-plugin cp -p %{SOURCE1} LICENSE.txt sed -i 's/\r//' LICENSE.txt %build mvn-rpmbuild package javadoc:aggregate %install mkdir -p %{buildroot}%{_javadir} install -m 644 target/%{name}-%{version}.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 -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name} %files %{_javadir}/%{name}.jar %{_mavenpomdir}/JPP-%{name}.pom %{_mavendepmapfragdir}/%{name} %doc LICENSE.txt %files javadoc %{_javadocdir}/%{name} %doc LICENSE.txt %changelog * Sat Aug 25 2012 gil cattaneo 1.4-1 - initial rpm