1.1 --- a/scripts/build/internals.sh Fri Jun 26 19:09:22 2009 +0200
1.2 +++ b/scripts/build/internals.sh Sun Aug 30 00:27:12 2009 +0200
1.3 @@ -46,9 +46,25 @@
1.4 CT_DoLog EXTRA "Installing toolchain wrappers"
1.5 CT_Pushd "${CT_PREFIX_DIR}/bin"
1.6
1.7 - # Copy the wrapper
1.8 - CT_DoExecLog DEBUG install -m 0755 "${CT_LIB_DIR}/scripts/wrapper.in" \
1.9 - ".${CT_TARGET}-wrapper"
1.10 + # Install the wrapper
1.11 + case "${CT_TOOLS_WRAPPER}" in
1.12 + script)
1.13 + CT_DoExecLog DEBUG install \
1.14 + -m 0755 \
1.15 + "${CT_LIB_DIR}/scripts/wrapper.in" \
1.16 + ".${CT_TARGET}-wrapper"
1.17 + ;;
1.18 + exec)
1.19 + _t="-s"
1.20 + if [ "${CT_DEBUG_CT}" = "y" ]; then
1.21 + _t="" # If debugging crosstool-NG, don't strip the wrapper
1.22 + fi
1.23 + CT_DoExecLog "${HOST_CC}" \
1.24 + -Wall -Wextra -Wunreachable-code -Werror \
1.25 + -O3 -static ${_t} \
1.26 + -o ".${CT_TARGET}-wrapper"
1.27 + ;;
1.28 + esac
1.29
1.30 # Replace every tools with the wrapper
1.31 # Do it unconditionally, even for those tools that happen to be shell