Build with xmvn
This commit is contained in:
parent
c6b8423059
commit
6a6c14152e
@ -1,96 +1,62 @@
|
||||
%global base_name compress
|
||||
%global short_name commons-%{base_name}
|
||||
|
||||
Name: apache-%{short_name}
|
||||
Version: 1.4.1
|
||||
Release: 2%{?dist}
|
||||
Summary: Java API for working with tar, zip and bzip2 files
|
||||
Group: Development/Libraries
|
||||
License: ASL 2.0
|
||||
URL: http://commons.apache.org/%{base_name}/
|
||||
Source0: http://www.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
||||
BuildArch: noarch
|
||||
Name: apache-%{short_name}
|
||||
Version: 1.4.1
|
||||
Release: 3%{?dist}
|
||||
Summary: Java API for working with compressed files and archivers
|
||||
Group: Development/Libraries
|
||||
License: ASL 2.0
|
||||
URL: http://commons.apache.org/%{base_name}/
|
||||
Source0: http://archive.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: java-devel >= 1:1.6.0
|
||||
BuildRequires: jpackage-utils
|
||||
BuildRequires: apache-commons-parent
|
||||
BuildRequires: junit4
|
||||
BuildRequires: maven-surefire-provider-junit4
|
||||
BuildRequires: xz-java
|
||||
Requires: java >= 1:1.6.0
|
||||
Requires: jpackage-utils
|
||||
Requires: xz-java
|
||||
Requires(post): jpackage-utils
|
||||
Requires(postun): jpackage-utils
|
||||
BuildRequires: xmvn >= 0.2.1
|
||||
BuildRequires: javapackages-tools >= 0.10.0
|
||||
BuildRequires: apache-commons-parent
|
||||
BuildRequires: maven-surefire-provider-junit
|
||||
BuildRequires: xz-java
|
||||
|
||||
# Upstream name change
|
||||
Provides: jakarta-%{short_name} = %{version}-%{release}
|
||||
Obsoletes: jakarta-%{short_name} < 1.0-2
|
||||
Provides: jakarta-%{short_name} = %{version}-%{release}
|
||||
Obsoletes: jakarta-%{short_name} < 1.0-2
|
||||
|
||||
%description
|
||||
The code in this component came from Avalon's Excalibur, but originally
|
||||
from Ant, as far as life in Apache goes. The tar package is originally
|
||||
Tim Endres' public domain package. The bzip2 package is based on the
|
||||
work done by Keiron Liddle. It has migrated via:
|
||||
Ant -> Avalon-Excalibur -> Commons-IO -> Commons-Compress.
|
||||
The Apache Commons Compress library defines an API for working with
|
||||
ar, cpio, Unix dump, tar, zip, gzip, XZ, Pack200 and bzip2 files.
|
||||
|
||||
|
||||
%package javadoc
|
||||
Summary: Javadocs for %{name}
|
||||
Summary: API documentation for %{name}
|
||||
Group: Documentation
|
||||
Requires: jpackage-utils
|
||||
|
||||
# Upstream name change
|
||||
Provides: jakarta-%{short_name}-javadoc = %{version}-%{release}
|
||||
Obsoletes: jakarta-%{short_name}-javadoc < 1.0-2
|
||||
Provides: jakarta-%{short_name}-javadoc = %{version}-%{release}
|
||||
Obsoletes: jakarta-%{short_name}-javadoc < 1.0-2
|
||||
|
||||
%description javadoc
|
||||
This package contains the API documentation for %{name}.
|
||||
This package provides %{summary}.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{short_name}-%{version}-src
|
||||
|
||||
%build
|
||||
mvn-rpmbuild install javadoc:aggregate
|
||||
%mvn_file : %{short_name} %{name}
|
||||
%mvn_alias : commons:
|
||||
%mvn_build
|
||||
|
||||
%install
|
||||
# jars
|
||||
install -d -m 0755 %{buildroot}%{_javadir}
|
||||
install -m 644 target/%{short_name}-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar
|
||||
ln -sf %{name}.jar %{buildroot}%{_javadir}/%{short_name}.jar
|
||||
%mvn_install
|
||||
|
||||
# poms
|
||||
install -d -m 0755 %{buildroot}%{_mavenpomdir}
|
||||
install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{short_name}.pom
|
||||
%add_to_maven_depmap org.apache.commons %{short_name} %{version} JPP %{short_name}
|
||||
|
||||
# javadoc
|
||||
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}
|
||||
cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
|
||||
|
||||
|
||||
%post
|
||||
%update_maven_depmap
|
||||
|
||||
|
||||
%postun
|
||||
%update_maven_depmap
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%files -f .mfiles
|
||||
%doc LICENSE.txt NOTICE.txt
|
||||
%{_javadir}/*
|
||||
%{_mavenpomdir}/JPP-%{short_name}.pom
|
||||
%{_mavendepmapfragdir}/*
|
||||
|
||||
%files javadoc
|
||||
%defattr(-,root,root,-)
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%doc LICENSE.txt NOTICE.txt
|
||||
%doc %{_javadocdir}/%{name}
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Jan 8 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.4.1-3
|
||||
- Build with xmvn
|
||||
- Update to current packaging guidelines
|
||||
|
||||
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user