Build with xmvn

- Disable fluent-hc module
This commit is contained in:
Michal Srb 2013-01-25 11:02:01 +01:00
parent 19bff7f13e
commit 497db611c9

View File

@ -3,7 +3,7 @@
Name: httpcomponents-client
Summary: HTTP agent implementation based on httpcomponents HttpCore
Version: 4.2.3
Release: 1%{?dist}
Release: 2%{?dist}
Group: Development/Libraries
License: ASL 2.0
URL: http://hc.apache.org/
@ -11,17 +11,12 @@ Source0: http://archive.apache.org/dist/httpcomponents/httpclient/sour
BuildArch: noarch
BuildRequires: xmvn >= 0.2.5
BuildRequires: httpcomponents-project
BuildRequires: httpcomponents-core
BuildRequires: apache-mime4j
BuildRequires: apache-commons-codec
Requires: java >= 1:1.6.0
Requires: jpackage-utils
Requires: httpcomponents-core
Requires: apache-mime4j
Requires: apache-commons-codec
%description
HttpClient is a HTTP/1.1 compliant HTTP agent implementation based on
httpcomponents HttpCore. It also provides reusable components for
@ -33,7 +28,6 @@ encouraged to upgrade.
%package javadoc
Summary: API documentation for %{name}
Group: Documentation
Requires: jpackage-utils
%description javadoc
%{summary}.
@ -45,6 +39,7 @@ Requires: jpackage-utils
# Remove optional build deps not available in Fedora
%pom_disable_module httpclient-cache
%pom_disable_module httpclient-osgi
%pom_disable_module fluent-hc
%pom_remove_dep :mockito-core httpclient
%pom_remove_plugin :maven-notice-plugin
%pom_remove_plugin :docbkx-maven-plugin
@ -96,48 +91,27 @@ done
</plugin>" httpclient
%build
mvn-rpmbuild -Dmaven.test.skip=true install javadoc:aggregate
%mvn_file ":{*}" httpcomponents/@1
%mvn_build -f
%install
# jars
install -dm 755 %{buildroot}%{_javadir}/%{base_name}
install -m 644 httpclient/target/httpclient-%{version}.jar %{buildroot}%{_javadir}/%{base_name}/httpclient.jar
install -m 644 httpmime/target/httpmime-%{version}.jar %{buildroot}%{_javadir}/%{base_name}/httpmime.jar
# main pom
install -dm 755 %{buildroot}/%{_mavenpomdir}
install -pm 644 pom.xml \
%{buildroot}/%{_mavenpomdir}/JPP.%{base_name}-httpcomponents-client.pom
%add_maven_depmap JPP.%{base_name}-httpcomponents-client.pom
# pom
install -pm 644 httpclient/pom.xml \
%{buildroot}/%{_mavenpomdir}/JPP.%{base_name}-httpclient.pom
%add_maven_depmap JPP.%{base_name}-httpclient.pom %{base_name}/httpclient.jar
install -pm 644 httpmime/pom.xml \
%{buildroot}/%{_mavenpomdir}/JPP.%{base_name}-httpmime.pom
%add_maven_depmap JPP.%{base_name}-httpmime.pom %{base_name}/httpmime.jar
%mvn_install
# javadocs
install -dm 755 %{buildroot}%{_javadocdir}/%{name}
cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
%files
%files -f .mfiles
%doc LICENSE.txt NOTICE.txt
%doc README.txt RELEASE_NOTES.txt
%{_mavendepmapfragdir}/%{name}
%{_mavenpomdir}/JPP.%{base_name}*.pom
%{_javadir}/%{base_name}
%files javadoc
%files javadoc -f .mfiles-javadoc
%doc LICENSE.txt NOTICE.txt
%doc %{_javadocdir}/%{name}
%changelog
* Fri Jan 25 2013 Michal Srb <msrb@redhat.com> - 4.2.3-2
- Build with xmvn
- Disable fluent-hc module
* Thu Jan 24 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.2.3-1
- Update to upstream version 4.2.3