SPECS: python30.spec - no conflicts with 2.x

arekm arekm at pld-linux.org
Sun Sep 2 21:18:30 CEST 2007


Author: arekm                        Date: Sun Sep  2 19:18:30 2007 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- no conflicts with 2.x

---- Files affected:
SPECS:
   python30.spec (1.3 -> 1.4) 

---- Diffs:

================================================================
Index: SPECS/python30.spec
diff -u SPECS/python30.spec:1.3 SPECS/python30.spec:1.4
--- SPECS/python30.spec:1.3	Sun Sep  2 20:49:47 2007
+++ SPECS/python30.spec	Sun Sep  2 21:18:25 2007
@@ -1,7 +1,4 @@
 # $Revision$, $Date$
-# TODO:
-# - conflicts with python.spec
-# - %files
 
 # Conditional build:
 %bcond_with	info			# info pages (requires emacs)
@@ -231,28 +228,28 @@
 %description modules-sqlite -l pl.UTF-8
 Oficjalnie rozprowadzany moduł sqlite języka Python.
 
-%package -n pydoc
+%package -n pydoc30
 Summary:	Python interactive module documentation access support
 Summary(pl.UTF-8):	Interaktywne korzystanie z dokumentacji modułów języka Python
 Group:		Applications
 Requires:	%{name}-modules = %{epoch}:%{version}-%{release}
 
-%description -n pydoc
+%description -n pydoc30
 Python interactive module documentation access support.
 
-%description -n pydoc -l pl.UTF-8
+%description -n pydoc30 -l pl.UTF-8
 Interaktywne korzystanie z dokumentacji modułów języka Python.
 
-%package -n idle
+%package -n idle30
 Summary:	IDE for Python language
 Summary(pl.UTF-8):	IDE dla języka Python
 Group:		Applications
 Requires:	%{name}-tkinter = %{epoch}:%{version}-%{release}
 
-%description -n idle
+%description -n idle30
 IDE for Python language.
 
-%description -n idle -l pl.UTF-8
+%description -n idle30 -l pl.UTF-8
 IDE dla języka Python.
 
 %package devel
@@ -267,6 +264,7 @@
 Summary(uk.UTF-8):	Бібліотеки та хедери для програмування на мові Python
 Group:		Development/Languages/Python
 Requires:	%{name}-libs = %{epoch}:%{version}-%{release}
+Obsoletes:	python-devel
 
 %description devel
 The Python interpreter is relatively easy to extend with dynamically
@@ -529,7 +527,7 @@
 binlibdir=`echo build/lib.*`
 %{__make} test \
 	TESTOPTS="%{test_flags} %{test_list}" \
-	TESTPYTHON="LD_LIBRARY_PATH=`pwd` PYTHONHOME=`pwd` PYTHONPATH=`pwd`/Lib:$binlibdir ./python -tt"
+	TESTPYTHON="LD_LIBRARY_PATH=`pwd` PYTHONHOME=`pwd` PYTHONPATH=`pwd`/Lib:$binlibdir ./python%{py_ver} -tt"
 %endif
 
 %install
@@ -555,8 +553,6 @@
 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython.so
 ln -sf libpython%{py_ver}.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libpython%{py_ver}.so
 
-rm -f $RPM_BUILD_ROOT%{_bindir}/python%{py_ver}
-
 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
 cp -a Tools Demo $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
 
@@ -566,31 +562,37 @@
 
 # for python devel tools
 for script in timeit profile pdb pstats; do
-    echo alias $script.py=\"python -m ${script}\"
-done > $RPM_BUILD_ROOT/etc/shrc.d/python-devel.sh
+    echo alias ${script}%{py_ver}.py=\"python%{py_ver} -m ${script}\"
+done > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh
 
-echo alias pygettext.py='"pygettext"' \
-	>> $RPM_BUILD_ROOT/etc/shrc.d/python-devel.sh
+echo alias pygettext%{py_ver}.py='"pygettext%{py_ver}"' \
+	>> $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh
 
 sed 's/=/ /' \
-	< $RPM_BUILD_ROOT/etc/shrc.d/python-devel.sh \
-	> $RPM_BUILD_ROOT/etc/shrc.d/python-devel.csh
+	< $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.sh \
+	> $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-devel.csh
 
 # for python modules
 for script in smtpd webbrowser; do
-    echo alias $script.py=\"python -m ${script}\"
-done > $RPM_BUILD_ROOT/etc/shrc.d/python-modules.sh
+    echo alias ${script}%{py_ver}.py=\"python%{py_ver} -m ${script}\"
+done > $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.sh
 
 sed 's/=/ /' \
-	< $RPM_BUILD_ROOT/etc/shrc.d/python-modules.sh \
-	> $RPM_BUILD_ROOT/etc/shrc.d/python-modules.csh
+	< $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.sh \
+	> $RPM_BUILD_ROOT/etc/shrc.d/python%{py_ver}-modules.csh
 
 # xgettext specific for Python code
 #
 # we will have two commands: pygettext.py (an alias) and pygettext;
 # this way there are no import (which is impossible now) conflicts and
 # pygettext.py is provided for compatibility
-install Tools/i18n/pygettext.py $RPM_BUILD_ROOT%{_bindir}/pygettext
+install Tools/i18n/pygettext.py $RPM_BUILD_ROOT%{_bindir}/pygettext%{py_ver}
+
+# add py_ver
+for script in idle pydoc; do
+	mv $RPM_BUILD_ROOT%{_bindir}/${script} $RPM_BUILD_ROOT%{_bindir}/${script}%{py_ver}
+done
+mv $RPM_BUILD_ROOT%{_mandir}/man1/python.1 $RPM_BUILD_ROOT%{_mandir}/man1/python%{py_ver}.1
 
 # just to cut the noise, as they are not packaged (now)
 # first tests
@@ -622,12 +624,13 @@
 
 %files
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/python
+#%attr(755,root,root) %{_bindir}/python
+%attr(755,root,root) %{_bindir}/python%{py_ver}
 %{_mandir}/man1/*
 
 %files modules
 %defattr(644,root,root,755)
-/etc/shrc.d/python-modules*
+/etc/shrc.d/python*-modules*
 %exclude %{py_scriptdir}/UserDict.py[co]
 %exclude %{py_scriptdir}/codecs.py[co]
 %exclude %{py_scriptdir}/copy_reg.py[co]
@@ -805,14 +808,14 @@
 %dir %{py_scriptdir}/encodings
 %{py_scriptdir}/encodings/*.py[co]
 
-%files -n pydoc
+%files -n pydoc30
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/pydoc
+%attr(755,root,root) %{_bindir}/pydoc%{py_ver}
 %{py_scriptdir}/pydoc.py[co]
 
-%files -n idle
+%files -n idle30
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/idle
+%attr(755,root,root) %{_bindir}/idle%{py_ver}
 %dir %{py_scriptdir}/idlelib
 %dir %{py_scriptdir}/idlelib/Icons
 %{py_scriptdir}/idlelib/*.py[co]
@@ -868,9 +871,9 @@
 %files devel-tools
 %defattr(644,root,root,755)
 %doc Lib/pdb.doc
-/etc/shrc.d/python-devel*
+/etc/shrc.d/python*-devel*
 
-%attr(755,root,root) %{_bindir}/pygettext
+%attr(755,root,root) %{_bindir}/pygettext%{py_ver}
 
 %attr(755,root,root) %{py_dyndir}/_hotshot.so
 %dir %{py_scriptdir}/hotshot
@@ -889,9 +892,9 @@
 %{_examplesdir}/%{name}-%{version}
 
 
-%files doc
-%defattr(644,root,root,755)
-%doc Python-Docs-%{version}%{beta}/*
+#%files doc
+#%defattr(644,root,root,755)
+#%doc Python-Docs-%{version}%{beta}/*
 
 %if %{with info}
 %files doc-info
@@ -912,6 +915,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.4  2007/09/02 19:18:25  arekm
+- no conflicts with 2.x
+
 Revision 1.3  2007/09/02 18:49:47  arekm
 - drop old obsoletes
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/python30.spec?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list