toolchain-external: fix bug #5054
PATCH 1/1 toolchain-external: fix bug #5054
The external toolchain logic checks (and finds) the proper ARCH_LIB_DIR and forcibly copies it to */lib even if it's in */lib64
This is all well until the check is done for create_lib64_symlinks which only verifies if ARCH_SYSROOT_DIR/lib64 is a symlink, which in some toolchain it's a real directory (like sourcery x86_64 2012.09) and thus doesn't make the symlink in the target.
Fix this by also checking for a real directory.
Easily reproducible by running "make qemu_x86_64_defconfig", switching to an external toolchain before build, building and then trying to run the resulting image.
Closes bug #5054
--- toolchain/toolchain-external/ext-tool.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
toolchain/toolchain-external/ext-tool.mk +1 -1
@@ -446,7 +446,7 @@ $(STAMP_DIR)/ext-toolchain-installed: $(STAMP_DIR)/ext-toolchain-checked fi ; \ $(call MESSAGE,"Copying external toolchain sysroot to staging...") ; \ $(call copy_toolchain_sysroot,$${SYSROOT_DIR},$${ARCH_SYSROOT_DIR},$${ARCH_SUBDIR},$${ARCH_LIB_DIR},$${SUPPORT_LIB_DIR}) ; \ - if [ -L $${ARCH_SYSROOT_DIR}/lib64 ] ; then \ + if [ -L $${ARCH_SYSROOT_DIR}/lib64 -o -d $${ARCH_SYSROOT_DIR}/lib64 ] ; then \ $(call create_lib64_symlinks) ; \ fi ; \ if test x"$(BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY)" == x"y"; then \
Signature · 1 line
1.8.1.5
PATCH 1/1 toolchain-external: fix bug #5054
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Gustavo" == Gustavo Zacarias <[email protected]> writes:
Gustavo> The external toolchain logic checks (and finds) the proper Gustavo> ARCH_LIB_DIR and forcibly copies it to */lib even if it's in Gustavo> */lib64 This is all well until the check is done for Gustavo> create_lib64_symlinks which only verifies if Gustavo> ARCH_SYSROOT_DIR/lib64 is a symlink, which in some toolchain Gustavo> it's a real directory (like sourcery x86_64 2012.09) and thus Gustavo> doesn't make the symlink in the target.
Gustavo> Fix this by also checking for a real directory.
Gustavo> Easily reproducible by running "make qemu_x86_64_defconfig", Gustavo> switching to an external toolchain before build, building and Gustavo> then trying to run the resulting image.
Gustavo> Closes bug #5054
Committed, thanks.
Signature · 1 line
Bye, Peter Korsgaard