libc/glibc: fix kernel version check
author"Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Wed Apr 21 18:54:58 2010 +0200 (2010-04-21)
changeset 1929f5d5e279af95
parent 1928 0535b588679a
child 1930 d78dac957ebc
libc/glibc: fix kernel version check

Since we log the test strings, it is no longer possible to call
the CT_Test* functions from sub-functions that print results to
their stdout.
scripts/build/libc/glibc.sh
     1.1 --- a/scripts/build/libc/glibc.sh	Tue Apr 20 09:58:41 2010 +0200
     1.2 +++ b/scripts/build/libc/glibc.sh	Wed Apr 21 18:54:58 2010 +0200
     1.3 @@ -578,7 +578,9 @@
     1.4                  # version installed in "usr/include/linux/version.h" in the sys-root.
     1.5                  # Parse that instead of having two code-paths.
     1.6                  version_code_file="${CT_SYSROOT_DIR}/usr/include/linux/version.h"
     1.7 -                CT_TestOrAbort "Linux version is unavailable in installed headers files" -f "${version_code_file}" -a -r "${version_code_file}"
     1.8 +                if [ ! -f "${version_code_file}" -o ! -r "${version_code_file}" ]; then
     1.9 +                    CT_Abort "Linux version is unavailable in installed headers files"
    1.10 +                fi
    1.11                  version_code=$(grep -E LINUX_VERSION_CODE "${version_code_file}" |cut -d ' ' -f 3)
    1.12                  version=$(((version_code>>16)&0xFF))
    1.13                  patchlevel=$(((version_code>>8)&0xFF))