packages: gcc/gcc.spec - gcc-branch.diff updated. - libstdc++ python pretty...

pluto pluto at pld-linux.org
Fri Oct 15 23:44:39 CEST 2010


Author: pluto                        Date: Fri Oct 15 21:44:39 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- gcc-branch.diff updated.
- libstdc++ python pretty printers for gdb packaged.
- adapterized.
- nfy...

---- Files affected:
packages/gcc:
   gcc.spec (1.634 -> 1.635) 

---- Diffs:

================================================================
Index: packages/gcc/gcc.spec
diff -u packages/gcc/gcc.spec:1.634 packages/gcc/gcc.spec:1.635
--- packages/gcc/gcc.spec:1.634	Sat Oct  2 08:24:56 2010
+++ packages/gcc/gcc.spec	Fri Oct 15 23:44:34 2010
@@ -8,17 +8,9 @@
 #   /usr/bin/gjdoc
 #   /usr/share/man/man1/aot-compile.1.gz
 #   /usr/share/man/man1/gjdoc.1.gz
-#   /usr/share/gcc-4.5.0/python/libstdcxx/__init__.py (gdb stuff?)
-#   /usr/share/gcc-4.5.0/python/libstdcxx/v6/__init__.py
-#   /usr/share/gcc-4.5.0/python/libstdcxx/v6/printers.py
 #   /usr/share/python/aotcompile.py
 #   /usr/share/python/classfile.py
 #
-# - thin about cooperate with (or drop some parts of) 'python-gdb' package which also contains:
-#   /usr/lib{,64}/libstdc++.so.6.0.*-gdb.py
-#   /usr/share/python2.6/site-packages/libstdcxx
-#   ^--- our gdb.spec backported the stuff (like fc), so package here and rm in gdb package?
-#
 # Conditional build:
 %bcond_without	ada		# build without ADA support
 %bcond_without	cxx		# build without C++ support
@@ -36,6 +28,7 @@
 %bcond_without	x		# don't build libgcj Xlib-dependent AWTs (incl. GTK/Qt)
 %bcond_without	multilib	# build without multilib support (it needs glibc[32&64]-devel)
 %bcond_with	profiling	# build with profiling
+%bcond_without	python		# build without libstdc++ python pretty printers for gdb
 %bcond_without	bootstrap	# omit 3-stage bootstrap
 %bcond_with	tests		# torture gcc
 
@@ -137,6 +130,10 @@
 BuildRequires:	gmp-devel >= 4.1
 BuildRequires:	libmpc-devel
 BuildRequires:	mpfr-devel >= 2.3.0
+%if %{with python}
+BuildRequires:	python-devel
+BuildRequires:	rpm-pythonprov
+%endif
 BuildRequires:	rpmbuild(macros) >= 1.211
 BuildRequires:	texinfo >= 4.1
 BuildRequires:	zlib-devel
@@ -561,8 +558,8 @@
 written in Ada.
 
 %description -n libgnat-multilib-static -l pl.UTF-8
-Ten pakiet zawiera 32-bitowe wersje bibliotek statycznych dla programów
-napisanych w Adzie.
+Ten pakiet zawiera 32-bitowe wersje bibliotek statycznych dla
+programów napisanych w Adzie.
 
 %package c++
 Summary:	C++ support for gcc
@@ -688,6 +685,15 @@
 Ten pakiet ten zawiera 32-bitową wersję implementacji GNU biblioteki
 standardowej C++.
 
+%package -n libstdc++-gdb
+Summary:	libstdc++ pretty printers for GDB
+Group:		Development/Debuggers
+Requires:	python-gdb
+
+%description -n libstdc++-gdb
+This package contains Python scripts for GDB pretty printing of the
+libstdc++ types/containers.
+
 %package -n libstdc++-devel
 Summary:	Header files and documentation for C++ development
 Summary(de.UTF-8):	Header-Dateien zur Entwicklung mit C++
@@ -734,8 +740,8 @@
 Requires:	libstdc++-multilib = %{epoch}:%{version}-%{release}
 
 %description -n libstdc++-multilib-devel
-This package contains the development files for 32-bit version of
-the GNU implementation of the standard C++ library.
+This package contains the development files for 32-bit version of the
+GNU implementation of the standard C++ library.
 
 %description -n libstdc++-multilib-devel -l pl.UTF-8
 Ten pakiet zawiera pliki programistyczne 32-bitowej wersji
@@ -1484,6 +1490,23 @@
 rm -rf $gccdir/install-tools
 rm -rf $gccdir/include-fixed
 
+%if %{with python}
+for LIB in lib lib64; do
+	LIBPATH="$RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{_prefix}/$LIB"
+	install -d $LIBPATH
+	# basename is being run only for the native (non-biarch) file.
+	sed -e 's, at pythondir@,%{_datadir}/gdb,' \
+	  -e 's, at toolexeclibdir@,%{_prefix}/'"$LIB," \
+	  < libstdc++-v3/python/hook.in	\
+	  > $LIBPATH/$(basename $RPM_BUILD_ROOT/%{_prefix}/%{_lib}/libstdc++.so.*.*.*)-gdb.py
+done
+install -d $RPM_BUILD_ROOT%{py_sitescriptdir}
+cp -a libstdc++-v3/python/libstdcxx $RPM_BUILD_ROOT%{py_sitescriptdir}
+%py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
+%py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
+%py_postclean
+%endif
+
 %find_lang gcc
 %find_lang cpplib
 cat cpplib.lang >> gcc.lang
@@ -1880,6 +1903,16 @@
 %attr(755,root,root) %ghost %{_libdir32}/libstdc++.so.6
 %endif
 
+%if %{with python}
+%files -n libstdc++-gdb
+%defattr(644,root,root,755)
+%dir %{py_sitescriptdir}/libstdcxx
+%{py_sitescriptdir}/libstdcxx/*.py[co]
+%dir %{py_sitescriptdir}/libstdcxx/v6
+%{py_sitescriptdir}/libstdcxx/v6/*.py[co]
+%{_datadir}/gdb/auto-load/%{_prefix}/lib*/libstdc++.so.6.0.14-gdb.py
+%endif
+
 %files -n libstdc++-devel
 %defattr(644,root,root,755)
 %doc libstdc++-v3/doc/html
@@ -2185,6 +2218,12 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.635  2010/10/15 21:44:34  pluto
+- gcc-branch.diff updated.
+- libstdc++ python pretty printers for gdb packaged.
+- adapterized.
+- nfy...
+
 Revision 1.634  2010/10/02 06:24:56  qboosh
 - libffi note
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/gcc/gcc.spec?r1=1.634&r2=1.635&f=u



More information about the pld-cvs-commit mailing list