More android support
Conflicts: Makefile.in cmakeFiles/rustllvm.cmake
This commit is contained in:
parent
987f824f23
commit
4fb4be8f17
8 changed files with 834 additions and 3 deletions
|
|
@ -2,4 +2,14 @@
|
|||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#include "execinfo.h"
|
||||
#ifndef _RUST_ANDROID_DUMMY_H
|
||||
#define _RUST_ANDROID_DUMMY_H
|
||||
|
||||
int backtrace (void **__array, int __size);
|
||||
|
||||
char **backtrace_symbols (void *__const *__array, int __size);
|
||||
|
||||
void backtrace_symbols_fd (void *__const *__array, int __size, int __fd);
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ last_os_error() {
|
|||
task->fail();
|
||||
return NULL;
|
||||
}
|
||||
#elif defined(_GNU_SOURCE)
|
||||
#elif defined(_GNU_SOURCE) && !defined(__ANDROID__)
|
||||
char cbuf[BUF_BYTES];
|
||||
char *buf = strerror_r(errno, cbuf, sizeof(cbuf));
|
||||
if (!buf) {
|
||||
|
|
|
|||
|
|
@ -9,9 +9,13 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#ifndef __WIN32__
|
||||
#ifndef __WIN32_
|
||||
#ifdef __ANDROID__
|
||||
#include "rust_android_dummy.h"
|
||||
#else
|
||||
#include <execinfo.h>
|
||||
#endif
|
||||
#endif
|
||||
#include <iostream>
|
||||
#include <algorithm>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue