Don't use lpthread for Android
authorMarco Costalba <mcostalba@gmail.com>
Sun, 1 Sep 2013 20:37:26 +0000 (13:37 -0700)
committerMarco Costalba <mcostalba@gmail.com>
Sun, 1 Sep 2013 20:48:09 +0000 (13:48 -0700)
Thanks to Peter Osterlund for the feedback.

No functional change.

src/Makefile

index 67cd382a53ed30482387df42cc88adb017fc755c..860b146a4fbe88a6a6aab515da073e6d6b153f9e 100644 (file)
@@ -263,9 +263,12 @@ endif
 
 ### On mingw use Windows threads, otherwise POSIX
 ifneq ($(comp),mingw)
-       # Haiku has pthreads in its libroot, so only link it in on other platforms
-       ifneq ($(UNAME),Haiku)
-               LDFLAGS += -lpthread
+       # On Android Bionic's C library comes with its own pthread implementation bundled in
+       ifneq ($(arch),armv7)
+               # Haiku has pthreads in its libroot, so only link it in on other platforms
+               ifneq ($(UNAME),Haiku)
+                       LDFLAGS += -lpthread
+               endif
        endif
 endif