Linux: support ld.gold

The -Ur option is not supported in gold

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
Mark Charlebois
2015-04-20 11:00:16 -07:00
parent aeb65702a2
commit a25ae71f99
+3 -2
View File
@@ -81,7 +81,7 @@ CPP = clang$(CLANGVER) -E
DEV_VER_SUPPORTED = 4.2.1
endif
LD = ld
LD = ld.gold
AR = ar rcs
NM = nm
OBJCOPY = objcopy
@@ -282,10 +282,11 @@ endef
# Produce partially-linked $1 from files in $2
#
#$(Q) $(LD) -Ur -o $1 $2 # -Ur not supported in ld.gold
define PRELINK
@$(ECHO) "PRELINK: $1"
@$(MKDIR) -p $(dir $1)
$(Q) $(LD) -Ur -o $1 $2
$(Q) $(LD) -r -o $1 $2
endef
# $(Q) $(LD) -Ur -o $1 $2 && $(OBJCOPY) --localize-hidden $1