From 9ffba5f4ddc7f4b167ff6a494516bc2d1ab49c06 Mon Sep 17 00:00:00 2001 From: Orion Poplawski Date: Sun, 30 Aug 2015 14:46:11 -0600 Subject: [PATCH] Minor spec cleanup --- pytz.spec | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pytz.spec b/pytz.spec index c6213ad..be1d04f 100644 --- a/pytz.spec +++ b/pytz.spec @@ -1,7 +1,7 @@ -%if 0%{?fedora} > 12 +%if 0%{?fedora} %global with_python3 1 %else -%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} +%{!?python2_sitelib: %global python2_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %endif Name: pytz @@ -71,8 +71,8 @@ popd %install %{__python} setup.py install --skip-build --root %{buildroot} -chmod +x %{buildroot}%{python_sitelib}/pytz/*.py -rm -rf %{buildroot}%{python_sitelib}/pytz/zoneinfo +chmod +x %{buildroot}%{python2_sitelib}/pytz/*.py +rm -rf %{buildroot}%{python2_sitelib}/pytz/zoneinfo %if 0%{?with_python3} pushd %{py3dir} @@ -86,10 +86,9 @@ rm -rf $RPM_BUILD_ROOT %files -%defattr(-,root,root,-) %doc CHANGES.txt LICENSE.txt README.txt -%{python_sitelib}/pytz/ -%{python_sitelib}/*.egg-info +%{python2_sitelib}/pytz/ +%{python2_sitelib}/*.egg-info %if 0%{?with_python3} %files -n python3-pytz