diff --git a/core/combo/TARGET_linux-arm.mk b/core/combo/TARGET_linux-arm.mk index f698ef5cec..81d0813184 100644 --- a/core/combo/TARGET_linux-arm.mk +++ b/core/combo/TARGET_linux-arm.mk @@ -239,7 +239,8 @@ $(hide) $(PRIVATE_CXX) \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-executable-inner @@ -264,7 +265,8 @@ $(hide) $(PRIVATE_CXX) -nostdlib -Bdynamic -fPIE -pie \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-static-executable-inner diff --git a/core/combo/TARGET_linux-arm64.mk b/core/combo/TARGET_linux-arm64.mk index 6bb3754fc6..5e50f9fd7f 100644 --- a/core/combo/TARGET_linux-arm64.mk +++ b/core/combo/TARGET_linux-arm64.mk @@ -180,7 +180,8 @@ $(hide) $(PRIVATE_CXX) \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ + $(PRIVATE_LDLIBS) endef define transform-o-to-executable-inner @@ -204,7 +205,8 @@ $(hide) $(PRIVATE_CXX) -nostdlib -Bdynamic -fPIE -pie \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define transform-o-to-static-executable-inner diff --git a/core/combo/TARGET_linux-mips.mk b/core/combo/TARGET_linux-mips.mk index ba03b5df35..1250767550 100644 --- a/core/combo/TARGET_linux-mips.mk +++ b/core/combo/TARGET_linux-mips.mk @@ -230,7 +230,8 @@ $(hide) $(PRIVATE_CXX) \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-executable-inner @@ -255,7 +256,8 @@ $(hide) $(PRIVATE_CXX) -nostdlib -Bdynamic -fPIE -pie \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-static-executable-inner diff --git a/core/combo/TARGET_linux-mips64.mk b/core/combo/TARGET_linux-mips64.mk index 969ba10a09..2130d03591 100644 --- a/core/combo/TARGET_linux-mips64.mk +++ b/core/combo/TARGET_linux-mips64.mk @@ -239,7 +239,8 @@ $(hide) $(PRIVATE_CXX) \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ + $(PRIVATE_LDLIBS) endef define transform-o-to-executable-inner @@ -264,7 +265,8 @@ $(hide) $(PRIVATE_CXX) -nostdlib -Bdynamic -fPIE -pie \ $(PRIVATE_TARGET_GLOBAL_LDFLAGS) \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define transform-o-to-static-executable-inner diff --git a/core/combo/TARGET_linux-x86.mk b/core/combo/TARGET_linux-x86.mk index 01f8242bd1..4f66765d32 100644 --- a/core/combo/TARGET_linux-x86.mk +++ b/core/combo/TARGET_linux-x86.mk @@ -194,7 +194,8 @@ $(hide) $(PRIVATE_CXX) \ -o $@ \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_SO_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-executable-inner @@ -219,7 +220,8 @@ $(hide) $(PRIVATE_CXX) \ -o $@ \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define $(combo_2nd_arch_prefix)transform-o-to-static-executable-inner diff --git a/core/combo/TARGET_linux-x86_64.mk b/core/combo/TARGET_linux-x86_64.mk index a5a745b4cc..42953ae52c 100644 --- a/core/combo/TARGET_linux-x86_64.mk +++ b/core/combo/TARGET_linux-x86_64.mk @@ -224,7 +224,8 @@ $(hide) $(PRIVATE_CXX) \ -o $@ \ $(PRIVATE_LDFLAGS) \ $(PRIVATE_TARGET_LIBGCC) \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef define transform-o-to-static-executable-inner @@ -244,5 +245,6 @@ $(hide) $(PRIVATE_CXX) \ $(PRIVATE_TARGET_FDO_LIB) \ $(PRIVATE_TARGET_LIBGCC) \ -Wl,--end-group \ - $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) + $(if $(filter true,$(PRIVATE_NO_CRT)),,$(PRIVATE_TARGET_CRTEND_O)) \ + $(PRIVATE_LDLIBS) endef