| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <sys/types.h> // Include something that will define __GLIBC__. | 5 #include <sys/types.h> // Include something that will define __GLIBC__. |
| 6 #include "nacl_io/kernel_wrap.h" // IRT_EXT is turned on in this header. |
| 6 | 7 |
| 7 // The entire file is wrapped in this #if. We do this so this .cc file can be | 8 #if !defined(NACL_IO_IRT_EXT) && defined(__native_client__) && \ |
| 8 // compiled, even on a non-glibc build. | 9 defined(__GLIBC__) |
| 9 // The ARM glibc toolchain uses a different IRT hooks mechanism and is not | |
| 10 // yet supported by nacl_io. | |
| 11 #if defined(__native_client__) && defined(__GLIBC__) && !defined(__arm__) | |
| 12 | |
| 13 #include "nacl_io/kernel_wrap.h" | |
| 14 | 10 |
| 15 #include <alloca.h> | 11 #include <alloca.h> |
| 16 #include <assert.h> | 12 #include <assert.h> |
| 17 #include <dirent.h> | 13 #include <dirent.h> |
| 18 #include <errno.h> | 14 #include <errno.h> |
| 19 #include <irt.h> | 15 #include <irt.h> |
| 20 #include <irt_syscalls.h> | 16 #include <irt_syscalls.h> |
| 21 #include <nacl_stat.h> | 17 #include <nacl_stat.h> |
| 22 #include <string.h> | 18 #include <string.h> |
| 23 #include <sys/stat.h> | 19 #include <sys/stat.h> |
| (...skipping 639 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 663 if (s_wrapped) { | 659 if (s_wrapped) { |
| 664 LOG_TRACE("kernel_wrap_uninit"); | 660 LOG_TRACE("kernel_wrap_uninit"); |
| 665 EXPAND_SYMBOL_LIST_OPERATION(USE_REAL) | 661 EXPAND_SYMBOL_LIST_OPERATION(USE_REAL) |
| 666 s_wrapped = false; | 662 s_wrapped = false; |
| 667 } | 663 } |
| 668 } | 664 } |
| 669 | 665 |
| 670 EXTERN_C_END | 666 EXTERN_C_END |
| 671 | 667 |
| 672 #endif // defined(__native_client__) && defined(__GLIBC__) | 668 #endif // defined(__native_client__) && defined(__GLIBC__) |
| OLD | NEW |