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