Update to current packaging guidelines
This commit is contained in:
parent
4229894859
commit
3c0c49d2ef
@ -1,38 +1,30 @@
|
||||
%if 0%{?fedora} > 19 || 0%{?rhel} > 6
|
||||
%global headless -headless
|
||||
%endif
|
||||
|
||||
Name: xml-commons-resolver
|
||||
Version: 1.2
|
||||
Release: 21%{?dist}
|
||||
Epoch: 0
|
||||
Version: 1.2
|
||||
Release: 22%{?dist}
|
||||
Summary: Resolver subproject of xml-commons
|
||||
License: ASL 2.0
|
||||
URL: http://xerces.apache.org/xml-commons/components/resolver/
|
||||
BuildArch: noarch
|
||||
|
||||
Source0: http://www.apache.org/dist/xerces/xml-commons/%{name}-%{version}.tar.gz
|
||||
Source5: %{name}-pom.xml
|
||||
Source6: %{name}-resolver.1
|
||||
Source7: %{name}-xparse.1
|
||||
Source8: %{name}-xread.1
|
||||
|
||||
Patch0: %{name}-1.2-crosslink.patch
|
||||
Patch1: %{name}-1.2-osgi.patch
|
||||
|
||||
Requires: java%{?headless} >= 1:1.6.0
|
||||
Requires: jpackage-utils
|
||||
BuildRequires: java-devel >= 1:1.6.0
|
||||
BuildRequires: javapackages-local
|
||||
BuildRequires: ant
|
||||
BuildRequires: jpackage-utils
|
||||
Group: Development/Libraries
|
||||
BuildArch: noarch
|
||||
BuildRequires: apache-parent
|
||||
|
||||
%description
|
||||
Resolver subproject of xml-commons.
|
||||
|
||||
%package javadoc
|
||||
Summary: Javadoc for %{name}
|
||||
Group: Documentation
|
||||
BuildRequires: java-javadoc
|
||||
Requires: java-javadoc
|
||||
|
||||
%description javadoc
|
||||
Javadoc for %{name}.
|
||||
@ -47,18 +39,14 @@ find . -name "*.jar" -exec rm -f {} \;
|
||||
rm -rf docs
|
||||
sed -i 's/\r//' KEYS LICENSE.resolver.txt NOTICE-resolver.txt
|
||||
|
||||
%mvn_file : xml-commons-resolver xml-resolver
|
||||
|
||||
%build
|
||||
%ant -f resolver.xml jar javadocs
|
||||
%mvn_artifact %{SOURCE5} build/resolver.jar
|
||||
|
||||
%install
|
||||
# Jars
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
|
||||
install -p -m 644 build/resolver.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
|
||||
ln -s %{name}.jar $RPM_BUILD_ROOT%{_javadir}/xml-resolver.jar
|
||||
|
||||
# Javadocs
|
||||
mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name}
|
||||
cp -pr build/apidocs/resolver/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
|
||||
%mvn_install -J build/apidocs/resolver
|
||||
|
||||
# Scripts
|
||||
mkdir -p $RPM_BUILD_ROOT%{_bindir}
|
||||
@ -72,23 +60,18 @@ install -p -m 644 %{SOURCE6} ${RPM_BUILD_ROOT}%{_mandir}/man1/xml-resolver.1
|
||||
install -p -m 644 %{SOURCE7} ${RPM_BUILD_ROOT}%{_mandir}/man1/xml-xparse.1
|
||||
install -p -m 644 %{SOURCE8} ${RPM_BUILD_ROOT}%{_mandir}/man1/xml-xread.1
|
||||
|
||||
# Pom
|
||||
install -d -m 755 %{buildroot}%{_mavenpomdir}
|
||||
install -p -m 644 %{SOURCE5} %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
|
||||
%add_maven_depmap JPP-%{name}.pom %{name}.jar
|
||||
|
||||
%files -f .mfiles
|
||||
%doc KEYS LICENSE.resolver.txt NOTICE-resolver.txt
|
||||
%{_mavenpomdir}/*
|
||||
%{_javadir}/*
|
||||
%{_mandir}/man1/*
|
||||
%{_bindir}/xml-*
|
||||
|
||||
%files javadoc
|
||||
%{_javadocdir}/%{name}
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%doc LICENSE.resolver.txt NOTICE-resolver.txt
|
||||
|
||||
%changelog
|
||||
* Thu Feb 23 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2-22
|
||||
- Update to current packaging guidelines
|
||||
|
||||
* Thu Feb 16 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2-21
|
||||
- Fix rpm conditional
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user