scripts: unset LIBRARY_PATH and LPATH
authorErik Inge Bolsø <knan-ct@anduin.net>
Sun May 13 01:09:20 2012 +0200 (2012-05-13)
changeset 3061e43643e41fb9
parent 3060 f46a1d105896
child 3062 f36c207348ef
scripts: unset LIBRARY_PATH and LPATH

These environment variables set search path for gcc at link time, which can break the build.

Signed-off-by: Erik Inge Bolsø <knan-ct@anduin.net>
Message-Id: <alpine.BSF.2.00.1205130131550.21551@anduin.net>
PatchWork-Id: 186872
scripts/crosstool-NG.sh.in
     1.1 --- a/scripts/crosstool-NG.sh.in	Sun Sep 23 11:59:28 2012 +0900
     1.2 +++ b/scripts/crosstool-NG.sh.in	Sun May 13 01:09:20 2012 +0200
     1.3 @@ -39,6 +39,10 @@
     1.4  CT_TestAndAbort "Don't set LD_LIBRARY_PATH. It screws up the build." -n "${LD_LIBRARY_PATH}"
     1.5  CT_TestAndAbort "Don't set CFLAGS. It screws up the build." -n "${CFLAGS}"
     1.6  CT_TestAndAbort "Don't set CXXFLAGS. It screws up the build." -n "${CXXFLAGS}"
     1.7 +CT_Test "LIBRARY_PATH screws up the build. Resetting." -n "${LIBRARY_PATH}"
     1.8 +export LIBRARY_PATH=
     1.9 +CT_Test "LPATH screws up the build. Resetting." -n "$LPATH"
    1.10 +export LPATH=
    1.11  CT_Test "GREP_OPTIONS screws up the build. Resetting." -n "${GREP_OPTIONS}"
    1.12  export GREP_OPTIONS=
    1.13  # Workaround against openSUSE 12.1 that breaks ./configure for cross-compilation: