patches/gcc/4.4.5/350-index_macro.patch
author Anthony Foiani <anthony.foiani@gmail.com>
Thu Apr 26 19:55:59 2012 -0600 (2012-04-26)
changeset 2939 58974be61289
permissions -rw-r--r--
Allow multi-word "install" command.

Autoconf can determine that the correct install command includes flags,
e.g., "/usr/bin/install -c". When using this as a command, we can't
enclose the value in double-quotes, as that makes some shells use the
whole expression as a filename:

# this is the value returned by autoconf and stored in CT_install
$ ins="/usr/bin/install -c"

# if we call it with quotes, the command is not found
$ "${ins}"
bash: /usr/bin/install -c: No such file or directory

# removing the quotes lets it work as expected
$ ${ins}
/usr/bin/install: missing file operand
Try `/usr/bin/install --help' for more information.

Signed-Off-By: Anthony Foiani <anthony.foiani@gmail.com>
yann@2149
     1
-= BEGIN original header =-
yann@2149
     2
Original patch from gentoo: gentoo/src/patchsets/gcc/4.3.1/uclibc/90_all_304-index_macro.patch
yann@2149
     3
-= END original header =-
yann@2149
     4
yann@2149
     5
diff -durN gcc-4.4.5.orig/libstdc++-v3/include/ext/rope gcc-4.4.5/libstdc++-v3/include/ext/rope
yann@2149
     6
--- gcc-4.4.5.orig/libstdc++-v3/include/ext/rope	2009-04-10 01:23:07.000000000 +0200
yann@2149
     7
+++ gcc-4.4.5/libstdc++-v3/include/ext/rope	2010-10-09 23:12:51.000000000 +0200
yann@2149
     8
@@ -54,6 +54,9 @@
yann@2149
     9
 #include <bits/gthr.h>
yann@2149
    10
 #include <tr1/functional>
yann@2149
    11
 
yann@2149
    12
+/* cope w/ index defined as macro, SuSv3 proposal */
yann@2149
    13
+#undef index
yann@2149
    14
+
yann@2149
    15
 # ifdef __GC
yann@2149
    16
 #   define __GC_CONST const
yann@2149
    17
 # else
yann@2149
    18
diff -durN gcc-4.4.5.orig/libstdc++-v3/include/ext/ropeimpl.h gcc-4.4.5/libstdc++-v3/include/ext/ropeimpl.h
yann@2149
    19
--- gcc-4.4.5.orig/libstdc++-v3/include/ext/ropeimpl.h	2009-04-10 01:23:07.000000000 +0200
yann@2149
    20
+++ gcc-4.4.5/libstdc++-v3/include/ext/ropeimpl.h	2010-10-09 23:12:51.000000000 +0200
yann@2149
    21
@@ -49,6 +49,9 @@
yann@2149
    22
 #include <ext/memory> // For uninitialized_copy_n
yann@2149
    23
 #include <ext/numeric> // For power
yann@2149
    24
 
yann@2149
    25
+/* cope w/ index defined as macro, SuSv3 proposal */
yann@2149
    26
+#undef index
yann@2149
    27
+
yann@2149
    28
 _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
yann@2149
    29
 
yann@2149
    30
   using std::size_t;