base-files: return success on lib-copying with external toolchain
authorJo-Philipp Wich <jow@openwrt.org>
Tue, 12 Apr 2011 20:37:43 +0000 (20:37 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Tue, 12 Apr 2011 20:37:43 +0000 (20:37 +0000)
commit8e633acd32821704888a586f7ecf74b20c8a5c3a
tree2209f6db31f5b1c1b4d2fef7d573156c35898d7b
parentbb6436338c94fe370eae20d48678c44b0ffdc216
base-files: return success on lib-copying with external toolchain
when using an external toolchain the base-files package copies libc, libgcc and
others from the library directory.

The file list is given as following in the .config:
CONFIG_LIBC_FILE_SPEC="./lib/ld{-*.so,-linux*.so.*} ./lib/lib{anl,c,cidn,crypt,dl,m,nsl,nss_dns,nss_files,resolv,util}{-*.so,.so.*}"

Because the filenames are composed with different endings, not all files exist
and will be skipped. Currently, this works only if the last composed file
(util.so.*) really exists. At the moment this works - but only if you don't add
a new file like 'uClibc'.

Adding it at the end '...resolv,util,uClibc}{-*.so,.so.*}' will lead to this
message, because the combination 'libuClibc.so.*' doesn't exist and Make will
evaluate the last copy statement of the for loop.

--- Message Snippet ---
cp: cannot stat `/home/user/Desktop/code/meetwise/toolchain/staging_dir/toolchain-arm_v5te_gcc-linaro_uClibc-0.9.32_eabi/./lib/libnss_files.so.*': No such file or directory
cp: cannot stat `/home/user/Desktop/code/meetwise/toolchain/staging_dir/toolchain-arm_v5te_gcc-linaro_uClibc-0.9.32_eabi/./lib/libresolv-*.so': No such file or directory
cp: cannot stat `/home/user/Desktop/code/meetwise/toolchain/staging_dir/toolchain-arm_v5te_gcc-linaro_uClibc-0.9.32_eabi/./lib/libresolv.so.*': No such file or directory
cp: cannot stat `/home/user/Desktop/code/meetwise/toolchain/staging_dir/toolchain-arm_v5te_gcc-linaro_uClibc-0.9.32_eabi/./lib/libuClibc.so.*': No such file or directory
make[2]: *** [/home/user/Desktop/code/meetwise/openwrt/bin/at91/packages/libc_-68_at91.ipk] Error 1
make[2]: Leaving directory `/home/user/Desktop/code/meetwise/openwrt/package/base-files'
make[1]: *** [package/base-files/compile] Error 2
make[1]: Leaving directory `/home/user/Desktop/code/meetwise/openwrt'
make: *** [package/base-files/compile] Error 2
--- /Message Snippet/ ---

To fix this unwanted behaviour I added an extra 'exit 0' to each for-loop and
make ignores non-existing files as before.

Signed-off-by: Sven Bachmann <dev@mcbachmann.de>
SVN-Revision: 26623
package/base-files/Makefile