X-Git-Url: http://git.openwrt.org/?p=openwrt%2Fopenwrt.git;a=blobdiff_plain;f=scripts%2Fext-toolchain.sh;h=09390c5e0d51f5195f776507593a29a48d77c614;hp=d1e163fd68973032ccd1e9b3e4e7ed95bdf0dbab;hb=9dcb921d908e664655e8bde2db64640b4f2d9072;hpb=643babfc3ca64d0fbb505cebbc1c1d92c270de1b diff --git a/scripts/ext-toolchain.sh b/scripts/ext-toolchain.sh index d1e163fd68..09390c5e0d 100755 --- a/scripts/ext-toolchain.sh +++ b/scripts/ext-toolchain.sh @@ -3,7 +3,7 @@ # Script for various external toolchain tasks, refer to # the --help output for more information. # -# Copyright (C) 2012 Jo-Philipp Wich +# Copyright (C) 2012 Jo-Philipp Wich # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -91,7 +91,7 @@ test_uclibc() { local sysroot="$("$CC" $CFLAGS -print-sysroot 2>/dev/null)" if [ -d "${sysroot:-$TOOLCHAIN}" ]; then local lib - for lib in "${sysroot:-$TOOLCHAIN}"/{lib,usr/lib,usr/local/lib}/ld-uClibc*.so*; do + for lib in "${sysroot:-$TOOLCHAIN}"/{lib,usr/lib,usr/local/lib}/ld*-uClibc*.so*; do if [ -f "$lib" ] && [ ! -h "$lib" ]; then return 0 fi @@ -356,6 +356,10 @@ print_config() { echo "CONFIG_TOOLCHAIN_PREFIX=\"$prefix\"" >> "$config" echo "CONFIG_TARGET_NAME=\"$target\"" >> "$config" + if [ "$LIBC_TYPE" != glibc ]; then + echo "CONFIG_TOOLCHAIN_LIBC=\"$LIBC_TYPE\"" >> "$config" + fi + local lib for lib in C RT PTHREAD GCC STDCPP SSP GFORTRAN; do local file