]> git.pld-linux.org Git - packages/python-Cython.git/blame_incremental - python-Cython.spec
- updated to 0.24
[packages/python-Cython.git] / python-Cython.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
5
6%define module Cython
7
8Summary: Language for writing Python Extension Modules (Python 2.x version)
9Summary(pl.UTF-8): Język służący do pisania modułów rozszerzających Pythona (wersja dla Pythona 2.x)
10Name: python-%{module}
11Version: 0.24
12Release: 1
13License: Apache v2.0
14Group: Libraries/Python
15Source0: http://cython.org/release/%{module}-%{version}.tar.gz
16# Source0-md5: 14fbc970f4a856845e633cbc09e61048
17URL: http://cython.org/
18BuildRequires: rpmbuild(macros) >= 1.710
19%if %{with python2}
20BuildRequires: python >= 1:2.6
21BuildRequires: python-devel >= 1:2.6
22BuildRequires: python-setuptools
23%endif
24%if %{with python3}
25BuildRequires: python3 >= 1:3.2
26BuildRequires: python3-2to3 >= 1:3.2
27BuildRequires: python3-devel >= 1:3.2
28BuildRequires: python3-modules >= 1:3.2
29BuildRequires: python3-setuptools
30%endif
31BuildRequires: rpm-pythonprov
32Requires: python-devel >= 1:2.6
33BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35%define _noautocompressdoc *.c
36
37%description
38Cython lets you write code that mixes Python and C data types any way
39you want, and compiles it into a C extension for Python. Cython is
40based on Pyrex.
41
42This package contains Cython module for Python 2.x.
43
44%description -l pl.UTF-8
45Cython pozwala pisać kod zawierający dane Pythona i języka C połączone
46w jakikolwiek sposób i kompiluje to jako rozszerzenie C dla Pythona.
47Cython jest oparty na Pyreksie.
48
49Ten pakiet zawiera moduł Cython dla Pythona 2.x.
50
51%package -n python3-Cython
52Summary: Language for writing Python Extension Modules (Python 3.x version)
53Summary(pl.UTF-8): Język służący do pisania modułów rozszerzających Pythona (wersja dla Pythona 3.x)
54Group: Libraries/Python
55Requires: python3-devel >= 1:3.2
56
57%description -n python3-Cython
58Cython lets you write code that mixes Python and C data types any way
59you want, and compiles it into a C extension for Python. Cython is
60based on Pyrex.
61
62This package contains Cython module for Python 3.x.
63
64%description -n python3-Cython -l pl.UTF-8
65Pyrex pozwala pisać kod zawierający dane Pythona i języka C połączone
66w jakikolwiek sposób i kompiluje to jako rozszerzenie C dla Pythona.
67Cython jest oparty na Pyreksie.
68
69Ten pakiet zawiera moduł Cython dla Pythona 3.x.
70
71%package examples
72Summary: Examples for Cython language
73Summary(pl.UTF-8): Przykłady programów w języku Cython
74Group: Libraries/Python
75Obsoletes: python3-Cython-examples
76
77%description examples
78This package contains example programs for Cython language.
79
80%description examples -l pl.UTF-8
81Pakiet zawierający przykładowe programy napisane w języku Cython.
82
83%prep
84%setup -q -n %{module}-%{version}
85
86%build
87%if %{with python2}
88%py_build
89%endif
90
91%if %{with python3}
92%py3_build
93%endif
94
95%install
96rm -rf $RPM_BUILD_ROOT
97install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
98
99%if %{with python3}
100%py3_install
101
102%{__mv} $RPM_BUILD_ROOT%{_bindir}/cython{,3}
103%{__mv} $RPM_BUILD_ROOT%{_bindir}/cythonize{,3}
104%{__mv} $RPM_BUILD_ROOT%{_bindir}/cygdb{,3}
105%endif
106
107%if %{with python2}
108%py_install
109
110find $RPM_BUILD_ROOT%{py_sitedir} -name "*.py" -a ! -name 'Lexicon.py' -exec rm -f {} \;
111%endif
112
113cp -a Demos/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
114
115%clean
116rm -rf $RPM_BUILD_ROOT
117
118%if %{with python2}
119%files
120%defattr(644,root,root,755)
121%doc COPYING.txt README.txt ToDo.txt USAGE.txt Doc/*.html Doc/*.c
122%attr(755,root,root) %{_bindir}/cython
123%attr(755,root,root) %{_bindir}/cythonize
124%attr(755,root,root) %{_bindir}/cygdb
125%{py_sitedir}/cython.py[co]
126%{py_sitedir}/Cython
127%{py_sitedir}/pyximport
128%{py_sitedir}/Cython-%{version}-py*.egg-info
129%endif
130
131%if %{with python3}
132%files -n python3-Cython
133%defattr(644,root,root,755)
134%doc COPYING.txt README.txt ToDo.txt USAGE.txt Doc/*.html Doc/*.c
135%attr(755,root,root) %{_bindir}/cython3
136%attr(755,root,root) %{_bindir}/cythonize3
137%attr(755,root,root) %{_bindir}/cygdb3
138%{py3_sitedir}/cython.py
139%{py3_sitedir}/__pycache__/cython.*
140%{py3_sitedir}/Cython
141%{py3_sitedir}/pyximport
142%{py3_sitedir}/Cython-%{version}-py*.egg-info
143%endif
144
145%files examples
146%defattr(644,root,root,755)
147%{_examplesdir}/%{name}-%{version}
This page took 0.055144 seconds and 4 git commands to generate.