toolchain: only take last found libgcc* file
authorJo-Philipp Wich <jow@openwrt.org>
Fri, 27 Jun 2014 10:40:21 +0000 (10:40 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Fri, 27 Jun 2014 10:40:21 +0000 (10:40 +0000)
commita53f56ec35dec76a4a3b61fd181a0768d3431bd2
treed9eee57c08d4b5071af6dc4031a2d353ebdbeed0
parente8c3531b6c5d6ee6ff5fc7fafd80c4ed74cce46c
toolchain: only take last found libgcc* file

The current $(wildcard ...) match might return multiple files which will break subsequent cp commands
with an error like:

  cp: target `/home/user/openwrt/staging_dir/target-mips_34kc_uClibc-0.9.33.2/root-ar71xx/tmp-libc/lib/libgcc_s_pic.a' is not a directory

Prevent this issue by only taking the last path returned by globbing.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
SVN-Revision: 41357
package/libs/toolchain/Makefile