From d49f04c50f10685d3703170d60c593f03acd32b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaroslav=20=C5=A0karvada?= Date: Thu, 9 May 2013 14:05:20 +0200 Subject: [PATCH] Improved macros for python3 conditinal build --- brltty.spec | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/brltty.spec b/brltty.spec index 1019e73..8989769 100644 --- a/brltty.spec +++ b/brltty.spec @@ -122,7 +122,7 @@ Summary: Python binding for BrlAPI %description -n python-brlapi This package provides the Python binding for BrlAPI. -%if %{with_python3} +%if 0%{?with_python3} %package -n python3-brlapi Version: %{api_version} Group: Development/System @@ -165,7 +165,7 @@ This package provides the OCaml binding for BrlAPI. %setup -q %patch4 -p1 -b .loadLibrary -%if %{with_python3} +%if 0%{?with_python3} # Make a copy of the source tree for building the Python 3 module rm -rf %{py3dir} cp -a . %{py3dir} @@ -198,7 +198,7 @@ configure_opts=" \ %configure $configure_opts PYTHON=%{__python2} make %{?_smp_mflags} -%if %{with_python3} +%if 0%{?with_python3} # ... and then do it again for the Python 3 module pushd %{py3dir} %configure $configure_opts PYTHON=%{__python3} @@ -233,7 +233,7 @@ make install JAVA_JAR_DIR=%{_jnidir} \ JAVA_JNI_DIR=%{_libdir}/brltty \ JAVA_JNI=yes -%if %{with_python3} +%if 0%{?with_python3} # Python 3 pushd %{py3dir} make install JAVA_JAR_DIR=%{_jnidir} \ @@ -333,7 +333,7 @@ exit 0 %{python_sitearch}/brlapi.so %{python_sitearch}/Brlapi-%{api_version}-*.egg-info -%if %{with_python3} +%if 0%{?with_python3} %files -n python3-brlapi %{python3_sitearch}/brlapi.cpython-*.so %{python3_sitearch}/Brlapi-%{api_version}-*.egg-info