public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "chaoyingfu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug bootstrap/54209] [4.8 Regression] Failed to build gcc for Android/x86
Date: Thu, 09 Aug 2012 18:46:00 -0000	[thread overview]
Message-ID: <bug-54209-4-dZCJB97jyH@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-54209-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54209

--- Comment #4 from chaoyingfu at gcc dot gnu.org <chaoyingfu at gcc dot gnu.org> 2012-08-09 18:45:41 UTC ---
(In reply to comment #3)
> (In reply to comment #2)
> > MIPS provides a version of link.h in Android NDK as follows:
> > Ex:
> > From android-ndk-r8b/platforms/android-9/arch-mips/usr/include# cat link.h
> > /*
> >    For building unwind-dw2-fde-glibc.c for MIPS frame unwinding,
> >    we need to have <link.h> that defines struct dl_phdr_info,
> >    ELFW(type), and dl_iterate_phdr().
> > */
> > 
> > #include <sys/types.h>
> > #include <elf.h>
> > 
> > struct dl_phdr_info
> > {
> >     Elf32_Addr dlpi_addr;
> >     const char *dlpi_name;
> >     const Elf32_Phdr *dlpi_phdr;
> >     Elf32_Half dlpi_phnum;
> > };
> > 
> > #if _MIPS_SZPTR == 32
> > #define ElfW(type)      Elf32_##type
> > #elif _MIPS_SZPTR == 64
> > #define ElfW(type)      Elf64_##type
> > #endif
> > 
> > int
> > dl_iterate_phdr(int (*cb)(struct dl_phdr_info *info, size_t size, void *data),
> >                 void *data);
> > 
> >   For x86, you can create link.h as well.  Or we can guard this define with
> > MIPS targets.
> 
> Why isn't link.h in AOSP Bionic C library?

  ARM doesn't use eh_frame, so there is no need to create link.h at the
beginning for the Android project, I guess.  For MIPS, we create our own link.h
to work with eh_frame unwinding.  Thanks!


  parent reply	other threads:[~2012-08-09 18:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-09 15:55 [Bug bootstrap/54209] New: " hjl.tools at gmail dot com
2012-08-09 15:57 ` [Bug bootstrap/54209] " hjl.tools at gmail dot com
2012-08-09 16:41 ` hjl.tools at gmail dot com
2012-08-09 17:24 ` chaoyingfu at gcc dot gnu.org
2012-08-09 18:41 ` hjl.tools at gmail dot com
2012-08-09 18:46 ` chaoyingfu at gcc dot gnu.org [this message]
2012-08-09 19:09 ` hjl.tools at gmail dot com
2012-08-20 14:03 ` hjl.tools at gmail dot com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-54209-4-dZCJB97jyH@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).