File python-cython.spec of Package python-cython
#
# spec file for package python-cython (Version 0.12.1)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: python-cython
%define _name Cython
Version: 0.12.1
Release: 1
License: Apache License
Summary: The Cython compiler for writing C extensions for the Python language
Url: http://www.cython.org
Group: Development/Libraries/Python
Source0: %{_name}-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel >= 2.5
%py_requires
%if 0%{?suse_version} <= 1110
%define python_sitelib %{py_sitedir}
%define python_sitearch %{py_sitedir}
%endif
%description
The Cython language makes writing C extensions for the Python language as
easy as Python itself. Cython is a source code translator based on the
well-known Pyrex, but supports more cutting edge functionality and
optimizations.
The Cython language is very close to the Python language (and most Python
code is also valid Cython code), but Cython additionally supports calling C
functions and declaring C types on variables and class attributes. This
allows the compiler to generate very efficient C code from Cython code.
This makes Cython the ideal language for writing glue code for external C
libraries, and for fast C modules that speed up the execution of Python
code.
%prep
%setup -n %{_name}-%{version}
%build
env CFLAGS="%{optflags}" python setup.py build
%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot} --record %{name}.files
%clean
rm -rf %{buildroot}
%files -f %{name}.files
%defattr(-,root,root)
%dir %{python_sitearch}/Cython
%dir %{python_sitearch}/Cython/Compiler
%dir %{python_sitearch}/Cython/Compiler/Tests
%dir %{python_sitearch}/Cython/Distutils
%dir %{python_sitearch}/Cython/Includes
%dir %{python_sitearch}/Cython/Plex
%dir %{python_sitearch}/Cython/Runtime
%dir %{python_sitearch}/Cython/Tests
%dir %{python_sitearch}/pyximport
%changelog