Merge "Add -lm to the default libs for Linux & Darwin"

This commit is contained in:
Treehugger Robot
2017-09-27 07:08:57 +00:00
committed by Gerrit Code Review
5 changed files with 2 additions and 12 deletions

View File

@@ -291,10 +291,10 @@ my_ldlib_flags :=
my_shared_libraries += $(patsubst -l%,lib%,$(filter-out $(my_allowed_ldlibs),$(my_ldlibs)))
my_ldlibs := $(filter $(my_allowed_ldlibs),$(my_ldlibs))
else # LOCAL_IS_HOST_MODULE
# Add -ldl, -lpthread and -lrt to host builds to match the default behavior of
# Add -ldl, -lpthread, -lm and -lrt to host builds to match the default behavior of
# device builds
ifneq ($($(my_prefix)OS),windows)
my_ldlibs += -ldl -lpthread
my_ldlibs += -ldl -lpthread -lm
ifneq ($(HOST_OS),darwin)
my_ldlibs += -lrt
endif