Only use the CROSS_BINUTILS_PREFIX tool if it exists.

Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
This commit is contained in:
Andrew Turner 2015-04-02 17:03:02 +00:00
parent c4c4346f5f
commit b40d31d0a1

View File

@ -344,7 +344,8 @@ X${COMPILER}?= ${${COMPILER}}
.endfor
XBINUTILS= AS AR LD NM OBJCOPY OBJDUMP RANLIB SIZE STRINGS
.for BINUTIL in ${XBINUTILS}
.if defined(CROSS_BINUTILS_PREFIX)
.if defined(CROSS_BINUTILS_PREFIX) && \
exists(${CROSS_BINUTILS_PREFIX}${${BINUTIL}})
X${BINUTIL}?= ${CROSS_BINUTILS_PREFIX}${${BINUTIL}}
.else
X${BINUTIL}?= ${${BINUTIL}}