# # spec file for package python-Levenshtein # # Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to this # package are under the same license as the package itself. # # Please submit bugfixes or comments via http://bugs.opensuse.org/ # %define mod_name Levenshtein Name: python-%{mod_name} Version: 0.10.2 Release: 0 License: GPL-2.0+ Summary: Python extension computing string distances and similarities Url: http://github.com/miohtama/python-Levenshtein Group: Development/Libraries/Python Source0: python-%{mod_name}-%{version}.tar.bz2 BuildRequires: python-devel BuildRequires: python-distribute Requires: python-base >= %{py_ver} BuildRoot: %{_tmppath}/%{name}-%{version}-build %description The Levenshtein Python C extension module contains functions for fast computation of * Levenshtein (edit) distance, and edit operations * string similarity * approximate median strings, and generally string averaging * string sequence and set similarity It supports both normal and Unicode strings. %prep %setup -q -n "python-%{mod_name}-%{version}" %build python ./setup.py build %install python ./setup.py install \ --prefix="%{_prefix}" \ --root=%{buildroot} \ %clean [ -d %{buildroot} -a %{buildroot} != "" ] && rm -rf %{buildroot} %files %defattr(-,root,root) %doc COPYING HISTORY.txt PKG-INFO README.rst MANIFEST NEWS %python_sitearch/%{mod_name}.so %python_sitearch/python_%{mod_name}-%{version}-py%{py_ver}.egg-info %changelog