[python-plumbum/f18] Introduce python3 subpackage.
Bohuslav Kabrda
bkabrda at fedoraproject.org
Fri Feb 8 10:08:37 UTC 2013
commit 16c4041c409438d1205f67d9d14bcaaf7655c5d4
Author: Bohuslav Kabrda <bkabrda at redhat.com>
Date: Fri Feb 8 10:54:41 2013 +0100
Introduce python3 subpackage.
python-plumbum.spec | 48 +++++++++++++++++++++++++++++++++++++++++++++++-
1 files changed, 47 insertions(+), 1 deletions(-)
---
diff --git a/python-plumbum.spec b/python-plumbum.spec
index 71d4995..98c0244 100644
--- a/python-plumbum.spec
+++ b/python-plumbum.spec
@@ -1,8 +1,9 @@
%global pypi_name plumbum
+%global with_python3 1
Name: python-%{pypi_name}
Version: 0.9.0
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Shell combinators library
License: MIT
@@ -13,6 +14,10 @@ BuildArch: noarch
BuildRequires: python-devel
Requires: python-six
+%if 0%{?with_python3}
+BuildRequires: python3-devel
+%endif # if with_python3
+
%description
Ever wished the wrist-handiness of shell scripts be put into a real programming
language? Say hello to Plumbum Shell Combinators. Plumbum (Latin for lead,
@@ -22,15 +27,46 @@ library for shell script-like programs in Python. The motto of the library is
syntax ("shell combinators") where it makes sense, while keeping it all
pythonic and cross-platform.
+%if 0%{?with_python3}
+%package -n python3-%{pypi_name}
+Summary: Shell combinators library
+Requires: python3-six
+
+%description -n python3-%{pypi_name}
+Ever wished the wrist-handiness of shell scripts be put into a real programming
+language? Say hello to Plumbum Shell Combinators. Plumbum (Latin for lead,
+which was used to create pipes back in the day) is a small yet feature-rich
+library for shell script-like programs in Python. The motto of the library is
+"Never write shell scripts again", and thus it attempts to mimic the shell
+syntax ("shell combinators") where it makes sense, while keeping it all
+pythonic and cross-platform.
+%endif # with_python3
+
%prep
%setup -q -n %{pypi_name}-%{version}
rm -rf %{pypi_name}.egg-info
+%if 0%{?with_python3}
+rm -rf %{py3dir}
+cp -a . %{py3dir}
+%endif # with_python3
+
%build
%{__python} setup.py build
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py build
+popd
+%endif # with_python3
%install
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py install --skip-build --root %{buildroot}
+popd
+%endif # with_python3
+
%{__python} setup.py install -O1 --skip-build --root %{buildroot}
@@ -39,8 +75,18 @@ rm -rf %{pypi_name}.egg-info
%{python_sitelib}/%{pypi_name}
%{python_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
+%if 0%{?with_python3}
+%files -n python3-%{pypi_name}
+%doc LICENSE README.rst
+%{python3_sitelib}/%{pypi_name}
+%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
+%endif # with_python3
+
%changelog
+* Fri Feb 08 2013 Bohuslav Kabrda <bkabrda at redhat.com> - 0.9.0-3
+- Introduce python3 subpackage.
+
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.9.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
More information about the scm-commits
mailing list