diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2013-11-14 10:04:55 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2013-11-18 21:45:58 -0800 |
| commit | 508b7b996e5d557ec1c49e1d11563ecf4fc9d287 (patch) | |
| tree | 56afc4b9b834d4496c175a3ab701823dbba72e15 /src/rt/rust_android_dummy.cpp | |
| parent | e8bf0788027932a0b547819cc9edd13c40426e36 (diff) | |
| download | rust-508b7b996e5d557ec1c49e1d11563ecf4fc9d287.tar.gz rust-508b7b996e5d557ec1c49e1d11563ecf4fc9d287.zip | |
Move runtime files to C instead of C++
Explicitly have the only C++ portion of the runtime be one file with exception handling. All other runtime files must now live in C and be fully defined in C.
Diffstat (limited to 'src/rt/rust_android_dummy.cpp')
| -rw-r--r-- | src/rt/rust_android_dummy.cpp | 107 |
1 files changed, 0 insertions, 107 deletions
diff --git a/src/rt/rust_android_dummy.cpp b/src/rt/rust_android_dummy.cpp deleted file mode 100644 index 05869c010af..00000000000 --- a/src/rt/rust_android_dummy.cpp +++ /dev/null @@ -1,107 +0,0 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifdef __ANDROID__ - -#include "rust_android_dummy.h" -#include <math.h> -#include <errno.h> - -int backtrace(void **array, int size) { return 0; } - -char **backtrace_symbols(void *const *array, int size) { return 0; } - -void backtrace_symbols_fd (void *const *array, int size, int fd) {} - -extern "C" volatile int* __errno_location() { - return &errno; -} - -extern "C" float log2f(float f) -{ - return logf( f ) / logf( 2 ); -} - -extern "C" double log2( double n ) -{ - return log( n ) / log( 2 ); -} - -extern "C" void telldir() -{ -} - -extern "C" void seekdir() -{ -} - -extern "C" void mkfifo() -{ -} - -extern "C" void abs() -{ -} - -extern "C" void labs() -{ -} - -extern "C" void rand() -{ -} - -extern "C" void srand() -{ -} - -extern "C" void atof() -{ -} - -extern "C" int glob(const char *pattern, - int flags, - int (*errfunc) (const char *epath, int eerrno), - glob_t *pglob) -{ - return 0; -} - -extern "C" void globfree(glob_t *pglob) -{ -} - -extern "C" int pthread_atfork(void (*prefork)(void), - void (*postfork_parent)(void), - void (*postfork_child)(void)) -{ - return 0; -} - -extern "C" int mlockall(int flags) -{ - return 0; -} - -extern "C" int munlockall(void) -{ - return 0; -} - -extern "C" int shm_open(const char *name, int oflag, mode_t mode) -{ - return 0; -} - -extern "C" int shm_unlink(const char *name) -{ - return 0; -} - -extern "C" int posix_madvise(void *addr, size_t len, int advice) -{ - return 0; -} - -#endif |
