scripts/build/internals.sh: compile wrapper with portable options.
authorTitus von Boxberg <titus@v9g.de>
Sat May 22 22:01:18 2010 +0200 (2010-05-22)
changeset 1970cdd761ad2d1a
parent 1969 618a1ffd1ea2
child 1971 cbe89e8dfc9c
scripts/build/internals.sh: compile wrapper with portable options.

static linking is not possible on MacOS, and unnessecary on other systems.
The old optimization and warning flags crash the gcc on MacOS
and (imho) are a bit overdone for this software.
scripts/build/internals.sh
     1.1 --- a/scripts/build/internals.sh	Sun May 23 16:34:15 2010 +0200
     1.2 +++ b/scripts/build/internals.sh	Sat May 22 22:01:18 2010 +0200
     1.3 @@ -58,15 +58,15 @@
     1.4                                     ".${CT_TARGET}-wrapper"
     1.5                  ;;
     1.6              exec)
     1.7 -                _t="-s"
     1.8 -                if [ "${CT_DEBUG_CT}" = "y" ]; then
     1.9 -                  _t="" # If debugging crosstool-NG, don't strip the wrapper
    1.10 -                fi
    1.11                  CT_DoExecLog DEBUG "${CT_HOST}-gcc"                           \
    1.12 -                                   -Wall -Wextra -Wunreachable-code -Werror   \
    1.13 -                                   -O3 -static ${_t}                          \
    1.14 +                                   -Wall -Wextra -Werror                      \
    1.15 +                                   -Os                                        \
    1.16                                     "${CT_LIB_DIR}/scripts/wrapper.c"          \
    1.17                                     -o ".${CT_TARGET}-wrapper"
    1.18 +                if [ "${CT_DEBUG_CT}" != "y" ]; then
    1.19 +                    # If not debugging crosstool-NG, strip the wrapper
    1.20 +                    CT_DoExecLog DEBUG "${CT_HOST}-strip" ".${CT_TARGET}-wrapper"
    1.21 +                fi
    1.22                  ;;
    1.23          esac
    1.24