New specfile approved for Fedora
This commit is contained in:
parent
c92a340f88
commit
917278b568
1 changed files with 56 additions and 122 deletions
|
@ -1,149 +1,83 @@
|
||||||
%define srcname feedgen
|
%global pypi_name feedgen
|
||||||
|
|
||||||
Name: python-%{srcname}
|
Name: python-%{pypi_name}
|
||||||
Version: 0.6.1
|
Version: 0.6.1
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: Feed Generator (ATOM, RSS, Podcasts)
|
Summary: Feed Generator (ATOM, RSS, Podcasts)
|
||||||
|
|
||||||
Group: Development/Libraries
|
License: BSD or LGPLv3
|
||||||
License: LGPLv3+ or BSD
|
URL: http://lkiesow.github.io/python-feedgen
|
||||||
URL: http://lkiesow.github.io/%{name}/
|
Source0: https://github.com/lkiesow/%{name}/archive/v%{version}.tar.gz
|
||||||
|
|
||||||
Source0: https://pypi.python.org/packages/source/f/%{srcname}/%{srcname}-%{version}.tar.gz
|
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
||||||
|
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
|
BuildRequires: python2-dateutil
|
||||||
BuildRequires: python2-devel
|
BuildRequires: python2-devel
|
||||||
BuildRequires: python-setuptools
|
BuildRequires: python2-lxml
|
||||||
|
BuildRequires: python2-setuptools
|
||||||
|
|
||||||
|
BuildRequires: python3-dateutil
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
|
BuildRequires: python3-lxml
|
||||||
BuildRequires: python3-setuptools
|
BuildRequires: python3-setuptools
|
||||||
|
|
||||||
Requires: python-lxml
|
|
||||||
Requires: python-dateutil
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
This module can be used to generate web feeds in both ATOM and RSS format. It
|
Feedgenerator This module can be used to generate web feeds in both ATOM and
|
||||||
has support for extensions. Included is for example an extension to produce
|
RSS format. It has support for extensions. Included is for example an extension
|
||||||
Podcasts.
|
to produce Podcasts.
|
||||||
|
|
||||||
|
%package -n python2-%{pypi_name}
|
||||||
|
Summary: %{summary}
|
||||||
|
%{?python_provide:%python_provide python2-%{pypi_name}}
|
||||||
|
|
||||||
%package -n python3-%{srcname}
|
Requires: python2-dateutil
|
||||||
Summary: Feed Generator (ATOM, RSS, Podcasts)
|
Requires: python2-lxml
|
||||||
Group: Development/Libraries
|
%description -n python2-%{pypi_name}
|
||||||
|
Feedgenerator This module can be used to generate web feeds in both ATOM and
|
||||||
|
RSS format. It has support for extensions. Included is for example an extension
|
||||||
|
to produce Podcasts.
|
||||||
|
|
||||||
|
%package -n python3-%{pypi_name}
|
||||||
|
Summary: %{summary}
|
||||||
|
%{?python_provide:%python_provide python3-%{pypi_name}}
|
||||||
|
|
||||||
Requires: python3-lxml
|
|
||||||
Requires: python3-dateutil
|
Requires: python3-dateutil
|
||||||
|
Requires: python3-lxml
|
||||||
%description -n python3-%{srcname}
|
%description -n python3-%{pypi_name}
|
||||||
This module can be used to generate web feeds in both ATOM and RSS format. It
|
Feedgenerator This module can be used to generate web feeds in both ATOM and
|
||||||
has support for extensions. Included is for example an extension to produce
|
RSS format. It has support for extensions. Included is for example an extension
|
||||||
Podcasts.
|
to produce Podcasts.
|
||||||
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{srcname}-%{version}
|
%autosetup
|
||||||
mkdir python2
|
# Remove bundled egg-info
|
||||||
mv PKG-INFO docs feedgen license.bsd license.lgpl readme.rst setup.py python2
|
rm -rf %{pypi_name}.egg-info
|
||||||
cp -r python2 python3
|
|
||||||
|
|
||||||
# ensure the right python version is used
|
|
||||||
find python3 -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python3}|'
|
|
||||||
find python2 -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python2}|'
|
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
pushd python2
|
%py2_build
|
||||||
%{__python2} setup.py build
|
%py3_build
|
||||||
popd
|
|
||||||
pushd python3
|
|
||||||
%{__python3} setup.py build
|
|
||||||
popd
|
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
rm -rf $RPM_BUILD_ROOT
|
%py2_install
|
||||||
pushd python3
|
%py3_install
|
||||||
%{__python3} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
|
||||||
popd
|
|
||||||
pushd python2
|
|
||||||
%{__python2} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
|
||||||
popd
|
|
||||||
chmod 644 $RPM_BUILD_ROOT%{python3_sitelib}/%{srcname}/*.py
|
|
||||||
chmod 644 $RPM_BUILD_ROOT%{python2_sitelib}/%{srcname}/*.py
|
|
||||||
|
|
||||||
|
|
||||||
%clean
|
%check
|
||||||
rm -rf $RPM_BUILD_ROOT
|
%{__python2} setup.py test
|
||||||
|
%{__python3} setup.py test
|
||||||
|
|
||||||
|
%files -n python2-%{pypi_name}
|
||||||
|
%license license.lgpl license.bsd
|
||||||
|
%doc readme.rst
|
||||||
|
%{python2_sitelib}/%{pypi_name}
|
||||||
|
%{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
|
||||||
|
|
||||||
%files
|
%files -n python3-%{pypi_name}
|
||||||
%defattr(-,root,root,-)
|
%license license.lgpl license.bsd
|
||||||
%license python2/license.*
|
%doc readme.rst
|
||||||
%doc python2/docs/*
|
%{python3_sitelib}/%{pypi_name}
|
||||||
%{python2_sitelib}/*
|
%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
|
||||||
|
|
||||||
|
|
||||||
%files -n python3-%{srcname}
|
|
||||||
%defattr(-,root,root,-)
|
|
||||||
%license python3/license.*
|
|
||||||
%doc python3/docs/*
|
|
||||||
%{python3_sitelib}/*
|
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Sat Oct 14 2017 Lars Kiesow <lkiesow@uos.de> - 0.6.1-1
|
* Tue Oct 24 2017 Lumir Balhar <lbalhar@redhat.com> - 0.6.1-1
|
||||||
- Update to 0.6.1
|
- Initial package.
|
||||||
|
|
||||||
* Sat Oct 14 2017 Lars Kiesow <lkiesow@uos.de> - 0.6.0-1
|
|
||||||
- Update to 0.6.0
|
|
||||||
|
|
||||||
* Thu Jan 05 2017 Lars Kiesow <lkiesow@uos.de> - 0.5.1-1
|
|
||||||
- Update to 0.5.1
|
|
||||||
|
|
||||||
* Thu Jan 05 2017 Lars Kiesow <lkiesow@uos.de> - 0.5.0-1
|
|
||||||
- Update to 0.5.0
|
|
||||||
|
|
||||||
* Thu Jan 05 2017 Lars Kiesow <lkiesow@uos.de> - 0.4.1-1
|
|
||||||
- Update to 0.4.1
|
|
||||||
|
|
||||||
* Sun Sep 04 2016 Lars Kiesow <lkiesow@uos.de> - 0.4.0-1
|
|
||||||
- Update to 0.4.0
|
|
||||||
|
|
||||||
* Thu Oct 29 2015 Lars Kiesow <lkiesow@uos.de> - 0.3.2-1
|
|
||||||
- Update to 0.3.2
|
|
||||||
|
|
||||||
* Mon May 4 2015 Lars Kiesow <lkiesow@uos.de> - 0.3.1-2
|
|
||||||
- Building for Python 3 as well
|
|
||||||
|
|
||||||
* Fri Jan 16 2015 Lars Kiesow <lkiesow@uos.de> - 0.3.1-1
|
|
||||||
- Update to 0.3.1
|
|
||||||
|
|
||||||
* Sun Jul 20 2014 Lars Kiesow <lkiesow@uos.de> - 0.3.0-1
|
|
||||||
- Update to 0.3
|
|
||||||
|
|
||||||
* Wed Jan 1 2014 Lars Kiesow <lkiesow@uos.de> - 0.2.8-1
|
|
||||||
- Update to 0.2.8
|
|
||||||
|
|
||||||
|
|
||||||
* Wed Jan 1 2014 Lars Kiesow <lkiesow@uos.de> - 0.2.7-1
|
|
||||||
- Update to 0.2.7
|
|
||||||
|
|
||||||
* Mon Sep 23 2013 Lars Kiesow <lkiesow@uos.de> - 0.2.6-1
|
|
||||||
- Update to 0.2.6
|
|
||||||
|
|
||||||
* Mon Jul 22 2013 Lars Kiesow <lkiesow@uos.de> - 0.2.5-1
|
|
||||||
- Updated to 0.2.5-1
|
|
||||||
|
|
||||||
* Thu May 16 2013 Lars Kiesow <lkiesow@uos.de> - 0.2.4-1
|
|
||||||
- Update to 0.2.4
|
|
||||||
|
|
||||||
* Tue May 14 2013 Lars Kiesow <lkiesow@uos.de> - 0.2.3-1
|
|
||||||
- Update to 0.2.3
|
|
||||||
|
|
||||||
* Sun May 5 2013 Lars Kiesow <lkiesow@uos.de> - 0.2.2-1
|
|
||||||
- Update to version 0.2.2
|
|
||||||
|
|
||||||
* Sat May 4 2013 Lars Kiesow <lkiesow@uos.de> - 0.1-1
|
|
||||||
- Initial build
|
|
||||||
|
|
Loading…
Reference in a new issue