patches/gcc/4.2.0/220-libstdc++-namespace.patch
author "Yann E. MORIN" <yann.morin.1998@free.fr>
Wed Dec 05 20:31:43 2012 +0100 (2012-12-05)
changeset 3134 863723936e24
parent 111 2e16b9fc302d
permissions -rw-r--r--
scripts/xldd: use user's sed and grep

xldd uses sed and grep as detected by ./configure. This works well if is
used on the machine that build the toolchain.

But if the user moves the toolchain to another machine where sed and grep
are not in the same directory (eg. /bin/sed vs. /usr/bin/sed), then xldd
will stop functionning.

Fix that by using ${SED} and ${GREP} if they are set in the environment.

Reported-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
yann@111
     1
diff -rup gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-4.2/libstdc++-v3/config/locale/uclibc/messages_members.h
yann@111
     2
--- gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/messages_members.h	2006-12-22 13:06:56.000000000 +0100
yann@111
     3
+++ gcc-4.2/libstdc++-v3/config/locale/uclibc/messages_members.h	2006-12-22 15:23:41.000000000 +0100
yann@111
     4
@@ -32,7 +32,8 @@
yann@111
     5
 //
yann@111
     6
 
yann@111
     7
 // Written by Benjamin Kosnik <bkoz@redhat.com>
yann@111
     8
-
yann@111
     9
+namespace std
yann@111
    10
+{
yann@111
    11
 #ifdef __UCLIBC_MJN3_ONLY__
yann@111
    12
 #warning fix prototypes for *textdomain funcs
yann@111
    13
 #endif
yann@111
    14
@@ -115,3 +116,4 @@
yann@111
    15
 	   this->_S_create_c_locale(this->_M_c_locale_messages, __s); 
yann@111
    16
 	 }
yann@111
    17
      }
yann@111
    18
+}
yann@111
    19
diff -rup gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/time_members.h gcc-4.2/libstdc++-v3/config/locale/uclibc/time_members.h
yann@111
    20
--- gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/time_members.h	2006-12-22 13:06:56.000000000 +0100
yann@111
    21
+++ gcc-4.2/libstdc++-v3/config/locale/uclibc/time_members.h	2006-12-22 15:20:31.000000000 +0100
yann@111
    22
@@ -33,7 +33,8 @@
yann@111
    23
 //
yann@111
    24
 
yann@111
    25
 // Written by Benjamin Kosnik <bkoz@redhat.com>
yann@111
    26
-
yann@111
    27
+namespace std
yann@111
    28
+{
yann@111
    29
   template<typename _CharT>
yann@111
    30
     __timepunct<_CharT>::__timepunct(size_t __refs) 
yann@111
    31
     : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), 
yann@111
    32
@@ -74,3 +75,4 @@
yann@111
    33
       delete _M_data; 
yann@111
    34
       _S_destroy_c_locale(_M_c_locale_timepunct); 
yann@111
    35
     }
yann@111
    36
+}