]> git.pld-linux.org Git - packages/python.git/blob - python.spec
- uname -m instead of target_cpu
[packages/python.git] / python.spec
1 #
2 # TODO
3 # - test_distutils fails for unknown reason: (does it still do with new lib64 patch?)
4 #   AssertionError: '/tmp/tmpaomC0l/installation/share/python' != '/tmp/tmpaomC0l/installation/lib/python'
5 # - test_pydoc fails because of PYTHONPATH override
6 # - test_zlib fails with zlib 1.2.4 - recheck with newer python
7 # - change searchpath order so /usr/lib* is before /usr/share
8 # - kill lib-tk from searchpath
9 # - kill BR: file requirement from lib64 patch
10 # - security(CVE-2008-4108)
11 #   http://securitytracker.com/alerts/2008/Sep/1020904.html
12 #
13 # Conditional build:
14 %bcond_with     info                    # build info pages (requires emacs, fails in python-2.5.0)
15 %bcond_without  tkinter                 # disables tkinter module building
16 %bcond_without  tests                   # disables Python testing
17 %bcond_with     verbose_tests           # runs tests in verbose mode
18 %bcond_with     openssl097
19 #
20 # tests which will not work on 64-bit platforms
21 %define         no64bit_tests   test_audioop test_rgbimg test_imageop
22 # tests which may fail because of builder environment limitations (no /proc or /dev/pts)
23 %define         nobuilder_tests test_resource test_openpty test_socket test_nis test_posix test_locale test_pty test_urllib2
24 # tests which fail because of some unknown/unresolved reason (this list should be empty)
25 %define         broken_tests test_anydbm test_bsddb test_re test_shelve test_whichdb test_zipimport test_distutils test_pydoc test_zlib test_file test_file2k
26
27 %define beta            %{nil}
28
29 %define py_ver          2.7
30 %define py_prefix       %{_prefix}
31 %define py_libdir       %{py_prefix}/%{_lib}/python%{py_ver}
32 %define py_incdir       %{_includedir}/python%{py_ver}
33 %define py_sitedir      %{py_libdir}/site-packages
34 %define py_dyndir       %{py_libdir}/lib-dynload
35
36 %define dver %{version}
37 Summary:        Very high level scripting language with X interface
38 Summary(es.UTF-8):      Lenguaje script de alto nivel con interfaz X
39 Summary(fr.UTF-8):      Langage de script de très haut niveau avec interface X
40 Summary(pl.UTF-8):      Python - język obiektowy wysokiego poziomu
41 Summary(pt_BR.UTF-8):   Linguagem de programação interpretada de alto nível
42 Summary(ru.UTF-8):      Язык программирования очень высокого уровня с X-интерфейсом
43 Summary(tr.UTF-8):      X arayüzlü, yüksek düzeyli, kabuk yorumlayıcı dili
44 Summary(uk.UTF-8):      Мова програмування дуже високого рівня з X-інтерфейсом
45 Name:           python
46 Version:        %{py_ver}
47 Release:        2
48 Epoch:          1
49 License:        PSF
50 Group:          Development/Languages/Python
51 Source0:        http://www.python.org/ftp/python/%{version}/Python-%{version}%{beta}.tar.bz2
52 # Source0-md5:  0e8c9ec32abf5b732bea7d91b38c3339
53 Source1:        http://www.python.org/ftp/python/doc/%{dver}/%{name}-%{dver}-docs-html.tar.bz2
54 # Source1-md5:  16b736789e923bbefe74e7a2219031c6
55 Patch1:         %{name}-%{name}path.patch
56 Patch2:         %{name}-ac_fixes.patch
57 Patch3:         %{name}-lib64.patch
58 Patch4:         %{name}-noarch_to_datadir.patch
59 Patch5:         %{name}-verbose.patch
60 URL:            http://www.python.org/
61 BuildRequires:  autoconf >= 2.61
62 BuildRequires:  bluez-libs-devel
63 BuildRequires:  bzip2-devel
64 BuildRequires:  db-devel >= 4
65 %{?with_info:BuildRequires:     emacs >= 21}
66 BuildRequires:  expat-devel >= 1:1.95.7
67 BuildRequires:  file
68 BuildRequires:  gdbm-devel >= 1.8.3
69 BuildRequires:  gmp-devel >= 4.0
70 BuildRequires:  libffi-devel
71 BuildRequires:  libstdc++-devel
72 BuildRequires:  ncurses-ext-devel >= 5.2
73 %if %{with openssl097}
74 BuildRequires:  openssl-devel < 0.9.8
75 %else
76 BuildRequires:  openssl-devel >= 0.9.8
77 %endif
78 BuildRequires:  readline-devel >= 5.0
79 BuildRequires:  rpm-pythonprov
80 BuildRequires:  sed >= 4.0
81 BuildRequires:  sqlite3-devel >= 3.3.5
82 %{?with_info:BuildRequires:     tetex-makeindex}
83 %{?with_tkinter:BuildRequires:  tix-devel >= 1:8.1.4-4}
84 %{?with_tkinter:BuildRequires:  tk-devel >= 8.4.3}
85 BuildRequires:  zlib-devel
86 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
87 Obsoletes:      python2
88 Conflicts:      bzr < 1.8
89 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
90
91 %if %{with verbose_tests}
92 %define test_flags -v -l -x
93 %else
94 %define test_flags -w -l -x
95 %endif
96
97 %ifarch alpha ia64 ppc64 ppc64 %{x8664}
98 %define test_list %{nobuilder_tests} %{broken_tests} %{no64bit_tests}
99 %else
100 %define test_list %{nobuilder_tests} %{broken_tests}
101 %endif
102
103 %ifarch sparc sparcv9
104 %define test_list %{nobuilder_tests} %{broken_tests} test_fcntl test_ioctl
105 %endif
106
107 %ifarch sparc64
108 %define test_list %{nobuilder_tests} %{broken_tests} %{no64bit_tests} test_fcntl test_ioctl
109 %endif
110
111 %description
112 Python is an interpreted, interactive, object-oriented programming
113 language. It incorporates modules, exceptions, dynamic typing, very
114 high level dynamic data types, and classes. Python combines remarkable
115 power with very clear syntax. It has interfaces to many system calls
116 and libraries, as well as to various window systems, and is extensible
117 in C or C++. It is also usable as an extension language for
118 applications that need a programmable interface. Finally, Python is
119 portable: it runs on many brands of UNIX, on the Mac, and on PCs under
120 MS-DOS, Windows, Windows NT, and OS/2.
121
122 This package contains the Python binary.
123
124 %description -l de.UTF-8
125 Python ist eine interpretierte, interaktive, objektorientierte
126 Programmiersprache, vergleichbar zu Tcl, Perl, Scheme oder Java.
127 Python enthält Module, Klassen, Exceptions, High-Level dynamische
128 Datentypen und dynamisches Typisieren. Python unterstützt Interfaces
129 zu vielen Systemaufrufen und Libraries, sowie verschiedene
130 Fenstersysteme (X11, Motif, Tk, Mac und MFC)
131
132 Programmierer können neue built-in-Module für Python in C oder C++
133 schreiben. Python kann auch als Erweiterungssprache für Applikationen
134 benutzt werden, die ein programmierbares Interface brauchen. Dieses
135 Paket enthält die meisten Standard-Python-Module, und Module zum
136 Ansprechen von Tix (Tk-widget set) und RPM.
137
138 %description -l es.UTF-8
139 Python es un lenguaje de scripts interpretado orientado a objetos.
140 Contiene soporte para carga dinámica de objetos, clases, módulos y
141 excepciones.
142
143 Es sencillo adicionar interfaces para nuevos sistemas de biblioteca a
144 través de código C, tornando Python fácil de usar en ambientes
145 particulares/personalizados. Este paquete Python incluye la mayoría de
146 los módulos padrón Python, junto con módulos para crear interfaces
147 para el conjunto de componentes Tix para Tk y RPM.
148
149 %description -l fr.UTF-8
150 Python est un langage de script interprété et orienté objet. Il gère
151 le chargement dynamique des objets, les classes, les modules et les
152 exceptions. L'ajout d'interfaces aux nouvelles bibliothèques systèmes
153 avec du code C est simple, ce qui rend Python facile à utiliser dans
154 des configs personnalisées.
155
156 Ce paquetage Python contient la plupart des modules Python standards,
157 ainsi que ceux permettant l'interfaçage avec les widgets Tix pour Tk
158 et RPM.
159
160 %description -l pl.UTF-8
161 Python jest interpretowanym, interaktywnym i zorientowanym obiektowo
162 językiem programowania. Jest modularny, obsługuje wyjątki, dynamiczne
163 typy, zaawansowane dynamiczne struktury danych i klasy. Python łączy w
164 sobie duże możliwości i przejrzystą składnię. Posiada interfejsy do
165 wielu wywołań systemowych i bibliotek, w tym również do różnych
166 bibliotek okienkowych. Możliwości jego można jeszcze rozszerzać
167 poprzez odpowiednie moduły pisane w C lub C++. Python może być również
168 użyty jako element aplikacji, którym potrzebny jest interpreter do
169 skryptów. I wreszcie, Python jest wieloplatformowy, działa na wielu
170 odmianach UNIX-a, Macu oraz PC pod DOS-em, Windows, WindowsNT oraz
171 OS/2.
172
173 Ten pakiet zawiera binarkę Pythona.
174
175 %description -l pt_BR.UTF-8
176 Python é uma linguagem de scripts interpretada orientada a objetos.
177 Contém suporte para carga dinâmica de objetos, classes, módulos e
178 exceções. Adicionar interfaces para novos sistemas de biblioteca
179 através de código C é simples, tornando Python fácil de usar em
180 ambientes particulares/personalizados.
181
182 Este pacote Python inclui a maioria do módulos padrão Python, junto
183 com módulos para interfaceamento para o conjunto de componentes Tix
184 para Tk e RPM.
185
186 %description -l ru.UTF-8
187 Python - это интерпретируемый, объектно-ориентированный язык
188 программирования. Он поддерживает динамическую загрузку объектов,
189 классы, модули и обработку исключительных ситуаций (exceptions).
190 Простота добавления интерфейсов к новым системным библиотекам через
191 код на языке C делает Python хорошим выбором для использования в
192 специальных конфигурациях.
193
194 %description -l tr.UTF-8
195 Python, nesneye yönelik bir kabuk yorumlayıcıdır. Nesnelerin,
196 sınıfların, modüllerin ve aykırı durumların dinamik yüklenmelerine
197 destek verir. C koduyla birlikte kullanımı son derece kolaydır. Bu
198 paket, standart Python birimlerinin çoğunun yanısıra Tk ve RPM için
199 arayüz birimlerini de içerir.
200
201 %description -l uk.UTF-8
202 Python - це інтерпретована, об'єктно-орієнтована мова програмування.
203 Він підтримує динамічну загрузку об'єктів, класи, модулі та обробку
204 виключних ситуацій (exceptions). Простота додавання інтерфейсів для
205 нових системних бібліотек через код на мові C робить Python добрим
206 вибором для використання в спеціальних конфігураціях.
207
208 %package libs
209 Summary:        Python library
210 Summary(pl.UTF-8):      Biblioteka języka Python
211 Group:          Libraries/Python
212 # broken detection in rpm/pythondeps.sh
213 Provides:       python(abi) = %{py_ver}
214 # for compatibility with existing Ac packages
215 Provides:       python(bytecode) = %{py_ver}
216 %{!?with_info:Obsoletes:        python-doc-info}
217 Obsoletes:      python-intl
218
219 %description libs
220 Python shared library and very essental modules for Python binary.
221
222 %description libs -l pl.UTF-8
223 Biblioteka współdzielona języka Python oraz bardzo podstawowe moduły
224 dla Pythona.
225
226 %package modules
227 Summary:        Python modules
228 Summary(pl.UTF-8):      Moduły języka Python
229 Group:          Libraries/Python
230 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
231 Provides:       python-cElementTree
232 Provides:       python-elementtree
233 Obsoletes:      python-cElementTree
234 Obsoletes:      python-ctypes
235 Obsoletes:      python-curses
236 Obsoletes:      python-elementtree
237 Obsoletes:      python-gdbm
238 Obsoletes:      python-hashlib
239 Obsoletes:      python-logging
240 Obsoletes:      python-old
241 Obsoletes:      python-optik
242 Obsoletes:      python-ssl
243 Obsoletes:      python-xml
244 Obsoletes:      python-xmlrpc <= 1.0.1
245 Obsoletes:      python-zlib
246
247 %description modules
248 Python officially distributed modules.
249
250 %description modules -l pl.UTF-8
251 Oficjalnie rozprowadzane moduły języka Python.
252
253 %package modules-sqlite
254 Summary:        Python SQLite modules
255 Summary(pl.UTF-8):      Moduły SQLite języka Python
256 Group:          Libraries/Python
257 Requires:       %{name}-modules = %{epoch}:%{version}-%{release}
258 Provides:       python(sqlite)
259
260 %description modules-sqlite
261 Python officially distributed sqlite module.
262
263 %description modules-sqlite -l pl.UTF-8
264 Oficjalnie rozprowadzany moduł sqlite języka Python.
265
266 %package -n pydoc
267 Summary:        Python interactive module documentation access support
268 Summary(pl.UTF-8):      Interaktywne korzystanie z dokumentacji modułów języka Python
269 Group:          Applications
270 Requires:       %{name}-modules = %{epoch}:%{version}-%{release}
271 Obsoletes:      python-pydoc
272
273 %description -n pydoc
274 Python interactive module documentation access support.
275
276 %description -n pydoc -l pl.UTF-8
277 Interaktywne korzystanie z dokumentacji modułów języka Python.
278
279 %package -n idle
280 Summary:        IDE for Python language
281 Summary(pl.UTF-8):      IDE dla języka Python
282 Group:          Applications/Editors
283 Requires:       %{name}-tkinter = %{epoch}:%{version}-%{release}
284 Obsoletes:      python-idle
285
286 %description -n idle
287 IDE for Python language.
288
289 %description -n idle -l pl.UTF-8
290 IDE dla języka Python.
291
292 %package devel
293 Summary:        Libraries and header files for building python code
294 Summary(de.UTF-8):      Libraries und Header-Dateien zum Erstellen von Python-Code
295 Summary(es.UTF-8):      Bibliotecas y archivos de inclusión para construir programas en python
296 Summary(fr.UTF-8):      Bibliothèques et en-têtes pour construire du code python
297 Summary(pl.UTF-8):      Pliki nagłówkowe i biblioteki Pythona
298 Summary(pt_BR.UTF-8):   Bibliotecas e arquivos de inclusão para o Python
299 Summary(ru.UTF-8):      Библиотеки и хедеры для построения кода на языке Python
300 Summary(tr.UTF-8):      Python ile geliştirme yapmak için gerekli dosyalar
301 Summary(uk.UTF-8):      Бібліотеки та хедери для програмування на мові Python
302 Group:          Development/Languages/Python
303 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
304 Obsoletes:      python2-devel
305
306 %description devel
307 The Python interpreter is relatively easy to extend with dynamically
308 loaded extensions and to embed in other programs. This package
309 contains the header files and libraries which are needed to do both of
310 these tasks.
311
312 %description devel -l de.UTF-8
313 Der Python-Interpretierer ist relativ einfach anhand von dynamisch
314 ladbaren Erweiterungen auszubauen und läßt sich in andere Programme
315 integrieren. Dieses Paket enthält die Header-Dateien und Libraries,
316 die für beide Aufgaben erforderlich sind.
317
318 %description devel -l es.UTF-8
319 El interpretador Python permite incluir con facilidad extensiones
320 cargadas dinámicamente. Python es también fácil de ser empotrado en
321 otros programas. Este paquete contiene los archivos de inclusión y
322 bibliotecas necesarios para estas dos tareas.
323
324 %description devel -l fr.UTF-8
325 L'interpréteur Python est relativement facile à étendre avec des
326 extensions chargées dynamiquement et à insérer dans d'autres
327 programmes. Ce paquetage contient les en-têtes et les bibliothèques
328 nécessaires à ces deux tâches.
329
330 %description devel -l pl.UTF-8
331 Interpreter Pythona jest w miarę łatwy do rozszerzania przy pomocy
332 dynamicznie ładowanych rozszerzeń napisanych w C lub C++ oraz
333 osadzania w innych programach. Ten pakiet zawiera pliki nagłówkowe i
334 wszystko inne co potrzebne do tych celów.
335
336 %description devel -l pt_BR.UTF-8
337 O interpretador Python permite incluir com facilidade extensões
338 carregadas dinamicamente. Python é também fácil de ser embutido em
339 outros programas. Este pacote contém os arquivos de inclusão e
340 bibliotecas necessários para estas duas tarefas.
341
342 %description devel -l ru.UTF-8
343 Интерпретатор Python относительно легко расширяется при помощи
344 динамически загружаемых расширений и встраивается в другие программы.
345 Этот пакет содержит хедеры и библиотеки, необходимые для обеих этих
346 задач.
347
348 %description devel -l tr.UTF-8
349 Bu paket, Python ile geliştirme yapılabilmesi için gerekli başlık
350 dosyalarını ve kitaplıkları içerir.
351
352 %description devel -l uk.UTF-8
353 Інтерпретатор Python відносно легко розширюється за допомогою
354 розширень з динамічною загрузкою та вбудовується в інші програми. Цей
355 пакет містить хедери та бібліотеки, необхідні для обох цих задач.
356
357 %package devel-src
358 Summary:        Python module sources
359 Summary(pl.UTF-8):      Pliki źródłowe modułów Pythona
360 Group:          Development/Languages/Python
361 Requires:       %{name}-modules = %{epoch}:%{version}-%{release}
362
363 %description devel-src
364 Python module sources.
365
366 %description devel-src -l pl.UTF-8
367 Pliki źródłowe modułów Pythona.
368
369 %package devel-tools
370 Summary:        Python development tools
371 Summary(pl.UTF-8):      Narzędzia programistyczne języka Python
372 Group:          Development/Languages/Python
373 Requires:       %{name}-modules = %{epoch}:%{version}-%{release}
374
375 %description devel-tools
376 Python development tools such as profilers and debugger.
377
378 %description devel-tools -l pl.UTF-8
379 Narzędzia programistyczne języka Python takie jak profiler oraz
380 debugger.
381
382 %package 2to3
383 Summary:        Automated Python 2 to 3 code translation
384 Summary(pl.UTF-8):      Automatyczne tłumaczenie kodu Pythona 2 na 3
385 Group:          Development/Languages/Python
386
387 %description 2to3
388 2to3 is a Python program that reads Python 2.x source code and applies
389 a series of fixers to transform it into valid Python 3.x code. The
390 standard library contains a rich set of fixers that will handle almost
391 all code. 2to3 supporting library lib2to3 is, however, a flexible and
392 generic library, so it is possible to write your own fixers for 2to3.
393 lib2to3 could also be adapted to custom applications in which Python
394 code needs to be edited automatically.
395
396 %description 2to3 -l pl.UTF-8
397 2to3 to program w Pythonie czytający od źródłowy w Pythonie 2.x i
398 aplikujący serię poprawek przekształcających go w poprawny kod w
399 Pythonie 3.x. Biblioteka standardowa zawiera duży zbiór poprawek
400 obsługujących większość kodu. Biblioteka wspierająca 2to3 (lib2to3)
401 jest jednak elastyczną i ogólną biblioteką, więc można pisać własne
402 poprawki dla 2to3. lib2to3 można także zaadaptować na potrzeby
403 własnych zastosowań, w których kod w Pythonie musi być modyfikowany
404 automatycznie.
405
406 %package static
407 Summary:        Static python library
408 Summary(pl.UTF-8):      Statyczna biblioteka Pythona
409 Group:          Development/Languages/Python
410 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
411
412 %description static
413 Static python library.
414
415 %description static -l pl.UTF-8
416 Statyczna biblioteka Pythona.
417
418 %package doc
419 Summary:        Documentation on Python
420 Summary(de.UTF-8):      Dokumentation zu Python
421 Summary(es.UTF-8):      Documentación para Python
422 Summary(fr.UTF-8):      Documentation sur Python
423 Summary(pl.UTF-8):      Dokumentacja do Pythona
424 Summary(pt_BR.UTF-8):   Documentação para a linguagem de programação Python
425 Summary(ru.UTF-8):      Документация по языку Python
426 Summary(tr.UTF-8):      Python belgeleri
427 Summary(uk.UTF-8):      Документація по мові Python
428 Group:          Documentation
429 Obsoletes:      python-docs
430
431 %description doc
432 This package contains documentation on the Python language and
433 interpretor as a mix of plain ASCII files and LaTeX sources.
434
435 %description doc -l de.UTF-8
436 Dieses Paket enthält Dokumentationen zu Python (Sprache und
437 Interpreter) in Form von einfachen ASCII-Dateien und LaTeX-Quellen.
438
439 %description doc -l es.UTF-8
440 Documentación para Python. Contiene archivos en texto y PostScript.
441
442 %description doc -l fr.UTF-8
443 Ce paquetage contient la documentation sur le langage python et sur
444 son interpréteur sous forme de fichiers ASCII et LaTeX.
445
446 %description doc -l pl.UTF-8
447 Oficjalna dokumentacja do Pythona. Zawiera przykładowe programy,
448 narzędzia i dokumentację. Strony podręcznika man znajdują się w
449 głównym pakiecie. Ten pakiet nie zawiera źródeł dokumentacji
450 napisanych w LaTeXu, tylko gotowe do wykorzystania pliki postscriptowe
451 i HTML.
452
453 %description doc -l pt_BR.UTF-8
454 O pacote python-doc contém documentação para a linguagem de
455 programação e para o interpretador Python. Fornecida em arquivos texto
456 e Postcript.
457
458 %description doc -l ru.UTF-8
459 Этот пакет содержит документацию по собственно языку Python и по
460 исполняющему его интерпретатору в виде набора текстовых файлов и
461 исходных текстов в формате LaTeX.
462
463 %description doc -l tr.UTF-8
464 Bu paket, Python dili ile ilgili belgeleri ve düz ASCII dosyaları ve
465 LaTeX kaynaklarının bir karışımı olan yorumlayıcıyı içerir.
466
467 %description doc -l uk.UTF-8
468 Цей пакет містить документацію по власне мові Python та по виконуючому
469 її інтерпретатору у вигляді набора текстових файлів та вихідних
470 текстів у форматі LaTeX.
471
472 %package doc-info
473 Summary:        Documentation on Python in texinfo format
474 Summary(pl.UTF-8):      Dokumentacja do Pythona w formacie texinfo
475 Group:          Documentation
476
477 %description doc-info
478 Documentation on Python in texinfo format.
479
480 %description doc-info -l pl.UTF-8
481 Dokumentacja do Pythona w formacie texinfo.
482
483 %package tkinter
484 Summary:        Standard Python interface to the Tk GUI toolkit
485 Summary(de.UTF-8):      Grafische Tk-Schnittstelle für Python
486 Summary(es.UTF-8):      Interfaz de GUI Tk para Python
487 Summary(fr.UTF-8):      Interface graphique Tk pour Python
488 Summary(pl.UTF-8):      Standardowy interfejs Pythona do biblioteki Tk
489 Summary(pt_BR.UTF-8):   Interface GUI Tk para Phyton
490 Summary(tr.UTF-8):      Python için grafik kullanıcı arayüzü
491 Group:          Libraries/Python
492 Requires:       %{name}-modules = %{epoch}:%{version}-%{release}
493 Requires:       tcl >= 8.4.3
494 Requires:       tix >= 1:8.1.4-4
495 Requires:       tk >= 8.4.3
496 Obsoletes:      tkinter
497
498 %description tkinter
499 Standard Python interface to the Tk GUI toolkit.
500
501 %description tkinter -l de.UTF-8
502 Eine grafische Schnittstelle für Python, basierend auf Tcl/Tk, und von
503 vielen Konfigurations-Tools genutzt.
504
505 %description tkinter -l es.UTF-8
506 Una interfaz gráfica para Python, basada en Tcl/Tk, y usada por muchas
507 herramientas de configuración.
508
509 %description tkinter -l fr.UTF-8
510 Interface graphique pour Python, basée sur Tcl/Tk et utilisée par
511 beaucoup des outils de configuration.
512
513 %description tkinter -l pl.UTF-8
514 Standardowy interfejs Pythona do biblioteki Tk.
515
516 %description tkinter -l pt_BR.UTF-8
517 Uma interface gráfica para Python, baseada em Tcl/Tk, e usada por
518 muitas ferramentas de configuração.
519
520 %description tkinter -l ru.UTF-8
521 Графический интерфейс (GUI) для Python, построенный на Tcl/Tk.
522
523 %description tkinter -l tr.UTF-8
524 Python için Tcl/Tk'ye dayalı ve pek çok ayarlama aracı tarafından
525 kullanılan grafik bir arayüzdür.
526
527 %description tkinter -l uk.UTF-8
528 Графічний інтерфейс (GUI) для Python, побудований на Tcl/Tk.
529
530 %package examples
531 Summary:        Example programs in Python
532 Summary(pl.UTF-8):      Przykładowe programy w Pythonie
533 Group:          Development/Languages/Python
534 Obsoletes:      python-tools
535
536 %description examples
537 Example programs in Python.
538
539 These are for Python 2.3.4, not %{version}.
540
541 %description examples -l pl.UTF-8
542 Przykładowe programy w Pythonie.
543
544 Przykłady te są dla Pythona 2.3.4, nie %{version}.
545
546 %prep
547 %setup -q -n Python-%{version}%{beta}
548 %patch1 -p1
549 %patch2 -p1
550 %patch3 -p1
551 %patch4 -p1
552 %patch5 -p1
553
554 tar xjf %{SOURCE1}
555
556 sed -i -e 's#db_setup_debug = False#db_setup_debug = True#g' setup.py
557
558 %build
559 %{__aclocal}
560 %{__autoconf}
561 CPPFLAGS="-I/usr/include/ncursesw %{rpmcppflags}"; export CPPFLAGS
562 %configure \
563         --with-threads \
564         --with-cxx-main="%{__cxx}" \
565         --with-system-ffi \
566         --enable-ipv6 \
567         --enable-unicode=ucs4 \
568         --enable-shared \
569         --with-system-ffi \
570         --with-dbmliborder=gdbm:bdb \
571         LINKCC='$(PURIFY) $(CXX)' \
572         LDSHARED='$(CC) $(CFLAGS) -shared' \
573         BLDSHARED='$(CC) $(CFLAGS) -shared' \
574         LDFLAGS="%{rpmcflags} %{rpmldflags}"
575
576 %{__make} \
577         OPT="%{rpmcflags}" 2>&1 | awk '
578 BEGIN { fail = 0; logmsg = ""; }
579 {
580                 if ($0 ~ /\*\*\* WARNING:/) {
581                                 fail = 1;
582                                 logmsg = logmsg $0;
583                 }
584                 print $0;
585 }
586 END { if (fail) { print "\nPROBLEMS FOUND:"; print logmsg; exit(1); } }'
587
588 LC_ALL=C
589 export LC_ALL
590 %if %{with tests}
591 %{__make} -j1 test \
592         TESTOPTS="%{test_flags} %{test_list}" \
593         TESTPYTHON="LD_LIBRARY_PATH=`pwd` PYTHONHOME=`pwd` PYTHONPATH=`pwd`/Lib:`pwd`/Lib/lib-tk:`pwd`/build/lib.linux-`uname -m`-%{py_ver} ./python -tt"
594 %endif
595
596 %install
597 rm -rf $RPM_BUILD_ROOT
598 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}} \
599         $RPM_BUILD_ROOT{%{py_sitedir},%{_mandir}/man1} \
600         $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} \
601         $RPM_BUILD_ROOT%{_infodir} \
602         $RPM_BUILD_ROOT%{_docdir} \
603         $RPM_BUILD_ROOT/etc/shrc.d
604
605 %{__make} install \
606         DESTDIR=$RPM_BUILD_ROOT
607
608 # docs in constant location
609 ln -sf python-doc-%{version} $RPM_BUILD_ROOT%{_docdir}/python-doc
610
611 %if %{with info}
612 %{__make} -C Doc/info
613 install Doc/info/python*info* $RPM_BUILD_ROOT%{_infodir}
614 %endif
615
616 install Makefile.pre.in $RPM_BUILD_ROOT%{py_libdir}/config
617
618 mv $RPM_BUILD_ROOT{%{py_libdir}/config,%{_libdir}}/libpython%{py_ver}.a
619 ln -sf libpython%{py_ver}.a $RPM_BUILD_ROOT%{_libdir}/libpython.a
620 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython.so
621 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython%{py_ver}.so
622
623 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
624 cp -a Tools Demo $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
625
626 #
627 # create several useful aliases, such as timeit.py, profile.py, pdb.py, smtpd.py
628 #
629
630 # for python devel tools
631 for script in timeit profile pdb pstats; do
632     echo alias $script.py=\"python -m ${script}\"
633 done > $RPM_BUILD_ROOT/etc/shrc.d/python-devel.sh
634
635 sed 's/=/ /' \
636         < $RPM_BUILD_ROOT/etc/shrc.d/python-devel.sh \
637         > $RPM_BUILD_ROOT/etc/shrc.d/python-devel.csh
638
639 # for python modules
640 for script in smtpd webbrowser; do
641     echo alias $script.py=\"python -m ${script}\"
642 done > $RPM_BUILD_ROOT/etc/shrc.d/python-modules.sh
643
644 sed 's/=/ /' \
645         < $RPM_BUILD_ROOT/etc/shrc.d/python-modules.sh \
646         > $RPM_BUILD_ROOT/etc/shrc.d/python-modules.csh
647
648 # just to cut the noise, as they are not packaged (now)
649 # first tests
650 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/test
651 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/bsddb/test
652 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/ctypes/test
653 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/distutils/tests
654 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/email/test
655 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/sqlite3/test
656 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/json/tests
657 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/lib2to3/tests
658
659 # other files
660 rm -r $RPM_BUILD_ROOT%{py_scriptdir}/plat-*/regen
661 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.egg-info -exec rm {} \;
662 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.bat -exec rm {} \;
663 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.txt -exec rm {} \;
664 find $RPM_BUILD_ROOT%{py_scriptdir} -name README\* -exec rm {} \;
665
666 %clean
667 rm -rf $RPM_BUILD_ROOT
668
669 %post   libs -p /sbin/ldconfig
670 %postun libs -p /sbin/ldconfig
671
672 %post   doc-info -p /sbin/postshell
673 -/usr/sbin/fix-info-dir -c %{_infodir}
674
675 %postun doc-info -p /sbin/postshell
676 -/usr/sbin/fix-info-dir -c %{_infodir}
677
678 %files
679 %defattr(644,root,root,755)
680 %attr(755,root,root) %{__python}
681 %attr(755,root,root) %{__python}%{py_ver}
682 %{_mandir}/man1/python.1*
683
684 %files modules
685 %defattr(644,root,root,755)
686 /etc/shrc.d/python-modules*
687 %exclude %{py_scriptdir}/_abcoll.py[co]
688 %exclude %{py_scriptdir}/abc.py[co]
689 %exclude %{py_scriptdir}/UserDict.py[co]
690 %exclude %{py_scriptdir}/codecs.py[co]
691 %exclude %{py_scriptdir}/copy_reg.py[co]
692 %exclude %{py_scriptdir}/genericpath.py[co]
693 %exclude %{py_scriptdir}/linecache.py[co]
694 %exclude %{py_scriptdir}/locale.py[co]
695 %exclude %{py_scriptdir}/posixpath.py[co]
696 %exclude %{py_scriptdir}/pdb.py[co]
697 %exclude %{py_scriptdir}/profile.py[co]
698 %exclude %{py_scriptdir}/pstats.py[co]
699 %exclude %{py_scriptdir}/pydoc.py[co]
700 %exclude %{py_scriptdir}/re.py[co]
701 %exclude %{py_scriptdir}/site.py[co]
702 %exclude %{py_scriptdir}/sre_*.py[co]
703 %exclude %{py_scriptdir}/stat.py[co]
704 %exclude %{py_scriptdir}/sysconfig.py[co]
705 %exclude %{py_scriptdir}/timeit.py[co]
706 %exclude %{py_scriptdir}/os.py[co]
707 %exclude %{py_scriptdir}/encodings/*.py[co]
708 %exclude %{py_scriptdir}/types.py[co]
709 %exclude %{py_scriptdir}/warnings.py[co]
710
711 %{py_scriptdir}/*.py[co]
712
713 %{py_dyndir}/*.egg-info
714
715 #
716 # list .so modules to be sure that all of them are built
717 #
718
719 # three modules below do not work on 64-bit architectures
720 # see Python README file for explanation
721 %ifnarch alpha ia64 ppc64 sparc64 %{x8664}
722 %attr(755,root,root) %{py_dyndir}/imageop.so
723 # sizeof(long) != sizeof(int), so dl module will not be built on 64-bit
724 # platforms
725 %attr(755,root,root) %{py_dyndir}/dl.so
726 %endif
727
728 %attr(755,root,root) %{py_dyndir}/audioop.so
729 %attr(755,root,root) %{py_dyndir}/array.so
730 %attr(755,root,root) %{py_dyndir}/binascii.so
731 %attr(755,root,root) %{py_dyndir}/_bisect.so
732 %attr(755,root,root) %{py_dyndir}/_bsddb.so
733 %attr(755,root,root) %{py_dyndir}/bz2.so
734 %attr(755,root,root) %{py_dyndir}/cmath.so
735 %attr(755,root,root) %{py_dyndir}/_codecs_cn.so
736 %attr(755,root,root) %{py_dyndir}/_codecs_hk.so
737 %attr(755,root,root) %{py_dyndir}/_codecs_iso2022.so
738 %attr(755,root,root) %{py_dyndir}/_codecs_jp.so
739 %attr(755,root,root) %{py_dyndir}/_codecs_kr.so
740 %attr(755,root,root) %{py_dyndir}/_codecs_tw.so
741 %attr(755,root,root) %{py_dyndir}/_collections.so
742 %attr(755,root,root) %{py_dyndir}/cPickle.so
743 %attr(755,root,root) %{py_dyndir}/crypt.so
744 %attr(755,root,root) %{py_dyndir}/cStringIO.so
745 %attr(755,root,root) %{py_dyndir}/_csv.so
746 %attr(755,root,root) %{py_dyndir}/_ctypes*.so
747 %attr(755,root,root) %{py_dyndir}/_curses_panel.so
748 %attr(755,root,root) %{py_dyndir}/_curses.so
749 %attr(755,root,root) %{py_dyndir}/datetime.so
750 %attr(755,root,root) %{py_dyndir}/_elementtree.so
751 %attr(755,root,root) %{py_dyndir}/_functools.so
752 %attr(755,root,root) %{py_dyndir}/_hashlib.so
753 %attr(755,root,root) %{py_dyndir}/_heapq.so
754 %attr(755,root,root) %{py_dyndir}/_io.so
755 %attr(755,root,root) %{py_dyndir}/_json.so
756 %attr(755,root,root) %{py_dyndir}/_locale.so
757 %attr(755,root,root) %{py_dyndir}/_lsprof.so
758 %attr(755,root,root) %{py_dyndir}/_multibytecodec.so
759 %attr(755,root,root) %{py_dyndir}/_multiprocessing.so
760 %attr(755,root,root) %{py_dyndir}/_random.so
761 %{?with_openssl097:%attr(755,root,root) %{py_dyndir}/_sha*.so}
762 %attr(755,root,root) %{py_dyndir}/_socket.so
763 %attr(755,root,root) %{py_dyndir}/_ssl.so
764 %attr(755,root,root) %{py_dyndir}/_testcapi.so
765 %attr(755,root,root) %{py_dyndir}/_weakref.so
766 %ifnarch sparc64
767 %attr(755,root,root) %{py_dyndir}/dbm.so
768 %endif
769 %attr(755,root,root) %{py_dyndir}/fcntl.so
770 %attr(755,root,root) %{py_dyndir}/future_builtins.so
771 %attr(755,root,root) %{py_dyndir}/gdbm.so
772 %attr(755,root,root) %{py_dyndir}/grp.so
773 %attr(755,root,root) %{py_dyndir}/itertools.so
774 %attr(755,root,root) %{py_dyndir}/linuxaudiodev.so
775 %attr(755,root,root) %{py_dyndir}/math.so
776 %attr(755,root,root) %{py_dyndir}/mmap.so
777 %attr(755,root,root) %{py_dyndir}/nis.so
778 %attr(755,root,root) %{py_dyndir}/operator.so
779 %attr(755,root,root) %{py_dyndir}/ossaudiodev.so
780 %attr(755,root,root) %{py_dyndir}/parser.so
781 %attr(755,root,root) %{py_dyndir}/pyexpat.so
782 %attr(755,root,root) %{py_dyndir}/readline.so
783 %attr(755,root,root) %{py_dyndir}/resource.so
784 %attr(755,root,root) %{py_dyndir}/select.so
785 %attr(755,root,root) %{py_dyndir}/strop.so
786 %attr(755,root,root) %{py_dyndir}/syslog.so
787 %attr(755,root,root) %{py_dyndir}/termios.so
788 %attr(755,root,root) %{py_dyndir}/time.so
789 %attr(755,root,root) %{py_dyndir}/spwd.so
790 %attr(755,root,root) %{py_dyndir}/unicodedata.so
791 %attr(755,root,root) %{py_dyndir}/zlib.so
792
793 %dir %{py_scriptdir}/plat-*
794 %{py_scriptdir}/plat-*/*.py[co]
795
796 %dir %{py_scriptdir}/bsddb
797 %{py_scriptdir}/bsddb/*.py[co]
798
799 %dir %{py_scriptdir}/compiler
800 %{py_scriptdir}/compiler/*.py[co]
801
802 %dir %{py_scriptdir}/ctypes
803 %dir %{py_scriptdir}/ctypes/macholib
804 %{py_scriptdir}/ctypes/*.py[co]
805 %{py_scriptdir}/ctypes/macholib/*.py[co]
806
807 %dir %{py_scriptdir}/curses
808 %{py_scriptdir}/curses/*.py[co]
809
810 %dir %{py_scriptdir}/distutils
811 %dir %{py_scriptdir}/distutils/command
812 %{py_scriptdir}/distutils/*.py[co]
813 %{py_scriptdir}/distutils/command/*.py[co]
814
815 %dir %{py_scriptdir}/email
816 %dir %{py_scriptdir}/email/mime
817 %{py_scriptdir}/email/*.py[co]
818 %{py_scriptdir}/email/mime/*.py[co]
819
820 %dir %{py_scriptdir}/importlib
821 %{py_scriptdir}/importlib/*.py[co]
822
823 %dir %{py_scriptdir}/json
824 %{py_scriptdir}/json/*.py[co]
825
826 %dir %{py_scriptdir}/logging
827 %{py_scriptdir}/logging/*.py[co]
828
829 %dir %{py_scriptdir}/multiprocessing
830 %dir %{py_scriptdir}/multiprocessing/dummy
831 %{py_scriptdir}/multiprocessing/*.py[co]
832 %{py_scriptdir}/multiprocessing/dummy/*.py[co]
833
834 %dir %{py_scriptdir}/unittest
835 %{py_scriptdir}/unittest/*.py[co]
836 %dir %{py_scriptdir}/unittest/test
837 %{py_scriptdir}/unittest/test/*.py[co]
838
839 %dir %{py_scriptdir}/wsgiref
840 %{py_scriptdir}/wsgiref/*.py[co]
841
842 %dir %{py_scriptdir}/xml
843 %dir %{py_scriptdir}/xml/dom
844 %dir %{py_scriptdir}/xml/etree
845 %dir %{py_scriptdir}/xml/parsers
846 %dir %{py_scriptdir}/xml/sax
847 %{py_scriptdir}/xml/*.py[co]
848 %{py_scriptdir}/xml/dom/*.py[co]
849 %{py_scriptdir}/xml/etree/*.py[co]
850 %{py_scriptdir}/xml/parsers/*.py[co]
851 %{py_scriptdir}/xml/sax/*.py[co]
852
853 %files modules-sqlite
854 %defattr(644,root,root,755)
855 %attr(755,root,root) %{py_dyndir}/_sqlite3.so
856 %dir %{py_scriptdir}/sqlite3
857 %{py_scriptdir}/sqlite3/*.py[co]
858
859 %files libs
860 %defattr(644,root,root,755)
861 %attr(755,root,root) %{_libdir}/libpython*.so.*
862
863 %dir %{py_dyndir}
864 %dir %{py_scriptdir}
865 %dir %{py_libdir}
866 %dir %{py_sitescriptdir}
867 %dir %{py_sitedir}
868
869 # shared modules required by python library
870 %attr(755,root,root) %{py_dyndir}/_struct.so
871
872 # modules required by python library
873 %{py_scriptdir}/_abcoll.py[co]
874 %{py_scriptdir}/abc.py[co]
875 %{py_scriptdir}/UserDict.py[co]
876 %{py_scriptdir}/codecs.py[co]
877 %{py_scriptdir}/copy_reg.py[co]
878 %{py_scriptdir}/genericpath.py[co]
879 %{py_scriptdir}/linecache.py[co]
880 %{py_scriptdir}/locale.py[co]
881 %{py_scriptdir}/posixpath.py[co]
882 %{py_scriptdir}/re.py[co]
883 %{py_scriptdir}/site.py[co]
884 %{py_scriptdir}/sre_*.py[co]
885 %{py_scriptdir}/stat.py[co]
886 %{py_scriptdir}/sysconfig.py[co]
887 %{py_scriptdir}/os.py[co]
888 # needed by the dynamic sys.lib patch
889 %{py_scriptdir}/types.py[co]
890 %{py_scriptdir}/warnings.py[co]
891
892 # encodings required by python library
893 %dir %{py_scriptdir}/encodings
894 %{py_scriptdir}/encodings/*.py[co]
895
896 # required by sysconfig.py
897 %dir %{py_libdir}/config
898 %{py_libdir}/config/Makefile
899 %dir %{py_incdir}
900 %{py_incdir}/pyconfig.h
901
902 %files -n pydoc
903 %defattr(644,root,root,755)
904 %attr(755,root,root) %{_bindir}/pydoc
905 %{py_scriptdir}/pydoc.py[co]
906 %dir %{py_scriptdir}/pydoc_data
907 %{py_scriptdir}/pydoc_data/*.py[co]
908
909 %files -n idle
910 %defattr(644,root,root,755)
911 %attr(755,root,root) %{_bindir}/idle
912 %dir %{py_scriptdir}/idlelib
913 %dir %{py_scriptdir}/idlelib/Icons
914 %{py_scriptdir}/idlelib/*.py[co]
915 %{py_scriptdir}/idlelib/Icons/*
916 %{py_scriptdir}/idlelib/*.def
917
918 %files devel
919 %defattr(644,root,root,755)
920 %doc Misc/{ACKS,NEWS,README,README.valgrind,valgrind-python.supp}
921 %attr(755,root,root) %{__python}-config
922 %attr(755,root,root) %{__python}%{py_ver}-config
923 %attr(755,root,root) %{_libdir}/lib*.so
924 %{py_incdir}/*.h
925 %exclude %{py_incdir}/pyconfig.h
926 %{_pkgconfigdir}/*.pc
927
928 %attr(755,root,root) %{py_libdir}/config/makesetup
929 %attr(755,root,root) %{py_libdir}/config/install-sh
930 %{py_libdir}/config/Makefile.pre.in
931 %{py_libdir}/config/Setup
932 %{py_libdir}/config/Setup.config
933 %{py_libdir}/config/Setup.local
934 %{py_libdir}/config/config.c
935 %{py_libdir}/config/config.c.in
936 %{py_libdir}/config/python.o
937
938 %files devel-src
939 %defattr(644,root,root,755)
940 %attr(-,root,root) %{py_scriptdir}/*.py
941 %{py_scriptdir}/plat-*/*.py
942 %{py_scriptdir}/bsddb/*.py
943 %{py_scriptdir}/ctypes/*.py
944 %{py_scriptdir}/ctypes/macholib/*.py
945 %{py_scriptdir}/compiler/*.py
946 %{py_scriptdir}/curses/*.py
947 %{py_scriptdir}/distutils/*.py
948 %{py_scriptdir}/distutils/command/*.py
949 %{py_scriptdir}/email/*.py
950 %{py_scriptdir}/email/mime/*.py
951 %{py_scriptdir}/hotshot/*.py
952 %{py_scriptdir}/json/*.py
953 %{py_scriptdir}/lib2to3/*.py
954 %{py_scriptdir}/lib2to3/fixes/*.py
955 %{py_scriptdir}/lib2to3/pgen2/*.py
956 %{py_scriptdir}/logging/*.py
957 %{py_scriptdir}/multiprocessing/*.py
958 %{py_scriptdir}/multiprocessing/dummy/*.py
959 %{py_scriptdir}/sqlite3/*.py
960 %{py_scriptdir}/wsgiref/*.py
961 %{py_scriptdir}/xml/*.py
962 %{py_scriptdir}/xml/dom/*.py
963 %{py_scriptdir}/xml/etree/*.py
964 %{py_scriptdir}/xml/parsers/*.py
965 %{py_scriptdir}/xml/sax/*.py
966 %{py_scriptdir}/encodings/*.py
967 %{py_scriptdir}/idlelib/*.py
968
969 %files devel-tools
970 %defattr(644,root,root,755)
971 %doc Lib/pdb.doc
972 /etc/shrc.d/python-devel*
973
974 %attr(755,root,root) %{py_dyndir}/_hotshot.so
975 %dir %{py_scriptdir}/hotshot
976 %{py_scriptdir}/hotshot/*.py[co]
977 %{py_scriptdir}/pdb.py[co]
978 %{py_scriptdir}/profile.py[co]
979 %{py_scriptdir}/pstats.py[co]
980 %{py_scriptdir}/timeit.py[co]
981
982 %files 2to3
983 %defattr(644,root,root,755)
984 %attr(755,root,root) %{_bindir}/2to3
985 %dir %{py_scriptdir}/lib2to3
986 %dir %{py_scriptdir}/lib2to3/fixes
987 %dir %{py_scriptdir}/lib2to3/pgen2
988 %{py_scriptdir}/lib2to3/*.py[co]
989 %{py_scriptdir}/lib2to3/*.pickle
990 %{py_scriptdir}/lib2to3/fixes/*.py[co]
991 %{py_scriptdir}/lib2to3/pgen2/*.py[co]
992
993 %files static
994 %defattr(644,root,root,755)
995 %{_libdir}/libpython*.a
996
997 %files examples
998 %defattr(644,root,root,755)
999 %{_examplesdir}/%{name}-%{version}
1000
1001 %files doc
1002 %defattr(644,root,root,755)
1003 %doc python-%{dver}-docs-html/*
1004 %{_docdir}/python-doc
1005
1006 %if %{with info}
1007 %files doc-info
1008 %defattr(644,root,root,755)
1009 %{_infodir}/*.info*
1010 %endif
1011
1012 %if %{with tkinter}
1013 %files tkinter
1014 %defattr(644,root,root,755)
1015 %{py_scriptdir}/lib-tk
1016 %attr(755,root,root) %{py_dyndir}/_tkinter.so
1017 %endif
This page took 4.413605 seconds and 4 git commands to generate.