patches/gcc/3.3.1/pr11949-fix.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Tue May 08 17:48:32 2007 +0000 (2007-05-08)
changeset 78 c3868084d81a
permissions -rw-r--r--
Huge fixes to glibc build, so that we can build at least (and at last):
- use ports addon even when installing headers,
- use optimisation (-O) when installing headers, to avoid unnecessary warnings (thanks Robert P. J. DAY for pointing this out!),
- lowest kernel version to use is only X.Y.Z, not X.Y.Z.T,
- a bit of preparations for NPTL (RSN I hope),
- fix fixing the linker scripts (changing the backup file is kind of useless and stupid);

Shut uClibc finish step: there really is nothing to do;

Add a patch for glibc-2.3.6 weak aliases handling on some archs (ARM and ALPHA at least);

Did not catch the make errors: fixed the pattern matching in scripts/functions;

Introduce a new log level, ALL:
- send components' build messages there,
- DEBUG log level is destined only for crosstool-NG debug messages,
- migrate sub-actions to use appropriate log levels;

Update the armeb-unknown-linux-gnu sample:
- it builds!
- uses gcc-4.0.4 and glibc-2.3.6,
- updated to latest config options set.
     1 Message-Id: 20030822160024.GA305@ftbfs.org
     2 From: Matt Kraai kraai at alumni dot cmu dot edu
     3 To: gcc-patches at gcc dot gnu dot org
     4 Date: Fri, 22 Aug 2003 09:00:24 -0700
     5 Subject: PR 11949
     6 
     7 Howdy,
     8 
     9 I've backported the following patch from the mainline to the 3.3
    10 branch to fix PR 11949.
    11 
    12 Bootstrapped and regression tested on powerpc-unknown-linux-gnu.
    13 
    14 OK to commit?
    15 
    16 	PR c/11949
    17 	Backport from mainline:
    18 
    19 	2003-05-05  Aldy Hernandez  aldyh@redhat.com
    20 
    21 	* testsuite/gcc.c-torture/compile/simd-6.c: New.
    22 
    23 	* c-typeck.c (digest_init): Handle arrays of vector constants.
    24 
    25 Index: gcc/c-typeck.c
    26 ===================================================================
    27 RCS file: /cvs/gcc/gcc/gcc/c-typeck.c,v
    28 retrieving revision 1.213.2.8
    29 diff -3 -c -p -r1.213.2.8 c-typeck.c
    30 *** gcc/gcc/c-typeck.c	19 Aug 2003 01:42:35 -0000	1.213.2.8
    31 --- gcc/gcc/c-typeck.c	22 Aug 2003 09:24:03 -0000
    32 *************** digest_init (type, init, require_constan
    33 *** 4765,4772 ****
    34     if (code == VECTOR_TYPE
    35         && comptypes (TREE_TYPE (inside_init), type)
    36         && TREE_CONSTANT (inside_init))
    37 !     return build_vector (type, TREE_OPERAND (inside_init, 1));
    38 ! 
    39   
    40     /* Any type can be initialized
    41        from an expression of the same type, optionally with braces.  */
    42 --- 4765,4778 ----
    43     if (code == VECTOR_TYPE
    44         && comptypes (TREE_TYPE (inside_init), type)
    45         && TREE_CONSTANT (inside_init))
    46 !     {
    47 !       if (TREE_CODE (inside_init) == VECTOR_CST
    48 ! 	  && comptypes (TYPE_MAIN_VARIANT (TREE_TYPE (inside_init)),
    49 ! 			TYPE_MAIN_VARIANT (type)))
    50 ! 	return inside_init;
    51 !       else
    52 ! 	return build_vector (type, CONSTRUCTOR_ELTS (inside_init));
    53 !     }
    54   
    55     /* Any type can be initialized
    56        from an expression of the same type, optionally with braces.  */
    57 
    58 typedef int __attribute__((mode(V2SI))) vec;
    59 
    60 vec a[] = {(vec) {1, 2}, {3, 4}};
    61