mirror of
https://git.suyu.dev/suyu/breakpad.git
synced 2026-01-06 14:38:19 +01:00
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
This commit is contained in:
parent
9c30407f7f
commit
cfc8628092
15 changed files with 248 additions and 26 deletions
|
|
@ -37,6 +37,8 @@
|
|||
#include <sys/syscall.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "third_party/lss/linux_syscall_support.h"
|
||||
|
||||
#if defined(__ARM_EABI__)
|
||||
#define TID_PTR_REGISTER "r3"
|
||||
#elif defined(__i386)
|
||||
|
|
@ -48,7 +50,7 @@
|
|||
#endif
|
||||
|
||||
void *thread_function(void *data) {
|
||||
volatile pid_t thread_id = syscall(SYS_gettid);
|
||||
volatile pid_t thread_id = syscall(__NR_gettid);
|
||||
register volatile pid_t *thread_id_ptr asm(TID_PTR_REGISTER) = &thread_id;
|
||||
while (true)
|
||||
asm volatile ("" : : "r" (thread_id_ptr));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue