summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Calin Juravle <calin@google.com> 2015-07-02 13:48:37 +0100
committer Calin Juravle <calin@google.com> 2015-07-02 13:51:43 +0100
commit9b369143615cb0eb836d2f1864d7d76da0668f1b (patch)
tree46898743da01de537a44990ab099f425d1689c59
parentdc5616146966369550f66e2a8866e142763bbefe (diff)
Fix mac build: use -lrt only on linux.
Change-Id: I25e6058d9003fa52ef3c8bd153c2108712ce7f96
-rw-r--r--build/Android.executable.mk6
1 files changed, 5 insertions, 1 deletions
diff --git a/build/Android.executable.mk b/build/Android.executable.mk
index fdb2be112d..a251c92464 100644
--- a/build/Android.executable.mk
+++ b/build/Android.executable.mk
@@ -93,14 +93,18 @@ define build-art-executable
else
LOCAL_CFLAGS += $(ART_HOST_NON_DEBUG_CFLAGS)
endif
+ LOCAL_LDLIBS += -lpthread -ldl
ifeq ($$(art_static_or_shared),static)
LOCAL_LDFLAGS += -static
# We need this because GC stress mode makes use of _Unwind_GetIP and _Unwind_Backtrace and
# the symbols are also defined in libgcc_eh.a(unwind-dw2.o)
# TODO: Having this is not ideal as it might obscure errors. Try to get rid of it.
LOCAL_LDFLAGS += -z muldefs
+ ifeq ($$(HOST_OS),linux)
+ LOCAL_LDLIBS += -lrt
+ endif
endif
- LOCAL_LDLIBS += -lpthread -ldl -lrt
+
endif
# If dynamically linked add libart by default. Statically linked executables