summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Calin Juravle <calin@google.com> 2015-07-02 12:52:48 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2015-07-02 12:52:48 +0000
commit06b6da5ccbf9246c697b8cf1be0ba58ce616521d (patch)
treebd9953b38f6b798650c992ee131d6c5a40cdc6a4
parenta3529ea5ec5c494647d72e219263d4ca374ca2ff (diff)
parent9b369143615cb0eb836d2f1864d7d76da0668f1b (diff)
Merge "Fix mac build: use -lrt only on linux."
-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