Move LDOPTS to the end of the linker call.
Command line order is important with newer gcc versions. mkzenboot extends
LDOPTS but the linker would ignore that since no object using it has been
mentioned on the command line. Moving it to the end should fix this.
Change-Id: I081e86fa88f95dba6077a50f2b4315bf3a805ae5
diff --git a/rbutil/libtools.make b/rbutil/libtools.make
index 4037276..defd320 100644
--- a/rbutil/libtools.make
+++ b/rbutil/libtools.make
@@ -106,9 +106,9 @@
@echo LD $@
$(SILENT)$(call mkdir,$(dir $@))
# EXTRADEPS need to be built into OBJDIR.
- $(SILENT)$(CROSS)$(CC) $(ARCHFLAGS) $(CFLAGS) $(LDOPTS) -o $(BINARY) \
+ $(SILENT)$(CROSS)$(CC) $(ARCHFLAGS) $(CFLAGS) -o $(BINARY) \
$(OBJS) $(addprefix $(OBJDIR),$(EXTRADEPS)) \
- $(addprefix $(OBJDIR),$(EXTRALIBOBJS))
+ $(addprefix $(OBJDIR),$(EXTRALIBOBJS)) $(LDOPTS)
# common rules
$(OBJDIR)%.o: