diff options
author | Elijah Taylor <elijahtaylor@google.com> | 2013-02-01 00:04:20 +0400 |
---|---|---|
committer | Zoltan Varga <vargaz@gmail.com> | 2013-04-07 11:45:45 +0400 |
commit | 1e726ce7a38a92860acab28f4427813d2ba14c13 (patch) | |
tree | e832165ae65eab2a49361b4a50509e71214bb4b8 /libgc/dyn_load.c | |
parent | 28c53a39a4630ecb719a94ee6dd6801633799a89 (diff) |
NaCl runtime fixes
- fix compile/runtime issues caused by upstream changes
- add NaCl glibc support
- various changes to support running tests in NaCl glibc
from 'make check'
Diffstat (limited to 'libgc/dyn_load.c')
-rw-r--r-- | libgc/dyn_load.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libgc/dyn_load.c b/libgc/dyn_load.c index e4be3c7d183..ca7ce54f194 100644 --- a/libgc/dyn_load.c +++ b/libgc/dyn_load.c @@ -26,7 +26,7 @@ * None of this is safe with dlclose and incremental collection. * But then not much of anything is safe in the presence of dlclose. */ -#if defined(__linux__) && !defined(_GNU_SOURCE) +#if (defined(__linux__) || defined(__native_client__)) && !defined(_GNU_SOURCE) /* Can't test LINUX, since this must be define before other includes */ # define _GNU_SOURCE #endif @@ -54,7 +54,7 @@ #if !defined(SUNOS4) && !defined(SUNOS5DL) && !defined(IRIX5) && \ !defined(MSWIN32) && !defined(MSWINCE) && \ !(defined(ALPHA) && defined(OSF1)) && \ - !defined(HPUX) && !(defined(LINUX) && defined(__ELF__)) && \ + !defined(HPUX) && !((defined(LINUX) || defined(NACL)) && defined(__ELF__)) && \ !defined(RS6000) && !defined(SCO_ELF) && !defined(DGUX) && \ !(defined(FREEBSD) && defined(__ELF__)) && \ !(defined(OPENBSD) && (defined(__ELF__) || defined(M68K))) && \ @@ -91,7 +91,7 @@ # define ELFSIZE ARCH_ELFSIZE #endif -#if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \ +#if (defined(LINUX) || defined(NACL)) && defined(__ELF__) || defined(SCO_ELF) || \ (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \ (defined(OPENBSD) && defined(__ELF__)) || \ (defined(NETBSD) && defined(__ELF__)) || defined(HURD) @@ -297,7 +297,7 @@ void GC_register_dynamic_libraries() # endif /* !USE_PROC ... */ # endif /* SUNOS */ -#if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \ +#if (defined(LINUX) || defined(NACL)) && defined(__ELF__) || defined(SCO_ELF) || \ (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \ (defined(OPENBSD) && defined(__ELF__)) || \ (defined(NETBSD) && defined(__ELF__)) || defined(HURD) @@ -394,7 +394,7 @@ GC_bool GC_register_main_static_data() /* For glibc 2.2.4+. Unfortunately, it doesn't work for older */ /* versions. Thanks to Jakub Jelinek for most of the code. */ -# if defined(LINUX) /* Are others OK here, too? */ \ +# if (defined(LINUX) || defined(NACL)) /* Are others OK here, too? */ \ && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \ || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG))) |