%global short_name commons-vfs2 Name: apache-%{short_name} Version: 2.0 Release: 1%{?dist} Summary: Provides a single API for accessing various different file systems Group: Development/Libraries License: ASL 2.0 URL: http://commons.apache.org/vfs/ Source0: http://www.apache.org/dist/commons/vfs/source/commons-vfs-%{version}-src.tar.gz # Update groupId and version of ant Patch0: apache-commons-vfs-versions.patch # We don't have jackrabbit-webday, so patch out webdav support Patch1: apache-commons-vfs-nowebdav.patch BuildArch: noarch BuildRequires: jpackage-utils BuildRequires: java-devel BuildRequires: maven BuildRequires: maven-compiler-plugin BuildRequires: maven-install-plugin BuildRequires: maven-jar-plugin BuildRequires: maven-javadoc-plugin BuildRequires: maven-release-plugin BuildRequires: maven-resources-plugin BuildRequires: maven-surefire-plugin BuildRequires: maven-surefire-provider-junit4 BuildRequires: apache-commons-parent BuildRequires: apache-commons-compress Requires: jpackage-utils Requires: java Requires: apache-commons-logging Requires: apache-commons-net Requires: jakarta-commons-httpclient %description Commons VFS provides a single API for accessing various different file systems. It presents a uniform view of the files from various different sources, such as the files on local disk, on an HTTP server, or inside a Zip archive. Some of the features of Commons VFS are: * A single consistent API for accessing files of different types. * Support for numerous file system types . * Caching of file information. Caches information in-JVM, and optionally can cache remote file information on the local file system. * Event delivery. * Support for logical file systems made up of files from various different file systems. * Utilities for integrating Commons VFS into applications, such as a VFS-aware ClassLoader and URLStreamHandlerFactory. * A set of VFS-enabled Ant tasks %package javadoc Summary: Javadocs for %{name} Group: Documentation Requires: jpackage-utils %description javadoc This package contains the API documentation for %{name}. %prep %setup -q -n commons-vfs-%{version} %patch0 -p1 -b .versions %patch1 -p1 -b .nowebdav find -name webdav | xargs rm -r %build mvn-rpmbuild install javadoc:aggregate %install mkdir -p $RPM_BUILD_ROOT%{_javadir} cp -p core/target/%{short_name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar ln -s %{name}.jar $RPM_BUILD_ROOT%{_javadir}/%{short_name}.jar mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name} cp -rp target/site/apidocs $RPM_BUILD_ROOT%{_javadocdir}/%{name} install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir} install -pm 644 core/pom.xml \ $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{short_name}.pom %add_maven_depmap JPP-%{short_name}.pom %{short_name}.jar %files %doc *.txt %{_mavenpomdir}/JPP-%{short_name}.pom %{_mavendepmapfragdir}/%{name} %{_javadir}/%{name}.jar %{_javadir}/%{short_name}.jar %files javadoc %doc LICENSE.txt %{_javadocdir}/%{name} %changelog * Tue Oct 11 2011 Orion Poplawski 2.0-1 - Update to 2.0 - Cleanup requires * Fri Jun 3 2011 Orion Poplawski 1.0-3 - Add license to javadoc package * Tue May 31 2011 Orion Poplawski 1.0-2 - Use pom.xml from upstream svn * Wed May 4 2011 Orion Poplawski 1.0-1 - Initial package