]> granicus.if.org Git - gc/commitdiff
* include/private/gcconfig.h: Android platforms are built atop Linux,
authorJonathan Pryor <jpryor@novell.com>
Mon, 19 Apr 2010 18:49:27 +0000 (18:49 +0000)
committerguest <ivmai@mail.ru>
Fri, 29 Jul 2011 11:31:22 +0000 (15:31 +0400)
  don't use glibc, and uses `environ` instead of `__environ`.
* configure.in: Use AC_CHECK_LIB() to check for pthread instead of
  just blindly linking to -lpthread, as Android includes pthread
  support within libc and doesn't provide a separate libpthread.

svn path=/trunk/mono/; revision=155747

ChangeLog
configure.in
include/private/gcconfig.h

index b6235a2838919710f08c7b8696c992cd28585606..1b0db0230be361ded6f3923ca7a8fa405754631a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2010-04-19  Jonathan Pryor  <jpryor@novell.com>
+
+       * include/private/gcconfig.h: Android platforms are built atop Linux,
+         don't use glibc, and uses `environ` instead of `__environ`.
+       * configure.in: Use AC_CHECK_LIB() to check for pthread instead of
+         just blindly linking to -lpthread, as Android includes pthread
+         support within libc and doesn't provide a separate libpthread.
+
 2010-03-09  Zoltan Varga  <vargaz@gmail.com>
 
        * include/private/gc_locks.h: Fix amd64 build with newer gcc's.
index 2749d08b13b96bbe437111f70bdfe617602b3ea3..2f7e173189b28e73b847343718fbfe356f6e6963 100644 (file)
@@ -84,7 +84,7 @@ case "$THREADS" in
     ;;
  posix | pthreads)
     THREADS=posix
-    THREADDLLIBS=-lpthread
+    AC_CHECK_LIB(pthread, pthread_self, THREADDLLIBS="-lpthread",,)
     case "$host" in
      x86-*-linux* | ia64-*-linux* | i386-*-linux* | i486-*-linux* | i586-*-linux* | i686-*-linux* | x86_64-*-linux* | alpha*-*-linux* | s390*-*-linux* | sparc*-*-linux* | powerpc-*-linux*)
        AC_DEFINE(GC_LINUX_THREADS)
index 860195c857f07c7aaf9ed6f6c5c43cccf3807794..3d12de892322422989db8f04bba53bf820c5215a 100644 (file)
 #           if defined(__GLIBC__)&& __GLIBC__>=2
 #              define SEARCH_FOR_DATA_START
 #           else /* !GLIBC2 */
+#              if defined(PLATFORM_ANDROID)
+#                      define __environ environ
+#              endif
                extern char **__environ;
 #              define DATASTART ((ptr_t)(&__environ))
                              /* hideous kludge: __environ is the first */