3 %bcond_with info # info pages (requires emacs)
4 %bcond_without tkinter # disables tkinter module building
5 %bcond_without tests # disables Python testing
6 %bcond_with verbose_tests # runs tests in verbose mode
9 # tests which will not work on 64-bit platforms
10 %define no64bit_tests test_audioop test_rgbimg test_imageop
11 # tests which may fail because of builder environment limitations (no /proc or /dev/pts)
12 %define nobuilder_tests test_resource test_openpty test_socket test_nis test_posix test_locale test_pty
13 # tests which fail because of some unknown/unresolved reason (this list should be empty)
14 %define broken_tests test_anydbm test_bsddb test_re test_shelve test_whichdb test_zipimport test_distutils
19 %define py_prefix %{_prefix}
20 %define py_libdir %{py_prefix}/%{_lib}/python%{py_ver}
21 %define py_incdir %{_includedir}/python%{py_ver}
22 %define py_sitedir %{py_libdir}/site-packages
23 %define py_dyndir %{py_libdir}/lib-dynload
25 Summary: Very high level scripting language with X interface
26 Summary(es.UTF-8): Lenguaje script de alto nivel con interfaz X
27 Summary(fr.UTF-8): Langage de script de très haut niveau avec interface X
28 Summary(pl.UTF-8): Python - język obiektowy wysokiego poziomu
29 Summary(pt_BR.UTF-8): Linguagem de programação interpretada de alto nível
30 Summary(ru.UTF-8): Язык программирования очень высокого уровня с X-интерфейсом
31 Summary(tr.UTF-8): X arayüzlü, yüksek düzeyli, kabuk yorumlayıcı dili
32 Summary(uk.UTF-8): Мова програмування дуже високого рівня з X-інтерфейсом
39 Source0: http://www.python.org/ftp/python/%{version}/Python-%{version}%{beta}.tgz
40 # Source0-md5: ac1d8aa55bd6d04232cd96abfa445ac4
41 Patch1: %{name}-pythonpath.patch
42 Patch2: %{name}-no_ndbm.patch
43 Patch3: %{name}-ac_fixes.patch
44 Patch4: %{name}-noarch_to_datadir.patch
45 Patch5: %{name}-lib64.patch
46 Patch6: %{name}-doc_path.patch
47 Patch7: %{name}-db4.6.patch
48 URL: http://www.python.org/
49 BuildRequires: autoconf
50 BuildRequires: bluez-libs-devel
51 BuildRequires: bzip2-devel
52 BuildRequires: db-devel >= 4
53 %{?with_info:BuildRequires: emacs >= 21}
54 BuildRequires: expat-devel >= 1:1.95.7
56 BuildRequires: gdbm-devel >= 1.8.3
57 BuildRequires: gmp-devel >= 4.0
58 BuildRequires: libstdc++-devel
59 BuildRequires: ncurses-ext-devel >= 5.2
60 %if %{with openssl097}
61 BuildRequires: openssl-devel < 0.9.8
63 BuildRequires: openssl-devel >= 0.9.8
65 BuildRequires: readline-devel >= 5.0
66 BuildRequires: rpm-pythonprov
67 BuildRequires: sed >= 4.0
68 BuildRequires: sqlite3-devel >= 3.3.5
69 %{?with_info:BuildRequires: tetex-makeindex}
70 %{?with_tkinter:BuildRequires: tix-devel >= 1:8.1.4-4}
71 %{?with_tkinter:BuildRequires: tk-devel >= 8.4.3}
72 BuildRequires: zlib-devel
73 Requires: %{name}-libs = %{epoch}:%{version}-%{release}
74 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
76 %if %{with verbose_tests}
77 %define test_flags -v -l -x
79 %define test_flags -l -x
82 %ifarch alpha ia64 ppc64 sparc64 ppc64 %{x8664}
83 %define test_list %{nobuilder_tests} %{broken_tests} %{no64bit_tests}
85 %define test_list %{nobuilder_tests} %{broken_tests}
89 %define test_list %{nobuilder_tests} %{broken_tests} test_fcntl test_ioctl
93 Python is an interpreted, interactive, object-oriented programming
94 language. It incorporates modules, exceptions, dynamic typing, very
95 high level dynamic data types, and classes. Python combines remarkable
96 power with very clear syntax. It has interfaces to many system calls
97 and libraries, as well as to various window systems, and is extensible
98 in C or C++. It is also usable as an extension language for
99 applications that need a programmable interface. Finally, Python is
100 portable: it runs on many brands of UNIX, on the Mac, and on PCs under
101 MS-DOS, Windows, Windows NT, and OS/2.
103 This package contains the Python binary.
105 %description -l de.UTF-8
106 Python ist eine interpretierte, interaktive, objektorientierte
107 Programmiersprache, vergleichbar zu Tcl, Perl, Scheme oder Java.
108 Python enthält Module, Klassen, Exceptions, High-Level dynamische
109 Datentypen und dynamisches Typisieren. Python unterstützt Interfaces
110 zu vielen Systemaufrufen und Libraries, sowie verschiedene
111 Fenstersysteme (X11, Motif, Tk, Mac und MFC)
113 Programmierer können neue built-in-Module für Python in C oder C++
114 schreiben. Python kann auch als Erweiterungssprache für Applikationen
115 benutzt werden, die ein programmierbares Interface brauchen. Dieses
116 Paket enthält die meisten Standard-Python-Module, und Module zum
117 Ansprechen von Tix (Tk-widget set) und RPM.
119 %description -l es.UTF-8
120 Python es un lenguaje de scripts interpretado orientado a objetos.
121 Contiene soporte para carga dinámica de objetos, clases, módulos y
124 Es sencillo adicionar interfaces para nuevos sistemas de biblioteca a
125 través de código C, tornando Python fácil de usar en ambientes
126 particulares/personalizados. Este paquete Python incluye la mayoría de
127 los módulos padrón Python, junto con módulos para crear interfaces
128 para el conjunto de componentes Tix para Tk y RPM.
130 %description -l fr.UTF-8
131 Python est un langage de script interprété et orienté objet. Il gère
132 le chargement dynamique des objets, les classes, les modules et les
133 exceptions. L'ajout d'interfaces aux nouvelles bibliothèques systèmes
134 avec du code C est simple, ce qui rend Python facile à utiliser dans
135 des configs personnalisées.
137 Ce paquetage Python contient la plupart des modules Python standards,
138 ainsi que ceux permettant l'interfaçage avec les widgets Tix pour Tk
141 %description -l pl.UTF-8
142 Python jest interpretowanym, interaktywnym i zorientowanym obiektowo
143 językiem programowania. Jest modularny, obsługuje wyjątki, dynamiczne
144 typy, zaawansowane dynamiczne struktury danych i klasy. Python łączy w
145 sobie duże możliwości i przejrzystą składnię. Posiada interfejsy do
146 wielu wywołań systemowych i bibliotek, w tym również do różnych
147 bibliotek okienkowych. Możliwości jego można jeszcze rozszerzać
148 poprzez odpowiednie moduły pisane w C lub C++. Python może być również
149 użyty jako element aplikacji, którym potrzebny jest interpreter do
150 skryptów. I wreszcie, Python jest wieloplatformowy, działa na wielu
151 odmianach UNIX-a, Macu oraz PC pod DOS-em, Windows, WindowsNT oraz
154 Ten pakiet zawiera binarkę Pythona.
156 %description -l pt_BR.UTF-8
157 Python é uma linguagem de scripts interpretada orientada a objetos.
158 Contém suporte para carga dinâmica de objetos, classes, módulos e
159 exceções. Adicionar interfaces para novos sistemas de biblioteca
160 através de código C é simples, tornando Python fácil de usar em
161 ambientes particulares/personalizados.
163 Este pacote Python inclui a maioria do módulos padrão Python, junto
164 com módulos para interfaceamento para o conjunto de componentes Tix
167 %description -l ru.UTF-8
168 Python - это интерпретируемый, объектно-ориентированный язык
169 программирования. Он поддерживает динамическую загрузку объектов,
170 классы, модули и обработку исключительных ситуаций (exceptions).
171 Простота добавления интерфейсов к новым системным библиотекам через
172 код на языке C делает Python хорошим выбором для использования в
173 специальных конфигурациях.
175 %description -l tr.UTF-8
176 Python, nesneye yönelik bir kabuk yorumlayıcıdır. Nesnelerin,
177 sınıfların, modüllerin ve aykırı durumların dinamik yüklenmelerine
178 destek verir. C koduyla birlikte kullanımı son derece kolaydır. Bu
179 paket, standart Python birimlerinin çoğunun yanısıra Tk ve RPM için
180 arayüz birimlerini de içerir.
182 %description -l uk.UTF-8
183 Python - це інтерпретована, об'єктно-орієнтована мова програмування.
184 Він підтримує динамічну загрузку об'єктів, класи, модулі та обробку
185 виключних ситуацій (exceptions). Простота додавання інтерфейсів для
186 нових системних бібліотек через код на мові C робить Python добрим
187 вибором для використання в спеціальних конфігураціях.
190 Summary: Python library
191 Summary(pl.UTF-8): Biblioteka języka Python
192 Group: Libraries/Python
193 # broken detection in rpm/pythondeps.sh
194 Provides: python(abi) = %{py_ver}
195 # for compatibility with existing Ac packages
196 Provides: python(bytecode) = %{py_ver}
197 %{!?with_info:Obsoletes: python30-doc-info}
200 Python shared library and very essental modules for Python binary.
202 %description libs -l pl.UTF-8
203 Biblioteka współdzielona języka Python oraz bardzo podstawowe moduły
207 Summary: Python modules
208 Summary(pl.UTF-8): Moduły języka Python
209 Group: Libraries/Python
210 Requires: %{name}-libs = %{epoch}:%{version}-%{release}
213 Python officially distributed modules.
215 %description modules -l pl.UTF-8
216 Oficjalnie rozprowadzane moduły języka Python.
218 %package modules-sqlite
219 Summary: Python SQLite modules
220 Summary(pl.UTF-8): Moduły SQLite języka Python
221 Group: Libraries/Python
222 Requires: %{name}-modules = %{epoch}:%{version}-%{release}
224 %description modules-sqlite
225 Python officially distributed sqlite module.
227 %description modules-sqlite -l pl.UTF-8
228 Oficjalnie rozprowadzany moduł sqlite języka Python.
231 Summary: Python interactive module documentation access support
232 Summary(pl.UTF-8): Interaktywne korzystanie z dokumentacji modułów języka Python
234 Requires: %{name}-modules = %{epoch}:%{version}-%{release}
236 %description -n pydoc30
237 Python interactive module documentation access support.
239 %description -n pydoc30 -l pl.UTF-8
240 Interaktywne korzystanie z dokumentacji modułów języka Python.
243 Summary: IDE for Python language
244 Summary(pl.UTF-8): IDE dla języka Python
246 Requires: %{name}-tkinter = %{epoch}:%{version}-%{release}
248 %description -n idle30
249 IDE for Python language.
251 %description -n idle30 -l pl.UTF-8
252 IDE dla języka Python.
255 Summary: Libraries and header files for building python code
256 Summary(de.UTF-8): Libraries und Header-Dateien zum Erstellen von Python-Code
257 Summary(es.UTF-8): Bibliotecas y archivos de inclusión para construir programas en python
258 Summary(fr.UTF-8): Bibliothèques et en-têtes pour construire du code python
259 Summary(pl.UTF-8): Pliki nagłówkowe i biblioteki Pythona
260 Summary(pt_BR.UTF-8): Bibliotecas e arquivos de inclusão para o Python
261 Summary(ru.UTF-8): Библиотеки и хедеры для построения кода на языке Python
262 Summary(tr.UTF-8): Python ile geliştirme yapmak için gerekli dosyalar
263 Summary(uk.UTF-8): Бібліотеки та хедери для програмування на мові Python
264 Group: Development/Languages/Python
265 Requires: %{name}-libs = %{epoch}:%{version}-%{release}
266 Obsoletes: python-devel
269 The Python interpreter is relatively easy to extend with dynamically
270 loaded extensions and to embed in other programs. This package
271 contains the header files and libraries which are needed to do both of
274 %description devel -l de.UTF-8
275 Der Python-Interpretierer ist relativ einfach anhand von dynamisch
276 ladbaren Erweiterungen auszubauen und läßt sich in andere Programme
277 integrieren. Dieses Paket enthält die Header-Dateien und Libraries,
278 die für beide Aufgaben erforderlich sind.
280 %description devel -l es.UTF-8
281 El interpretador Python permite incluir con facilidad extensiones
282 cargadas dinámicamente. Python es también fácil de ser empotrado en
283 otros programas. Este paquete contiene los archivos de inclusión y
284 bibliotecas necesarios para estas dos tareas.
286 %description devel -l fr.UTF-8
287 L'interpréteur Python est relativement facile à étendre avec des
288 extensions chargées dynamiquement et à insérer dans d'autres
289 programmes. Ce paquetage contient les en-têtes et les bibliothèques
290 nécessaires à ces deux tâches.
292 %description devel -l pl.UTF-8
293 Interpreter Pythona jest w miarę łatwy do rozszerzania przy pomocy
294 dynamicznie ładowanych rozszerzeń napisanych w C lub C++ oraz
295 osadzania w innych programach. Ten pakiet zawiera pliki nagłówkowe i
296 wszystko inne co potrzebne do tych celów.
298 %description devel -l pt_BR.UTF-8
299 O interpretador Python permite incluir com facilidade extensões
300 carregadas dinamicamente. Python é também fácil de ser embutido em
301 outros programas. Este pacote contém os arquivos de inclusão e
302 bibliotecas necessários para estas duas tarefas.
304 %description devel -l ru.UTF-8
305 Интерпретатор Python относительно легко расширяется при помощи
306 динамически загружаемых расширений и встраивается в другие программы.
307 Этот пакет содержит хедеры и библиотеки, необходимые для обеих этих
310 %description devel -l tr.UTF-8
311 Bu paket, Python ile geliştirme yapılabilmesi için gerekli başlık
312 dosyalarını ve kitaplıkları içerir.
314 %description devel -l uk.UTF-8
315 Інтерпретатор Python відносно легко розширюється за допомогою
316 розширень з динамічною загрузкою та вбудовується в інші програми. Цей
317 пакет містить хедери та бібліотеки, необхідні для обох цих задач.
320 Summary: Python module sources
321 Summary(pl.UTF-8): Pliki źródłowe modułów Pythona
322 Group: Development/Languages/Python
323 Requires: %{name}-modules = %{epoch}:%{version}-%{release}
325 %description devel-src
326 Python module sources.
328 %description devel-src -l pl.UTF-8
329 Pliki źródłowe modułów Pythona.
332 Summary: Python development tools
333 Summary(pl.UTF-8): Narzędzia programistyczne języka Python
334 Group: Development/Languages/Python
335 Requires: %{name}-modules = %{epoch}:%{version}-%{release}
337 %description devel-tools
338 Python development tools such as profilers and debugger.
340 %description devel-tools -l pl.UTF-8
341 Narzędzia programistyczne języka Python takie jak profiler oraz
345 Summary: Static python library
346 Summary(pl.UTF-8): Statyczna biblioteka Pythona
347 Group: Development/Languages/Python
348 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
351 Static python library.
353 %description static -l pl.UTF-8
354 Statyczna biblioteka Pythona.
357 Summary: Documentation on Python
358 Summary(de.UTF-8): Dokumentation zu Python
359 Summary(es.UTF-8): Documentación para Python
360 Summary(fr.UTF-8): Documentation sur Python
361 Summary(pl.UTF-8): Dokumentacja do Pythona
362 Summary(pt_BR.UTF-8): Documentação para a linguagem de programação Python
363 Summary(ru.UTF-8): Документация по языку Python
364 Summary(tr.UTF-8): Python belgeleri
365 Summary(uk.UTF-8): Документація по мові Python
369 This package contains documentation on the Python language and
370 interpretor as a mix of plain ASCII files and LaTeX sources.
372 %description doc -l de.UTF-8
373 Dieses Paket enthält Dokumentationen zu Python (Sprache und
374 Interpreter) in Form von einfachen ASCII-Dateien und LaTeX-Quellen.
376 %description doc -l es.UTF-8
377 Documentación para Python. Contiene archivos en texto y PostScript.
379 %description doc -l fr.UTF-8
380 Ce paquetage contient la documentation sur le langage python et sur
381 son interpréteur sous forme de fichiers ASCII et LaTeX.
383 %description doc -l pl.UTF-8
384 Oficjalna dokumentacja do Pythona. Zawiera przykładowe programy,
385 narzędzia i dokumentację. Strony podręcznika man znajdują się w
386 głównym pakiecie. Ten pakiet nie zawiera źródeł dokumentacji
387 napisanych w LaTeXu, tylko gotowe do wykorzystania pliki postscriptowe
390 %description doc -l pt_BR.UTF-8
391 O pacote python-doc contém documentação para a linguagem de
392 programação e para o interpretador Python. Fornecida em arquivos texto
395 %description doc -l ru.UTF-8
396 Этот пакет содержит документацию по собственно языку Python и по
397 исполняющему его интерпретатору в виде набора текстовых файлов и
398 исходных текстов в формате LaTeX.
400 %description doc -l tr.UTF-8
401 Bu paket, Python dili ile ilgili belgeleri ve düz ASCII dosyaları ve
402 LaTeX kaynaklarının bir karışımı olan yorumlayıcıyı içerir.
404 %description doc -l uk.UTF-8
405 Цей пакет містить документацію по власне мові Python та по виконуючому
406 її інтерпретатору у вигляді набора текстових файлів та вихідних
407 текстів у форматі LaTeX.
410 Summary: Documentation on Python in texinfo format
411 Summary(pl.UTF-8): Dokumentacja do Pythona w formacie texinfo
414 %description doc-info
415 Documentation on Python in texinfo format.
417 %description doc-info -l pl.UTF-8
418 Dokumentacja do Pythona w formacie texinfo.
421 Summary: Standard Python interface to the Tk GUI toolkit
422 Summary(de.UTF-8): Grafische Tk-Schnittstelle für Python
423 Summary(es.UTF-8): Interfaz de GUI Tk para Python
424 Summary(fr.UTF-8): Interface graphique Tk pour Python
425 Summary(pl.UTF-8): Standardowy interfejs Pythona do biblioteki Tk
426 Summary(pt_BR.UTF-8): Interface GUI Tk para Phyton
427 Summary(tr.UTF-8): Python için grafik kullanıcı arayüzü
428 Group: Libraries/Python
429 Requires: %{name}-modules = %{epoch}:%{version}-%{release}
430 Requires: tcl >= 8.4.3
431 Requires: tix >= 1:8.1.4-4
432 Requires: tk >= 8.4.3
435 Standard Python interface to the Tk GUI toolkit.
437 %description tkinter -l de.UTF-8
438 Eine grafische Schnittstelle für Python, basierend auf Tcl/Tk, und von
439 vielen Konfigurations-Tools genutzt.
441 %description tkinter -l es.UTF-8
442 Una interfaz gráfica para Python, basada en Tcl/Tk, y usada por muchas
443 herramientas de configuración.
445 %description tkinter -l fr.UTF-8
446 Interface graphique pour Python, basée sur Tcl/Tk et utilisée par
447 beaucoup des outils de configuration.
449 %description tkinter -l pl.UTF-8
450 Standardowy interfejs Pythona do biblioteki Tk.
452 %description tkinter -l pt_BR.UTF-8
453 Uma interface gráfica para Python, baseada em Tcl/Tk, e usada por
454 muitas ferramentas de configuração.
456 %description tkinter -l ru.UTF-8
457 Графический интерфейс (GUI) для Python, построенный на Tcl/Tk.
459 %description tkinter -l tr.UTF-8
460 Python için Tcl/Tk'ye dayalı ve pek çok ayarlama aracı tarafından
461 kullanılan grafik bir arayüzdür.
463 %description tkinter -l uk.UTF-8
464 Графічний інтерфейс (GUI) для Python, побудований на Tcl/Tk.
467 Summary: Example programs in Python
468 Summary(pl.UTF-8): Przykładowe programy w Pythonie
469 Group: Development/Languages/Python
471 %description examples
472 Example programs in Python.
474 These are for Python 2.3.4, not %{version}.
476 %description examples -l pl.UTF-8
477 Przykładowe programy w Pythonie.
479 Przykłady te są dla Pythona 2.3.4, nie %{version}.
482 %setup -q -n Python-%{version}%{beta}
492 sed -i -e 's#-ltermcap#-ltinfo#g' configure*
494 CPPFLAGS="-I/usr/include/ncurses"; export CPPFLAGS
496 --with-cxx="%{__cxx}" \
499 --enable-unicode=ucs4 \
500 --with-signal-module \
504 --with-wctype-functions \
506 LINKCC='$(PURIFY) $(CXX)' \
507 LDSHARED='$(CC) $(CFLAGS) -shared' \
508 BLDSHARED='$(CC) $(CFLAGS) -shared' \
509 LDFLAGS="%{rpmcflags} %{rpmldflags}"
512 OPT="%{rpmcflags}" 2>&1 | awk '
513 BEGIN { fail = 0; logmsg = ""; }
515 if ($0 ~ /\*\*\* WARNING:/) {
521 END { if (fail) { print "\nPROBLEMS FOUND:"; print logmsg; exit(1); } }'
526 binlibdir=`echo build/lib.*`
528 TESTOPTS="%{test_flags} %{test_list}" \
529 TESTPYTHON="LD_LIBRARY_PATH=`pwd` PYTHONHOME=`pwd` PYTHONPATH=`pwd`/Lib:$binlibdir ./python%{py_ver} -tt"
533 rm -rf $RPM_BUILD_ROOT
534 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}} \
535 $RPM_BUILD_ROOT{%{py_sitedir},%{_mandir}/man1} \
536 $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} \
537 $RPM_BUILD_ROOT%{_infodir} \
538 $RPM_BUILD_ROOT/etc/shrc.d
541 DESTDIR=$RPM_BUILD_ROOT
544 %{__make} -C Doc/info
545 install Doc/info/python*info* $RPM_BUILD_ROOT%{_infodir}
548 install Makefile.pre.in $RPM_BUILD_ROOT%{py_libdir}/config
550 mv $RPM_BUILD_ROOT{%{py_libdir}/config,%{_libdir}}/libpython%{py_ver}.a
551 ln -sf libpython%{py_ver}.a $RPM_BUILD_ROOT%{_libdir}/libpython.a
552 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython.so
553 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython%{py_ver}.so
555 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
556 cp -a Tools Demo $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
559 # create several useful aliases, such as timeit.py, profile.py, pdb.py, smtpd.py
562 # for python devel tools
563 for script in timeit profile pdb pstats; do
564 echo alias ${script}%{py_ver}.py=\"python%{py_ver} -m ${script}\"
565 done > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh
567 echo alias pygettext%{py_ver}.py='"pygettext%{py_ver}"' \
568 >> $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh
571 < $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh \
572 > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.csh
575 for script in smtpd webbrowser; do
576 echo alias ${script}%{py_ver}.py=\"python%{py_ver} -m ${script}\"
577 done > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.sh
580 < $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.sh \
581 > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.csh
583 # xgettext specific for Python code
585 # we will have two commands: pygettext.py (an alias) and pygettext;
586 # this way there are no import (which is impossible now) conflicts and
587 # pygettext.py is provided for compatibility
588 install Tools/i18n/pygettext.py $RPM_BUILD_ROOT%{_bindir}/pygettext%{py_ver}
591 for script in idle pydoc; do
592 mv $RPM_BUILD_ROOT%{_bindir}/${script} $RPM_BUILD_ROOT%{_bindir}/${script}%{py_ver}
594 mv $RPM_BUILD_ROOT%{_mandir}/man1/python.1 $RPM_BUILD_ROOT%{_mandir}/man1/python%{py_ver}.1
596 # just to cut the noise, as they are not packaged (now)
598 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/test
599 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/bsddb/test
600 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/ctypes/test
601 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/distutils/tests
602 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/email/test
603 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/sqlite3/test
606 rm -rf $RPM_BUILD_ROOT%{py_scriptdir}/plat-*/regen
607 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.egg-info -exec rm {} \;
608 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.bat -exec rm {} \;
609 find $RPM_BUILD_ROOT%{py_scriptdir} -name \*.txt -exec rm {} \;
610 find $RPM_BUILD_ROOT%{py_scriptdir} -name README\* -exec rm {} \;
613 rm -rf $RPM_BUILD_ROOT
615 %post libs -p /sbin/ldconfig
616 %postun libs -p /sbin/ldconfig
618 %post doc-info -p /sbin/postshell
619 -/usr/sbin/fix-info-dir -c %{_infodir}
621 %postun doc-info -p /sbin/postshell
622 -/usr/sbin/fix-info-dir -c %{_infodir}
625 %defattr(644,root,root,755)
626 #%attr(755,root,root) %{_bindir}/python
627 %attr(755,root,root) %{_bindir}/python%{py_ver}
631 %defattr(644,root,root,755)
632 /etc/shrc.d/python*-modules*
633 %exclude %{py_scriptdir}/UserDict.py[co]
634 %exclude %{py_scriptdir}/codecs.py[co]
635 %exclude %{py_scriptdir}/copy_reg.py[co]
636 %exclude %{py_scriptdir}/locale.py[co]
637 %exclude %{py_scriptdir}/posixpath.py[co]
638 %exclude %{py_scriptdir}/pdb.py[co]
639 %exclude %{py_scriptdir}/profile.py[co]
640 %exclude %{py_scriptdir}/pstats.py[co]
641 %exclude %{py_scriptdir}/pydoc.py[co]
642 %exclude %{py_scriptdir}/site.py[co]
643 %exclude %{py_scriptdir}/stat.py[co]
644 %exclude %{py_scriptdir}/timeit.py[co]
645 %exclude %{py_scriptdir}/os.py[co]
646 %exclude %{py_scriptdir}/encodings/*.py[co]
647 %exclude %{py_scriptdir}/types.py[co]
649 %{py_scriptdir}/*.py[co]
651 %{py_dyndir}/*.egg-info
654 # list .so modules to be sure that all of them are built
657 # three modules below do not work on 64-bit architectures
658 # see Python README file for explanation
659 %ifnarch alpha ia64 ppc64 sparc64 %{x8664}
660 %attr(755,root,root) %{py_dyndir}/audioop.so
661 %attr(755,root,root) %{py_dyndir}/rgbimg.so
662 %attr(755,root,root) %{py_dyndir}/imageop.so
663 # sizeof(long) != sizeof(int), so dl module will not be built on 64-bit
665 %attr(755,root,root) %{py_dyndir}/dl.so
668 %attr(755,root,root) %{py_dyndir}/array.so
669 %attr(755,root,root) %{py_dyndir}/atexit.so
670 %attr(755,root,root) %{py_dyndir}/audioop.so
671 %attr(755,root,root) %{py_dyndir}/binascii.so
672 %attr(755,root,root) %{py_dyndir}/_bisect.so
673 %attr(755,root,root) %{py_dyndir}/_bsddb.so
674 %attr(755,root,root) %{py_dyndir}/bz2.so
675 %attr(755,root,root) %{py_dyndir}/cmath.so
676 %attr(755,root,root) %{py_dyndir}/_codecs_cn.so
677 %attr(755,root,root) %{py_dyndir}/_codecs_hk.so
678 %attr(755,root,root) %{py_dyndir}/_codecs_iso2022.so
679 %attr(755,root,root) %{py_dyndir}/_codecs_jp.so
680 %attr(755,root,root) %{py_dyndir}/_codecs_kr.so
681 %attr(755,root,root) %{py_dyndir}/_codecs_tw.so
682 %attr(755,root,root) %{py_dyndir}/_collections.so
683 #%attr(755,root,root) %{py_dyndir}/cPickle.so
684 %attr(755,root,root) %{py_dyndir}/crypt.so
685 #%attr(755,root,root) %{py_dyndir}/cStringIO.so
686 %attr(755,root,root) %{py_dyndir}/_csv.so
687 %attr(755,root,root) %{py_dyndir}/_ctypes*.so
688 %attr(755,root,root) %{py_dyndir}/_curses_panel.so
689 %attr(755,root,root) %{py_dyndir}/_curses.so
690 %attr(755,root,root) %{py_dyndir}/datetime.so
691 %attr(755,root,root) %{py_dyndir}/_elementtree.so
692 %attr(755,root,root) %{py_dyndir}/_functools.so
693 %attr(755,root,root) %{py_dyndir}/_hashlib.so
694 %attr(755,root,root) %{py_dyndir}/_heapq.so
695 %attr(755,root,root) %{py_dyndir}/_locale.so
696 %attr(755,root,root) %{py_dyndir}/_lsprof.so
697 %attr(755,root,root) %{py_dyndir}/_multibytecodec.so
698 %attr(755,root,root) %{py_dyndir}/_random.so
699 %{?with_openssl097:%attr(755,root,root) %{py_dyndir}/_sha*.so}
700 %attr(755,root,root) %{py_dyndir}/_socket.so
701 %attr(755,root,root) %{py_dyndir}/_ssl.so
702 %attr(755,root,root) %{py_dyndir}/_testcapi.so
703 %attr(755,root,root) %{py_dyndir}/_weakref.so
705 %attr(755,root,root) %{py_dyndir}/dbm.so
707 %attr(755,root,root) %{py_dyndir}/fcntl.so
708 %attr(755,root,root) %{py_dyndir}/gdbm.so
709 %attr(755,root,root) %{py_dyndir}/grp.so
710 %attr(755,root,root) %{py_dyndir}/itertools.so
711 #%attr(755,root,root) %{py_dyndir}/linuxaudiodev.so
712 %attr(755,root,root) %{py_dyndir}/math.so
713 %attr(755,root,root) %{py_dyndir}/mmap.so
714 %attr(755,root,root) %{py_dyndir}/nis.so
715 %attr(755,root,root) %{py_dyndir}/operator.so
716 %attr(755,root,root) %{py_dyndir}/ossaudiodev.so
717 %attr(755,root,root) %{py_dyndir}/parser.so
718 %attr(755,root,root) %{py_dyndir}/pyexpat.so
719 %attr(755,root,root) %{py_dyndir}/readline.so
720 %attr(755,root,root) %{py_dyndir}/resource.so
721 %attr(755,root,root) %{py_dyndir}/select.so
722 #%attr(755,root,root) %{py_dyndir}/strop.so
723 %attr(755,root,root) %{py_dyndir}/syslog.so
724 %attr(755,root,root) %{py_dyndir}/termios.so
725 %attr(755,root,root) %{py_dyndir}/time.so
726 %attr(755,root,root) %{py_dyndir}/spwd.so
727 %attr(755,root,root) %{py_dyndir}/unicodedata.so
728 %attr(755,root,root) %{py_dyndir}/zlib.so
730 %dir %{py_scriptdir}/plat-*
731 %{py_scriptdir}/plat-*/*.py[co]
733 %dir %{py_scriptdir}/bsddb
734 %{py_scriptdir}/bsddb/*.py[co]
736 #%dir %{py_scriptdir}/compiler
737 #%{py_scriptdir}/compiler/*.py[co]
739 %dir %{py_scriptdir}/ctypes
740 %dir %{py_scriptdir}/ctypes/macholib
742 %{py_scriptdir}/ctypes/*.py[co]
743 %{py_scriptdir}/ctypes/macholib/*.py[co]
745 %dir %{py_scriptdir}/curses
746 %{py_scriptdir}/curses/*.py[co]
748 %dir %{py_scriptdir}/distutils
749 %dir %{py_scriptdir}/distutils/command
750 %{py_scriptdir}/distutils/*.py[co]
751 %{py_scriptdir}/distutils/command/*.py[co]
753 %dir %{py_scriptdir}/email
754 %dir %{py_scriptdir}/email/mime
755 %{py_scriptdir}/email/*.py[co]
756 %{py_scriptdir}/email/mime/*.py[co]
758 %dir %{py_scriptdir}/logging
759 %{py_scriptdir}/logging/*.py[co]
761 %dir %{py_scriptdir}/wsgiref
762 %{py_scriptdir}/wsgiref/*.py[co]
764 %dir %{py_scriptdir}/xml
765 %dir %{py_scriptdir}/xml/dom
766 %dir %{py_scriptdir}/xml/etree
767 %dir %{py_scriptdir}/xml/parsers
768 %dir %{py_scriptdir}/xml/sax
769 %{py_scriptdir}/xml/*.py[co]
770 %{py_scriptdir}/xml/dom/*.py[co]
771 %{py_scriptdir}/xml/etree/*.py[co]
772 %{py_scriptdir}/xml/parsers/*.py[co]
773 %{py_scriptdir}/xml/sax/*.py[co]
775 %files modules-sqlite
776 %defattr(644,root,root,755)
777 %attr(755,root,root) %{py_dyndir}/_sqlite3.so
778 %dir %{py_scriptdir}/sqlite3
779 %{py_scriptdir}/sqlite3/*.py[co]
782 %defattr(644,root,root,755)
783 %attr(755,root,root) %{_libdir}/libpython*.so.*
788 %dir %{py_sitescriptdir}
791 # shared modules required by python library
792 %attr(755,root,root) %{py_dyndir}/_struct.so
794 # modules required by python library
795 %{py_scriptdir}/UserDict.py[co]
796 %{py_scriptdir}/codecs.py[co]
797 %{py_scriptdir}/copy_reg.py[co]
798 %{py_scriptdir}/locale.py[co]
799 %{py_scriptdir}/posixpath.py[co]
800 %{py_scriptdir}/site.py[co]
801 %{py_scriptdir}/stat.py[co]
802 %{py_scriptdir}/os.py[co]
803 # needed by the dynamic sys.lib patch
804 %{py_scriptdir}/types.py[co]
806 # encodings required by python library
807 %dir %{py_scriptdir}/encodings
808 %{py_scriptdir}/encodings/*.py[co]
811 %defattr(644,root,root,755)
812 %attr(755,root,root) %{_bindir}/pydoc%{py_ver}
813 %{py_scriptdir}/pydoc.py[co]
816 %defattr(644,root,root,755)
817 %attr(755,root,root) %{_bindir}/idle%{py_ver}
818 %dir %{py_scriptdir}/idlelib
819 %dir %{py_scriptdir}/idlelib/Icons
820 %{py_scriptdir}/idlelib/*.py[co]
821 %{py_scriptdir}/idlelib/Icons/*
822 %{py_scriptdir}/idlelib/*.def
825 %defattr(644,root,root,755)
826 %doc Misc/{ACKS,NEWS,README,README.valgrind,valgrind-python.supp}
827 %attr(755,root,root) %{_bindir}/python-config
828 %attr(755,root,root) %{_bindir}/python%{py_ver}-config
829 %attr(755,root,root) %{_libdir}/lib*.so
833 %dir %{py_libdir}/config
834 %attr(755,root,root) %{py_libdir}/config/makesetup
835 %attr(755,root,root) %{py_libdir}/config/install-sh
836 %{py_libdir}/config/Makefile
837 %{py_libdir}/config/Makefile.pre.in
838 %{py_libdir}/config/Setup
839 %{py_libdir}/config/Setup.config
840 %{py_libdir}/config/Setup.local
841 %{py_libdir}/config/config.c
842 %{py_libdir}/config/config.c.in
843 %{py_libdir}/config/python.o
846 %defattr(644,root,root,755)
847 %attr(-,root,root) %{py_scriptdir}/*.py
848 %{py_scriptdir}/plat-*/*.py
849 %{py_scriptdir}/bsddb/*.py
850 %{py_scriptdir}/ctypes/*.py
851 %{py_scriptdir}/ctypes/macholib/*.py
852 #%{py_scriptdir}/compiler/*.py
853 %{py_scriptdir}/curses/*.py
854 %{py_scriptdir}/distutils/*.py
855 %{py_scriptdir}/distutils/command/*.py
856 %{py_scriptdir}/email/*.py
857 %{py_scriptdir}/email/mime/*.py
858 %{py_scriptdir}/hotshot/*.py
859 %{py_scriptdir}/logging/*.py
860 %{py_scriptdir}/sqlite3/*.py
861 %{py_scriptdir}/wsgiref/*.py
862 %{py_scriptdir}/xml/*.py
863 %{py_scriptdir}/xml/dom/*.py
864 %{py_scriptdir}/xml/etree/*.py
865 %{py_scriptdir}/xml/parsers/*.py
866 %{py_scriptdir}/xml/sax/*.py
867 %{py_scriptdir}/encodings/*.py
868 %{py_scriptdir}/idlelib/*.py
871 %defattr(644,root,root,755)
873 /etc/shrc.d/python*-devel*
875 %attr(755,root,root) %{_bindir}/pygettext%{py_ver}
877 %attr(755,root,root) %{py_dyndir}/_hotshot.so
878 %dir %{py_scriptdir}/hotshot
879 %{py_scriptdir}/hotshot/*.py[co]
880 %{py_scriptdir}/pdb.py[co]
881 %{py_scriptdir}/profile.py[co]
882 %{py_scriptdir}/pstats.py[co]
883 %{py_scriptdir}/timeit.py[co]
886 %defattr(644,root,root,755)
890 %defattr(644,root,root,755)
891 %{_examplesdir}/%{name}-%{version}
895 #%defattr(644,root,root,755)
896 #%doc Python-Docs-%{version}%{beta}/*
900 %defattr(644,root,root,755)
906 %defattr(644,root,root,755)
907 %{py_scriptdir}/lib-tk
908 %attr(755,root,root) %{py_dyndir}/_tkinter.so