diff options
author | ted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-20 15:51:38 +0000 |
---|---|---|
committer | ted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-20 15:51:38 +0000 |
commit | cfc8628092e17069d8d6c7068d4f21d9baabe077 (patch) | |
tree | 43e9d016602ec4944511a3f02981a004a6225ef5 /src/client/linux/minidump_writer/linux_dumper.h | |
parent | Double stack scanning length in stackwalker (diff) | |
download | breakpad-cfc8628092e17069d8d6c7068d4f21d9baabe077.tar.xz |
Add support for building the Linux client code using the Android NDK
r=mwu at http://breakpad.appspot.com/212001/show
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@716 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/linux/minidump_writer/linux_dumper.h')
-rw-r--r-- | src/client/linux/minidump_writer/linux_dumper.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/client/linux/minidump_writer/linux_dumper.h b/src/client/linux/minidump_writer/linux_dumper.h index b0c479a9..71d1188f 100644 --- a/src/client/linux/minidump_writer/linux_dumper.h +++ b/src/client/linux/minidump_writer/linux_dumper.h @@ -34,18 +34,38 @@ #include <linux/limits.h> #include <stdint.h> #include <sys/types.h> +#if !defined(__ANDROID__) #include <sys/user.h> +#endif #include "common/memory.h" #include "google_breakpad/common/minidump_format.h" namespace google_breakpad { +#if defined(__i386) || defined(__x86_64) typedef typeof(((struct user*) 0)->u_debugreg[0]) debugreg_t; +#endif // Typedef for our parsing of the auxv variables in /proc/pid/auxv. #if defined(__i386) || defined(__ARM_EABI__) +#if !defined(__ANDROID__) typedef Elf32_auxv_t elf_aux_entry; +#else +// Android is missing this structure definition +typedef struct +{ + uint32_t a_type; /* Entry type */ + union + { + uint32_t a_val; /* Integer value */ + } a_un; +} elf_aux_entry; + +#if !defined(AT_SYSINFO_EHDR) +#define AT_SYSINFO_EHDR 33 +#endif +#endif // __ANDROID__ #elif defined(__x86_64__) typedef Elf64_auxv_t elf_aux_entry; #endif @@ -76,8 +96,12 @@ struct ThreadInfo { #elif defined(__ARM_EABI__) // Mimicking how strace does this(see syscall.c, search for GETREGS) +#if defined(__ANDROID__) + struct pt_regs regs; +#else struct user_regs regs; struct user_fpregs fpregs; +#endif // __ANDROID__ #endif }; |