From 1b1882800cce7f271bebdb6d62a8b3f9c99baf26 Mon Sep 17 00:00:00 2001 From: sopwith Date: Fri, 22 Nov 2002 14:58:21 +0000 Subject: [PATCH] Handle python disablement better by always passing --with-python/--without-python as appropriate. CVS patchset: 5878 CVS date: 2002/11/22 14:58:21 --- rpm.spec.in | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/rpm.spec.in b/rpm.spec.in index 3a83b42..a637c74 100644 --- a/rpm.spec.in +++ b/rpm.spec.in @@ -118,15 +118,25 @@ shell-like rules. %build +%if %{with_python_subpackage} +WITH_PYTHON="--with-python=%{with_python_version}" +%else +WITH_PYTHON="--without-python" +%endif + %ifos linux %ifarch x86_64 s390 s390x CFLAGS="$RPM_OPT_FLAGS -fPIC"; export CFLAGS %else CFLAGS="$RPM_OPT_FLAGS"; export CFLAGS %endif -CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{__prefix} --sysconfdir=/etc --localstatedir=/var --infodir='${prefix}%{__share}/info' --mandir='${prefix}%{__share}/man' --with-python=%{with_python_version} --without-javaglue +CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{__prefix} --sysconfdir=/etc \ + --localstatedir=/var --infodir='${prefix}%{__share}/info' \ + --mandir='${prefix}%{__share}/man' \ + $WITH_PYTHON --without-javaglue %else -CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{__prefix} +CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{__prefix} $WITH_PYTHON \ + --without-javaglue %endif make -- 2.7.4