tanukiwrapper/tanukiwrapper.spec
P. Janouch 605d65665f Accepting request 390774 from home:dmacvicar:branches:Java:packages
- update to version 3.5.29
- update to version 3.5.28
- removed not longer needed patches
  * tanukiwrapper-no-4g-mem-limit.patch
  * tanukiwrapper-makefile-linux-x86-64.patch
  * tanukiwrapper-makefile-linux-x86-64.patch
- Move from jpackage-utils to javapackages-tools
- aarch64 and ppc64le are 64bit 
- format specfile
- allow more than 4G as -Xmx option (bnc#914900)
  * add tanukiwrapper-no-4g-mem-limit.patch
- License: and Obsoletes: fields fixed 
- x86_64 Makefile fixed
- change rpm groups
- remove BuildRequires on javadoc. It should be part of the
  devel package which is already required.

- rebase on current upstream which builds on s390x

OBS-URL: https://build.opensuse.org/request/show/390774
OBS-URL: https://build.opensuse.org/package/show/Java:packages/tanukiwrapper?expand=0&rev=20
2016-04-20 12:58:11 +00:00

140 lines
4.1 KiB
RPMSpec

#
# spec file for package tanukiwrapper
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2000-2006, JPackage Project
#
# 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/
#
Name: tanukiwrapper
Version: 3.5.29
Release: 0.<RELEASE2>
Summary: Java Service Wrapper
License: GPL-2.0
Group: Development/Languages/Java
Url: http://wrapper.tanukisoftware.org/
Source0: http://download.sourceforge.net/wrapper/wrapper_%{version}_src.tar.gz
Source1: wrapper.1
Patch0: %{name}-additional-makefiles.patch
BuildRequires: ant >= 1.6.1
BuildRequires: ant-junit
BuildRequires: ant-nodeps >= 1.6.1
BuildRequires: cunit-devel
BuildRequires: glibc-devel
BuildRequires: java-devel >= 1.6.0
BuildRequires: javapackages-tools
BuildRequires: perl
BuildRequires: xerces-j2
BuildRequires: xml-commons-apis
Requires: javapackages-tools
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
The Java Service Wrapper is an application which has
evolved out of a desire to solve a number of problems
common to many Java applications:
- Run as a Windows Service or Unix Daemon
- Application Reliability
- Standard, Out of the Box Scripting
- On Demand Restarts
- Flexible Configuration
- Ease Application installations
- Logging
%package javadoc
Summary: Javadoc documentation for %{name}
Group: Documentation/Other
# For /bin/rm and /bin/ln
Requires(post): coreutils
Requires(postun): coreutils
%description javadoc
This package contains the javadoc documentation for %{name}
%package manual
Summary: Manuals for %{name}
Group: Documentation/Other
%description manual
This package contains the manuals for %{name}
%prep
%setup -q -n wrapper_%{version}_src
%patch0 -p1
find . -name "*.jar" -exec rm -f {} \;
perl -p -i -e 's|-O3|%{optflags}|' src/c/Makefile*
rm -f bin/* build/* conf/* lib/* logs/* test/* src/c/*.o src/c/wrapperinfo.c
%build
export CLASSPATH=$(build-classpath ant junit xerces-j2 xml-commons-apis)
%{ant} -Dbuild.sysclasspath=first -Dbits=%{__isa_bits}
%{javadoc} -sourcepath src/java -d build/javadoc org.tanukisoftware.wrapper
%install
# jar
%{__mkdir} -p %{buildroot}%{_javadir}
%{__install} -p -m 0644 lib/wrapper.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar
(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done)
# jni
%{__install} -d -m 755 %{buildroot}%{_libdir}
%{__install} -p -m 755 lib/libwrapper.so %{buildroot}%{_libdir}
# commands
%{__install} -d -m 755 %{buildroot}%{_sbindir}
%{__install} -p -m 755 bin/wrapper %{buildroot}%{_sbindir}/%{name}
# javadoc
%{__install} -d -m 755 %{buildroot}%{_javadocdir}/%{name}-%{version}
cp -a build/javadoc/* %{buildroot}%{_javadocdir}/%{name}-%{version}
%{__ln_s} %{name}-%{version} %{buildroot}%{_javadocdir}/%{name} # ghost symlink
# manpage
%{__mkdir_p} %{buildroot}%{_mandir}/man1
%{__install} -p -m 0644 %{SOURCE1} %{buildroot}%{_mandir}/man1/%{name}.1
%check
%{ant} -Dbuild.sysclasspath=first -Dbits=%{__isa_bits} test
%post javadoc
rm -rf %{_javadocdir}/%{name}
%{__ln_s} -f %{name}-%{version} %{_javadocdir}/%{name}
%postun javadoc
if [ "$1" = "0" ]; then
rm -f %{_javadocdir}/%{name}
fi
%files
%defattr(-,root,root,-)
%doc doc/wrapper-community-license-1.3.txt
%{_sbindir}/%{name}
%{_libdir}/libwrapper.so
%{_javadir}/%{name}*.jar
%{_mandir}/man1/%{name}.1.*
%files javadoc
%defattr(0644,root,root,0755)
%{_javadocdir}/%{name}-%{version}
%ghost %doc %{_javadocdir}/%{name}
%files manual
%defattr(0644,root,root,0755)
%doc doc/*
%changelog