14
0

Accepting request 121469 from home:TheBlackCat:branches:devel:languages:python

- Fix rpmlint warnings
- Improve openSUSE 11.4 build fix
- Clean up spec file

OBS-URL: https://build.opensuse.org/request/show/121469
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=19
This commit is contained in:
Todd R
2012-05-18 15:28:08 +00:00
committed by Git OBS Bridge
parent acb8c0cf3d
commit e39831b48d
4 changed files with 37 additions and 5 deletions

View File

@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Fri May 18 15:27:08 UTC 2012 - toddrme2178@gmail.com
- Fix rpmlint warnings
- Improve openSUSE 11.4 build fix
- Clean up spec file
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Apr 30 13:06:58 UTC 2012 - toddrme2178@gmail.com Mon Apr 30 13:06:58 UTC 2012 - toddrme2178@gmail.com

View File

@@ -28,7 +28,10 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel BuildRequires: python-devel
Requires: python-pycurl Requires: python-pycurl
Requires: python-simplejson Requires: python-simplejson
%if 0%{?suse_version} && 0%{?suse_version} <= 1110 %if 0%{?suse_version}
BuildRequires: fdupes
%endif
%if 0%{?suse_version} <= 1110
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else %else
BuildArch: noarch BuildArch: noarch
@@ -58,10 +61,17 @@ python setup.py build
%install %install
python setup.py install --prefix=%{_prefix} --root=%{buildroot} python setup.py install --prefix=%{_prefix} --root=%{buildroot}
%if 0%{?suse_version}
%fdupes demos
%endif
# fix executability rmplint warning
chmod +x %{buildroot}%{python_sitelib}/%{modname}/*.py
chmod +x %{buildroot}%{python_sitelib}/%{modname}/*/*.py
%files %files
%defattr(-,root,root,-) %defattr(-,root,root,-)
%doc README demos %doc README demos
%{python_sitelib}/%{modname} %{python_sitelib}/%{modname}
%{python_sitelib}/%{modname}-%{version}-py%{py_ver}.egg-info %{python_sitelib}/%{modname}-%{version}-py%{py_ver}.egg-info
%changelog %changelog

View File

@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Fri May 18 15:27:08 UTC 2012 - toddrme2178@gmail.com
- Fix rpmlint warnings
- Improve openSUSE 11.4 build fix
- Clean up spec file
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Apr 30 13:06:58 UTC 2012 - toddrme2178@gmail.com Mon Apr 30 13:06:58 UTC 2012 - toddrme2178@gmail.com

View File

@@ -28,13 +28,12 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: python3-2to3 BuildRequires: python3-2to3
BuildRequires: python3-distribute BuildRequires: python3-distribute
%if 0%{?suse_version}
BuildRequires: fdupes
%endif
%if 0%{?suse_version} <= 1140 %if 0%{?suse_version} <= 1140
%{!?python3_sitelib: %global python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} %{!?python3_sitelib: %global python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
%{!?py3_ver: %global py3_ver %(python3 -c "import sys; version=str(sys.version_info[0]) + '.' + str(sys.version_info[1]); print(version)" 2>/dev/null || echo PYTHON-NOT-FOUND)} %{!?py3_ver: %global py3_ver %(python3 -c "import sys; version=str(sys.version_info[0]) + '.' + str(sys.version_info[1]); print(version)" 2>/dev/null || echo PYTHON-NOT-FOUND)}
%ifarch x86_64
# to allow ownership of noarch python directories
BuildRequires: python3-32bit
%endif
%endif %endif
BuildArch: noarch BuildArch: noarch
Requires: python3 >= %{py3_ver} Requires: python3 >= %{py3_ver}
@@ -65,10 +64,19 @@ python3 setup.py build
%install %install
python3 setup.py install --prefix=%{_prefix} --root=%{buildroot} python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
%fdupes demos
# fix executability rpmlint warning
chmod +x %{buildroot}%{python3_sitelib}/%{modname}/*.py
chmod +x %{buildroot}%{python3_sitelib}/%{modname}/*/*.py
%files %files
%defattr(-,root,root,-) %defattr(-,root,root,-)
%doc README demos %doc README demos
%{python3_sitelib}/%{modname} %{python3_sitelib}/%{modname}
%{python3_sitelib}/%{modname}-%{version}-py%{py3_ver}.egg-info %{python3_sitelib}/%{modname}-%{version}-py%{py3_ver}.egg-info
%if 0%{?suse_version} <= 1140
%dir %{_prefix}/lib/python%{py3_ver}
%dir %{python3_sitelib}
%endif
%changelog %changelog