- conditionalize java subpackage

This commit is contained in:
jorton 2005-03-08 11:21:24 +00:00
parent 539f500b87
commit 5be0495fd1
1 changed files with 10 additions and 1 deletions

View File

@ -1,5 +1,6 @@
# set to zero to avoid running test suite # set to zero to avoid running test suite
%define make_check 1 %define make_check 1
%define with_java %{?_with_java:1}%{!?_with_java:0}
# set JDK path to build javahl; default for JPackage # set JDK path to build javahl; default for JPackage
%define jdk_path /usr/lib/jvm/java-1.4.2-gcj %define jdk_path /usr/lib/jvm/java-1.4.2-gcj
@ -74,6 +75,7 @@ Requires: subversion = %{version}-%{release}
This package includes the Perl bindings to the Subversion libraries. This package includes the Perl bindings to the Subversion libraries.
%endif %endif
%if %{with_java}
%package javahl %package javahl
Group: Development/Libraries Group: Development/Libraries
Summary: JNI bindings to the Subversion libraries Summary: JNI bindings to the Subversion libraries
@ -82,6 +84,7 @@ BuildPreReq: java-1.4.2-gcj-compat-devel
%description javahl %description javahl
This package includes the JNI bindings to the Subversion libraries. This package includes the JNI bindings to the Subversion libraries.
%endif
%prep %prep
%setup -q %setup -q
@ -89,7 +92,9 @@ This package includes the JNI bindings to the Subversion libraries.
%patch2 -p1 -b .deplibs %patch2 -p1 -b .deplibs
%patch3 -p1 -b .rpath %patch3 -p1 -b .rpath
%patch6 -p1 -b .pie %patch6 -p1 -b .pie
%if %{with_java}
%patch7 -p1 -b .java %patch7 -p1 -b .java
%endif
rm -rf neon apr apr-util db4 rm -rf neon apr apr-util db4
@ -108,11 +113,13 @@ export CC=gcc CXX=g++ JAVA_HOME=%{jdk_path}
--with-apxs=%{_sbindir}/apxs --disable-mod-activation --with-apxs=%{_sbindir}/apxs --disable-mod-activation
make %{?_smp_mflags} all %{swigdirs} make %{?_smp_mflags} all %{swigdirs}
#make swig-pl swig-py #make swig-pl swig-py
%if %{with_java}
make javahl make javahl
%endif
%install %install
rm -rf ${RPM_BUILD_ROOT} rm -rf ${RPM_BUILD_ROOT}
make install install-javahl \ make install %{?_with_java:install-javahl} \
DESTDIR=$RPM_BUILD_ROOT %{swigdirs} DESTDIR=$RPM_BUILD_ROOT %{swigdirs}
# install-swig-py install-swig-pl-lib # install-swig-py install-swig-pl-lib
@ -219,10 +226,12 @@ rm -rf ${RPM_BUILD_ROOT}
%{_mandir}/man*/*::* %{_mandir}/man*/*::*
%endif %endif
%if %{with_java}
%files javahl %files javahl
%defattr(-,root,root,-) %defattr(-,root,root,-)
%{_libdir}/libsvnjavahl-1.* %{_libdir}/libsvnjavahl-1.*
%{_libdir}/svn-javahl %{_libdir}/svn-javahl
%endif
%changelog %changelog
* Tue Mar 8 2005 Joe Orton <jorton@redhat.com> 1.1.3-5 * Tue Mar 8 2005 Joe Orton <jorton@redhat.com> 1.1.3-5