[packages/yasm] add python bcond
glen
glen at pld-linux.org
Thu Aug 2 12:05:47 CEST 2012
commit 40c83e876a1574018626a5c68a6493f6984fd0fb
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Thu Aug 2 13:05:40 2012 +0300
add python bcond
yasm.spec | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/yasm.spec b/yasm.spec
index 8627d5c..7f54ad9 100644
--- a/yasm.spec
+++ b/yasm.spec
@@ -1,3 +1,7 @@
+#
+# Conditional build:
+%bcond_without python # without Python bindings
+
Summary: The YASM Modular Assembler
Summary(pl.UTF-8): Modularny assembler YASM
Name: yasm
@@ -13,7 +17,7 @@ BuildRequires: autoconf >= 2.53
BuildRequires: automake >= 1:1.9.6
BuildRequires: gettext-devel
BuildRequires: libtool
-BuildRequires: python-Cython >= 0.11.3
+%{?with_python:BuildRequires: python-Cython >= 0.11.3}
BuildRequires: xmlto
Obsoletes: libyasm
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -73,7 +77,7 @@ Pythonowy interfejs do biblioteki yasm.
%{__automake}
%configure \
%{?debug:--enable-debug} \
- --enable-python-bindings
+ %{?with_python:--enable-python-bindings}
%{__make} -j1 all check
@@ -102,7 +106,9 @@ rm -rf $RPM_BUILD_ROOT
%{_includedir}/libyasm*.h
%{_includedir}/libyasm
+%if %{with python}
%files -n python-yasm
%defattr(644,root,root,755)
%attr(755,root,root) %{py_sitedir}/yasm.so
%{py_sitedir}/yasm-0.0-py*.egg-info
+%endif
More information about the pld-cvs-commit
mailing list