%global srcname maxminddb Name: python-%{srcname} Version: 1.2.0 Release: 1%{?dist} Summary: Reader for the MaxMind DB format License: BSD URL: http://pypi.python.org/pypi/%{srcname} Source0: http://pypi.python.org/packages/source/m/%{srcname}/%{srcname}-%{version}.tar.gz BuildArch: noarch BuildRequires: python2-devel BuildRequires: python3-devel %description This is a Python module for reading MaxMind DB files. The module includes both a pure Python reader and an optional C extension. %package -n python2-%{srcname} Summary: Reader for the MaxMind DB format %{?python_provide:%python_provide python2-%{srcname}} %description -n python2-%{srcname} This is a Python 2 module for reading MaxMind DB files. The module includes both a pure Python reader and an optional C extension. %package -n python3-%{srcname} Summary: Reader for the MaxMind DB format %{?python_provide:%python_provide python3-%{srcname}} %description -n python3-%{srcname} This is a Python 3 module for reading MaxMind DB files. The module includes both a pure Python reader and an optional C extension. %prep %autosetup -n %{srcname}-%{version} rm -rf %{name}.egg.info %build %py2_build %py3_build %install %py2_install %py3_install %check #Text fails due to missing C library than do not buil #in Fedora %files -n python2-%{srcname} %doc README.rst %{python2_sitearch}/* %files -n python3-%{srcname} %doc README.rst %{python3_sitearch}/* %changelog * Thu Oct 01 2015 Fedora - 1.2.0-1 - Initial Packaging