Patchwork PATCH: PR bootstrap/54209: [4.8 Regression] Failed to build gcc for Android/x86

login
register
mail settings
Submitter Fu, Chao-Ying
Date Aug. 9, 2012, 6:11 p.m.
Message ID <7C6479EB2BF52547AC332FD6034646DA01448EB6A5@exchdb03.mips.com>
Download mbox | patch
Permalink /patch/176205/
State New
Headers show

Comments

Fu, Chao-Ying - Aug. 9, 2012, 6:11 p.m.
> > Hi,
> > 
> > Bionic C library doesn't provide link.h.  This patch 
> reverts revision
> > 186788:
> > 
> > http://gcc.gnu.org/ml/gcc-cvs/2012-04/msg00740.html
> > 
> > OK to install?
> > 
> > Thanks.
> > 
> > H.J.
> > ---
> > 2012-08-09  H.J. Lu  <hongjiu.lu@intel.com>
> > 
> > 	PR bootstrap/54209
> > 	* unwind-dw2-fde-dip.c (USE_PT_GNU_EH_FRAME): Don't define for
> > 	Bionic C library.
> > 
> > diff --git a/libgcc/unwind-dw2-fde-dip.c 
> b/libgcc/unwind-dw2-fde-dip.c
> > index 92f8ab5..f57dc8c 100644
> > --- a/libgcc/unwind-dw2-fde-dip.c
> > +++ b/libgcc/unwind-dw2-fde-dip.c
> > @@ -54,11 +54,6 @@
> >  #endif
> >  
> >  #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
> > -    && defined(__BIONIC__)
> > -# define USE_PT_GNU_EH_FRAME
> > -#endif
> > -
> > -#if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
> >      && defined(__FreeBSD__) && __FreeBSD__ >= 7
> >  # define ElfW __ElfN
> >  # define USE_PT_GNU_EH_FRAME
> > 
> 
>   How about this patch?  Just enable it for MIPS that 
> provides link.h in Android NDK.
> Thanks a lot!
> 
> Regards,
> Chao-ying
> 
> Index: unwind-dw2-fde-dip.c
> ===================================================================
> --- unwind-dw2-fde-dip.c        (revision 190260)
> +++ unwind-dw2-fde-dip.c        (working copy)
> @@ -55,6 +55,7 @@
> 
>  #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
>      && defined(__BIONIC__)
> +    && defined(__mips__)
>  # define USE_PT_GNU_EH_FRAME
>  #endif
> 

  Sorry, I forgot \ in the previous patch.
Ex:
H.J. Lu - Aug. 9, 2012, 6:35 p.m.
On Thu, Aug 9, 2012 at 11:11 AM, Fu, Chao-Ying <fu@mips.com> wrote:
>> > Hi,
>> >
>> > Bionic C library doesn't provide link.h.  This patch
>> reverts revision
>> > 186788:
>> >
>> > http://gcc.gnu.org/ml/gcc-cvs/2012-04/msg00740.html
>> >
>> > OK to install?
>> >
>> > Thanks.
>> >
>> > H.J.
>> > ---
>> > 2012-08-09  H.J. Lu  <hongjiu.lu@intel.com>
>> >
>> >     PR bootstrap/54209
>> >     * unwind-dw2-fde-dip.c (USE_PT_GNU_EH_FRAME): Don't define for
>> >     Bionic C library.
>> >
>> > diff --git a/libgcc/unwind-dw2-fde-dip.c
>> b/libgcc/unwind-dw2-fde-dip.c
>> > index 92f8ab5..f57dc8c 100644
>> > --- a/libgcc/unwind-dw2-fde-dip.c
>> > +++ b/libgcc/unwind-dw2-fde-dip.c
>> > @@ -54,11 +54,6 @@
>> >  #endif
>> >
>> >  #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
>> > -    && defined(__BIONIC__)
>> > -# define USE_PT_GNU_EH_FRAME
>> > -#endif
>> > -
>> > -#if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
>> >      && defined(__FreeBSD__) && __FreeBSD__ >= 7
>> >  # define ElfW __ElfN
>> >  # define USE_PT_GNU_EH_FRAME
>> >
>>
>>   How about this patch?  Just enable it for MIPS that
>> provides link.h in Android NDK.
>> Thanks a lot!
>>
>> Regards,
>> Chao-ying
>>
>> Index: unwind-dw2-fde-dip.c
>> ===================================================================
>> --- unwind-dw2-fde-dip.c        (revision 190260)
>> +++ unwind-dw2-fde-dip.c        (working copy)
>> @@ -55,6 +55,7 @@
>>
>>  #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
>>      && defined(__BIONIC__)
>> +    && defined(__mips__)
>>  # define USE_PT_GNU_EH_FRAME
>>  #endif
>>
>
>   Sorry, I forgot \ in the previous patch.
> Ex:
> Index: unwind-dw2-fde-dip.c
> ===================================================================
> --- unwind-dw2-fde-dip.c        (revision 190260)
> +++ unwind-dw2-fde-dip.c        (working copy)
> @@ -54,7 +54,8 @@
>  #endif
>
>  #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
> -    && defined(__BIONIC__)
> +    && defined(__BIONIC__) \
> +    && defined(__mips__)
>  # define USE_PT_GNU_EH_FRAME
>  #endif


Where does mips link.h come from?  I didn't see it in AOSP Bionic C library.
Fu, Chao-Ying - Aug. 9, 2012, 6:39 p.m.
> 
> Where does mips link.h come from?  I didn't see it in AOSP 
> Bionic C library.
> 
> -- 
> H.J.
> 

 It's from development/ndk/platforms/android-9/arch-mips/include/link.h from AOSP checkout.

Regards,
Chao-ying

Patch

Index: unwind-dw2-fde-dip.c
===================================================================
--- unwind-dw2-fde-dip.c        (revision 190260)
+++ unwind-dw2-fde-dip.c        (working copy)
@@ -54,7 +54,8 @@ 
 #endif

 #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
-    && defined(__BIONIC__)
+    && defined(__BIONIC__) \
+    && defined(__mips__)
 # define USE_PT_GNU_EH_FRAME
 #endif