[pytrailer/f14/master] New upstream version and python3 subpackage

Stanislav Ochotnicky sochotni at fedoraproject.org
Tue Oct 26 07:27:20 UTC 2010


commit 46dced256da0e0a6320395fcf467075a0263fdeb
Author: Stanislav Ochotnicky <sochotnicky at redhat.com>
Date:   Tue Oct 26 09:26:42 2010 +0200

    New upstream version and python3 subpackage

 .gitignore     |    1 +
 pytrailer.spec |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++----
 sources        |    2 +-
 3 files changed, 53 insertions(+), 5 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 63a4375..6fab4f3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
 /pytrailer-0.3.1.tar.gz
+/pytrailer-0.4.tar.gz
diff --git a/pytrailer.spec b/pytrailer.spec
index 6e7618f..3922885 100644
--- a/pytrailer.spec
+++ b/pytrailer.spec
@@ -1,10 +1,13 @@
-%if 0%{?fedora} < 13 && 0%{?rhel} < 6
-%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
+%if 0%{?fedora} > 12 || 0%{?rhel} > 6
+    %global with_python3 1
+%else
+    %{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print (get_python_lib())")}
 %endif
 
+
 Name:           pytrailer
-Version:        0.3.1
-Release:        2%{?dist}
+Version:        0.4
+Release:        1%{?dist}
 Summary:        Python module to simplify access to movie trailers on apple.com
 Group:          Development/Libraries
 License:        LGPLv3
@@ -14,24 +17,57 @@ BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildArch:      noarch
 BuildRequires:  python-devel,python-setuptools
+%if 0%{?with_python3}
+BuildRequires:  python3-devel,python3-setuptools
+%endif # if with_python3
+
 
 %description
 Pytrailer is very simple python module using JSON and few simple
 regular expressions to simplify access to trailer information on
 www.apple.com/trailers.
 
+%if 0%{?with_python3}
+%package -n python3-%{name}
+Summary:        Python module to simplify access to movie trailers on apple.com
+Group:          Development/Libraries
+
+%description -n python3-%{name}
+Pytrailer is very simple python 3 module using JSON and few simple
+regular expressions to simplify access to trailer information on
+www.apple.com/trailers.
+%endif #with_python3
 
 %prep
 %setup -q
 
+%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
 rm -rf %{buildroot}
+
 %{__python} setup.py install --skip-build --root %{buildroot}
 
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py install --skip-build --root %{buildroot}
+popd
+%endif # with_python3
+
 
 %clean
 rm -rf %{buildroot}
@@ -43,7 +79,18 @@ rm -rf %{buildroot}
 %{python_sitelib}/pytrailer*
 %{python_sitelib}/*.egg-info
 
+%files -n python3-%{name}
+%defattr(-,root,root,-)
+%doc LICENSE README
+%{python3_sitelib}/pytrailer*
+%{python3_sitelib}/*.egg-info
+
+
 %changelog
+* Tue Oct 26 2010 Stanislav Ochotnicky <sochotnicky at redhat.com> - 0.4-1
+- New upstream version
+- Python3 subpackage
+
 * Fri Oct 15 2010 Stanislav Ochotnicky <sochotnicky at redhat.com> - 0.3.1-2
 - Fix License tag to match license of the package
 - Change RPM_BUILD_ROOT to buildroot macro
diff --git a/sources b/sources
index 9652cde..ab798b1 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-e563e9ecdcb7cf8491d17a9758446b6a  pytrailer-0.3.1.tar.gz
+7bbfa3c495a251d54cd9f51b9657a8f0  pytrailer-0.4.tar.gz


More information about the scm-commits mailing list