2016-09-29 12:39:51 +02:00
|
|
|
#
|
2016-09-29 12:44:28 +02:00
|
|
|
# spec file for package apache-commons-pool
|
2016-09-29 12:39:51 +02:00
|
|
|
#
|
2016-09-29 12:44:28 +02:00
|
|
|
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
2016-09-29 12:39:51 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
%define base_name pool
|
|
|
|
%define short_name commons-%{base_name}
|
|
|
|
Name: jakarta-commons-pool
|
|
|
|
Version: 1.3
|
|
|
|
Release: 0
|
|
|
|
Summary: Jakarta Commons Pool Package
|
|
|
|
License: Apache-2.0
|
|
|
|
Group: Development/Libraries/Java
|
2016-09-29 12:44:28 +02:00
|
|
|
Url: https://commons.apache.org/proper/commons-pool/
|
2016-09-29 12:39:51 +02:00
|
|
|
Source0: http://www.apache.org/dist/jakarta/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.bz2
|
|
|
|
Source1: pom-maven2jpp-depcat.xsl
|
|
|
|
Source2: pom-maven2jpp-newdepmap.xsl
|
|
|
|
Source3: pom-maven2jpp-mapdeps.xsl
|
|
|
|
Source4: %{base_name}-%{version}-jpp-depmap.xml
|
|
|
|
Source5: commons-build.tar.bz2
|
|
|
|
Source6: pool-tomcat5-build.xml
|
|
|
|
Source7: commons-pool-maven-build.dtd
|
|
|
|
Source8: commons-pool-commons.ent
|
|
|
|
Patch0: jakarta-commons-pool-build.patch
|
|
|
|
BuildRequires: ant
|
2016-09-29 12:44:28 +02:00
|
|
|
BuildRequires: java-devel
|
2016-09-29 12:39:51 +02:00
|
|
|
BuildRequires: javapackages-tools
|
|
|
|
BuildRequires: junit
|
2016-09-29 12:44:28 +02:00
|
|
|
Provides: jakarta-commons-pool = %{version}
|
|
|
|
Obsoletes: jakarta-commons-pool < %{version}
|
|
|
|
Provides: %{short_name} = %{version}
|
|
|
|
Obsoletes: %{short_name} < %{version}
|
2016-09-29 12:39:51 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2016-09-29 12:44:28 +02:00
|
|
|
BuildArch: noarch
|
2016-09-29 12:39:51 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
The goal of the Pool package is to create and maintain an object
|
|
|
|
(instance) pooling package to be distributed under the ASF license. The
|
|
|
|
package supports a variety of pool implementations, but encourages
|
|
|
|
support of an interface that makes these implementations
|
|
|
|
interchangeable.
|
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: Javadoc for jakarta-commons-pool
|
|
|
|
Group: Development/Libraries/Java
|
2016-09-29 12:44:28 +02:00
|
|
|
Requires(post): /bin/ln
|
|
|
|
Requires(post): /bin/rm
|
|
|
|
Requires(postun): /bin/rm
|
|
|
|
%if ! %defined suse_version
|
2016-09-29 12:39:51 +02:00
|
|
|
Requires: java-javadoc
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
The goal of Pool package it to create and maintain an object (instance)
|
|
|
|
pooling package to be distributed under the ASF license. The package
|
|
|
|
should support a variety of pool implementations, but encourage support
|
|
|
|
of an interface that makes these implementations interchangeable.
|
|
|
|
|
|
|
|
This package contains the javadoc documentation for the Jakarta Commons
|
|
|
|
Pool Package.
|
|
|
|
|
|
|
|
%package tomcat5
|
|
|
|
Summary: Jakarta Commons Pool Package
|
|
|
|
Group: Development/Libraries/Java
|
|
|
|
|
|
|
|
%description tomcat5
|
|
|
|
The goal of the Pool package is to create and maintain an object
|
|
|
|
(instance) pooling package to be distributed under the ASF license. The
|
|
|
|
package supports a variety of pool implementations, but encourages
|
|
|
|
support of an interface that makes these implementations
|
|
|
|
interchangeable.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n %{short_name}-%{version}-src
|
|
|
|
# remove all binary libs
|
|
|
|
find . -name "*.jar" -exec rm -f {} \;
|
|
|
|
bzip2 -dc %{SOURCE5} | tar xf -
|
|
|
|
%patch0
|
|
|
|
cp %{SOURCE6} .
|
|
|
|
|
|
|
|
%build
|
|
|
|
mkdir ./tmp
|
|
|
|
ant -Djava.io.tmpdir=. clean dist
|
|
|
|
#commons-pool-tomcat5
|
|
|
|
ant -f pool-tomcat5-build.xml
|
|
|
|
ant -Djava.io.tmpdir=. clean dist
|
|
|
|
|
|
|
|
%install
|
|
|
|
# jars
|
2016-09-29 12:44:28 +02:00
|
|
|
install -d -m 755 %{buildroot}%{_javadir}
|
2016-09-29 12:39:51 +02:00
|
|
|
%if %{with_maven}
|
2016-09-29 12:44:28 +02:00
|
|
|
install -m 644 target/%{short_name}-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar
|
2016-09-29 12:39:51 +02:00
|
|
|
%else
|
2016-09-29 12:44:28 +02:00
|
|
|
install -m 644 dist/%{short_name}-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar
|
2016-09-29 12:39:51 +02:00
|
|
|
%endif
|
|
|
|
#tomcat5 jar
|
2016-09-29 12:44:28 +02:00
|
|
|
install -m 644 pool-tomcat5/%{short_name}-tomcat5.jar %{buildroot}%{_javadir}/%{name}-tomcat5-%{version}.jar
|
|
|
|
(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|jakarta-||g"`; done)
|
|
|
|
(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done)
|
2016-09-29 12:39:51 +02:00
|
|
|
# javadoc
|
2016-09-29 12:44:28 +02:00
|
|
|
install -d -m 755 %{buildroot}%{_javadocdir}/%{name}
|
|
|
|
cp -pr dist/docs/api/* %{buildroot}%{_javadocdir}/%{name}
|
2016-09-29 12:39:51 +02:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(0644,root,root,0755)
|
|
|
|
%doc README.txt LICENSE.txt
|
|
|
|
%{_javadir}/%{name}.jar
|
|
|
|
%{_javadir}/%{name}-%{version}.jar
|
|
|
|
%{_javadir}/%{short_name}.jar
|
|
|
|
%{_javadir}/%{short_name}-%{version}.jar
|
|
|
|
|
|
|
|
%files tomcat5
|
|
|
|
%defattr(0644,root,root,0755)
|
|
|
|
%{_javadir}/*-tomcat5*.jar
|
|
|
|
|
|
|
|
%files javadoc
|
|
|
|
%defattr(0644,root,root,0755)
|
2016-09-29 12:44:28 +02:00
|
|
|
%doc %{_javadocdir}/%{name}
|
2016-09-29 12:39:51 +02:00
|
|
|
|
|
|
|
%changelog
|