From e440c3c07b26258139156075f0a51a9ad92eef75 Mon Sep 17 00:00:00 2001 From: Dan Albert Date: Thu, 20 Nov 2014 14:48:50 -0800 Subject: [PATCH] Revert "Fix the libgcc/libatomic link order." This caused a lot of failures in the libc++ tests, since linking libgcc.a before libc++.so means that the wrong unwinder will be used. This patch is still correct, but I will revert for now while I find a good way to apply it without breaking unwinding. This reverts commit 741b36e922a09c47507b61cbfc9cd8bba029f476. Change-Id: I57e0b89534adf5c1677dbf2f64ac750e74bd5fbf --- core/definitions.mk | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/core/definitions.mk b/core/definitions.mk index 0bbdb6da0..506467f02 100644 --- a/core/definitions.mk +++ b/core/definitions.mk @@ -1315,13 +1315,14 @@ $(hide) $(PRIVATE_CXX) \ $(if $(PRIVATE_GROUP_STATIC_LIBRARIES),-Wl$(comma)--start-group) \ $(call normalize-target-libraries,$(PRIVATE_ALL_STATIC_LIBRARIES)) \ $(if $(PRIVATE_GROUP_STATIC_LIBRARIES),-Wl$(comma)--end-group) \ - $(if $(filter true,$(NATIVE_COVERAGE)),$(PRIVATE_TARGET_LIBGCOV)) \ - $(PRIVATE_TARGET_LIBATOMIC) \ - $(PRIVATE_TARGET_LIBGCC) \ + $(if $(TARGET_BUILD_APPS),$(PRIVATE_TARGET_LIBGCC)) \ $(call normalize-target-libraries,$(PRIVATE_ALL_SHARED_LIBRARIES)) \ -o $@ \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ + $(PRIVATE_TARGET_LIBATOMIC) \ + $(if $(filter true,$(NATIVE_COVERAGE)),$(PRIVATE_TARGET_LIBGCOV)) \ + $(PRIVATE_TARGET_LIBGCC) \ $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ $(PRIVATE_LDLIBS) endef @@ -1377,13 +1378,14 @@ $(hide) $(PRIVATE_CXX) -pie \ $(if $(PRIVATE_GROUP_STATIC_LIBRARIES),-Wl$(comma)--start-group) \ $(call normalize-target-libraries,$(PRIVATE_ALL_STATIC_LIBRARIES)) \ $(if $(PRIVATE_GROUP_STATIC_LIBRARIES),-Wl$(comma)--end-group) \ - $(if $(filter true,$(NATIVE_COVERAGE)),$(PRIVATE_TARGET_LIBGCOV)) \ - $(PRIVATE_TARGET_LIBATOMIC) \ - $(PRIVATE_TARGET_LIBGCC) \ + $(if $(TARGET_BUILD_APPS),$(PRIVATE_TARGET_LIBGCC)) \ $(call normalize-target-libraries,$(PRIVATE_ALL_SHARED_LIBRARIES)) \ -o $@ \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ + $(PRIVATE_TARGET_LIBATOMIC) \ + $(if $(filter true,$(NATIVE_COVERAGE)),$(PRIVATE_TARGET_LIBGCOV)) \ + $(PRIVATE_TARGET_LIBGCC) \ $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ $(PRIVATE_LDLIBS) endef