From bfc436969d342a023280a227d6b7072fbb133d07 Mon Sep 17 00:00:00 2001 From: Ying Wang Date: Thu, 5 Mar 2015 11:29:30 -0800 Subject: [PATCH] Reorder lib paths in transform-bc-to-so to avoid build race condition. We should put the NDK library path before $(TARGET_OUT_INTERMEDIATE_LIBRARIES), so that we link against the NDK libc/libm, instead of the platform libc/libm in $(TARGET_OUT_INTERMEDIATE_LIBRARIES), which may still being written out, because we don't have dependency on them. Bug: 19613709 Change-Id: I26a8b272e38b7436bca3324246b21cd71349662b --- core/definitions.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/definitions.mk b/core/definitions.mk index e0f61c53a4..4bc51d3098 100644 --- a/core/definitions.mk +++ b/core/definitions.mk @@ -885,7 +885,7 @@ $(hide) $(PRIVATE_CXX) -shared -Wl,-soname,$(notdir $@) -nostdlib \ $(dir $@)/$(notdir $(<:.bc=.o)) \ $(RS_PREBUILT_COMPILER_RT) \ -o $@ $(TARGET_GLOBAL_LDFLAGS) -Wl,--hash-style=sysv -L prebuilts/gcc/ \ - -L $(TARGET_OUT_INTERMEDIATE_LIBRARIES) $(RS_PREBUILT_LIBPATH) \ + $(RS_PREBUILT_LIBPATH) -L $(TARGET_OUT_INTERMEDIATE_LIBRARIES) \ -lRSSupport -lm -lc endef