From bd5d27dea1af6a9fa5de3d6e958682932a2a9f5a Mon Sep 17 00:00:00 2001 From: Stanislav Ochotnicky Date: Thu, 23 Dec 2010 11:05:58 +0100 Subject: [PATCH] Initial commit --- .gitignore | 1 + 0001-Remove-unneeded-pom-dependencies.patch | 178 ++++++++++++++++++++ httpcomponents-core.spec | 103 +++++++++++ sources | 1 + 4 files changed, 283 insertions(+) create mode 100644 0001-Remove-unneeded-pom-dependencies.patch create mode 100644 httpcomponents-core.spec diff --git a/.gitignore b/.gitignore index e69de29..f594002 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/httpcomponents-core-4.1-src.tar.gz diff --git a/0001-Remove-unneeded-pom-dependencies.patch b/0001-Remove-unneeded-pom-dependencies.patch new file mode 100644 index 0000000..d7ffe58 --- /dev/null +++ b/0001-Remove-unneeded-pom-dependencies.patch @@ -0,0 +1,178 @@ +From 8f27e169ae72b1cecb91c6a911e4ded5aeac7005 Mon Sep 17 00:00:00 2001 +From: Stanislav Ochotnicky +Date: Fri, 17 Dec 2010 15:22:06 +0100 +Subject: [PATCH] Remove unneeded pom dependencies + +--- + httpcore-nio/pom.xml | 26 ---------------------- + httpcore/pom.xml | 26 ---------------------- + pom.xml | 58 -------------------------------------------------- + 3 files changed, 0 insertions(+), 110 deletions(-) + +diff --git a/httpcore-nio/pom.xml b/httpcore-nio/pom.xml +index 7eba598..14aa177 100644 +--- a/httpcore-nio/pom.xml ++++ b/httpcore-nio/pom.xml +@@ -103,24 +103,6 @@ + + + +- +- com.atlassian.maven.plugins +- maven-clover2-plugin +- +- threaded +- 100 +- 50% +- +- +- +- site +- pre-site +- +- instrument +- +- +- +- + + + +@@ -146,14 +128,6 @@ + + + +- com.atlassian.maven.plugins +- maven-clover2-plugin +- +- 1.5 +- +- +- +- + org.codehaus.mojo + clirr-maven-plugin + +diff --git a/httpcore/pom.xml b/httpcore/pom.xml +index e01f182..c0ca7ed 100644 +--- a/httpcore/pom.xml ++++ b/httpcore/pom.xml +@@ -111,24 +111,6 @@ + + + +- +- com.atlassian.maven.plugins +- maven-clover2-plugin +- +- threaded +- 100 +- 50% +- +- +- +- site +- pre-site +- +- instrument +- +- +- +- + + + +@@ -153,14 +135,6 @@ + + + +- com.atlassian.maven.plugins +- maven-clover2-plugin +- +- 1.4 +- +- +- +- + org.codehaus.mojo + clirr-maven-plugin + +diff --git a/pom.xml b/pom.xml +index 6305d73..45e5e2c 100644 +--- a/pom.xml ++++ b/pom.xml +@@ -91,21 +91,6 @@ + + + +- maven-notice-plugin +- org.apache.httpcomponents +- +- +- attach-notice-license +- +- generate +- +- +- +- +- Apache HttpComponents +- +- +- + maven-source-plugin + + +@@ -166,49 +151,6 @@ + + + +- com.agilejava.docbkx +- docbkx-maven-plugin +- +- +- org.docbook +- docbook-xml +- 4.4 +- runtime +- +- +- +- index.xml +- true +- true +- src/docbkx/resources/xsl/fopdf.xsl +- src/docbkx/resources/xsl/html_chunk.xsl +- css/hc-tutorial.css +- +- +- version +- ${project.version} +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- + maven-resources-plugin + + +-- +1.7.3.3 + diff --git a/httpcomponents-core.spec b/httpcomponents-core.spec new file mode 100644 index 0000000..50a5832 --- /dev/null +++ b/httpcomponents-core.spec @@ -0,0 +1,103 @@ +Name: httpcomponents-core +Summary: Set of low level Java HTTP transport components for HTTP services +Version: 4.1 +Release: 2%{?dist} +Group: Development/Libraries +License: ASL 2.0 +URL: http://hc.apache.org/ +Source0: http://www.apache.org/dist/httpcomponents/httpcore/source/httpcomponents-core-%{version}-src.tar.gz +Patch0: 0001-Remove-unneeded-pom-dependencies.patch +BuildArch: noarch + +BuildRequires: httpcomponents-project +BuildRequires: java >= 1:1.6.0 +BuildRequires: jpackage-utils + +Requires: java >= 1:1.6.0 +Requires: jpackage-utils + +Requires(post): jpackage-utils +Requires(postun): jpackage-utils + +%description +HttpCore is a set of low level HTTP transport components that can be +used to build custom client and server side HTTP services with a +minimal footprint. HttpCore supports two I/O models: blocking I/O +model based on the classic Java I/O and non-blocking, event driven I/O +model based on Java NIO. + +The blocking I/O model may be more appropriate for data intensive, low +latency scenarios, whereas the non-blocking model may be more +appropriate for high latency scenarios where raw data throughput is +less important than the ability to handle thousands of simultaneous +HTTP connections in a resource efficient manner. + +%package javadoc +Summary: API documentation for %{name} +Group: Documentation +Requires: jpackage-utils + +%description javadoc +%{summary}. + + +%prep +%setup -q +%patch0 -p1 + +%build +export maven_repo_local=$(pwd)/.m2/repository +install -d $maven_repo_local + +# start using install again when bundle plugin is updated to 2.1.0 +mvn-jpp -Dmaven.repo.local=$maven_repo_local \ + package javadoc:aggregate + +%install +install -d %{buildroot}/%{_mavenpomdir} +install -d %{buildroot}/%{_javadir}/%{name} + +for m in httpcore httpcore-nio httpcore-osgi; do + # poms + install -m 0644 $m/pom.xml %{buildroot}/%{_mavenpomdir}/JPP.%{name}-$m.pom + + # jars - osgi doesn't have one + if [ -f $m/target/$m-%{version}.jar ];then + install -m 0644 $m/target/$m-%{version}.jar %{buildroot}%{_javadir}/%{name}/$m.jar + fi + + %add_to_maven_depmap org.apache.httpcomponents $m %{version} JPP/%{name} $m +done + +# parent +install -D -m 0644 pom.xml %{buildroot}/%{_mavenpomdir}/JPP.%{name}-%{name}.pom +%add_to_maven_depmap org.apache.httpcomponents %{name} %{version} JPP/%{name} %{name} + +# javadocs +install -dm 755 %{buildroot}%{_javadocdir}/%{name} +cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name} + +%post +%update_maven_depmap + +%postun +%update_maven_depmap + +%files +%defattr(-,root,root,-) +%doc README.txt LICENSE.txt RELEASE_NOTES.txt +%{_mavendepmapfragdir}/%{name} +%{_mavenpomdir}/JPP.%{name}*.pom +%{_javadir}/%{name} + +%files javadoc +%doc LICENSE.txt +%defattr(-,root,root,-) +%doc %{_javadocdir}/* + +%changelog +* Wed Dec 22 2010 Stanislav Ochotnicky - 4.1-2 +- Added license to javadoc subpackage + +* Fri Dec 17 2010 Stanislav Ochotnicky - 4.1-1 +- Initial package diff --git a/sources b/sources index e69de29..7c2e814 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +5921a41284b6452a259c2ae55b1f78b6 httpcomponents-core-4.1-src.tar.gz