scripts/build/arch/x86.sh
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Thu Oct 23 13:45:48 2008 +0000 (2008-10-23)
changeset 965 45ddf096def1
parent 903 9fb0f81b4416
child 1635 5d1936ad5ba8
permissions -rw-r--r--
Push the calculation of the tuple's kernel part down to kernel's build scripts:
- update the kernel script's API with the function CT_DiKernelTupleValues
- update doc accordingly (also with the architecture change, missing in the previous commit)
- small clean-up in the main script, remove useless test

/trunk/scripts/build/kernel/bare-metal.sh | 5 5 0 0 +++++
/trunk/scripts/build/kernel/linux.sh | 5 5 0 0 +++++
/trunk/scripts/crosstool.sh | 31 13 18 0 +++++++++++++------------------
/trunk/scripts/functions | 15 8 7 0 ++++++++-------
/trunk/docs/overview.txt | 13 9 4 0 +++++++++----
5 files changed, 40 insertions(+), 29 deletions(-)
yann@383
     1
# Compute x86-specific values
yann@383
     2
yann@383
     3
# This one really need a little love! :-(
yann@383
     4
yann@964
     5
CT_DoArchTupleValues() {
yann@383
     6
    # The architecture part of the tuple:
yann@383
     7
    arch="${CT_ARCH_ARCH}"
yann@383
     8
    [ -z "${arch}" ] && arch="${CT_ARCH_TUNE}"
yann@383
     9
    case "${arch}" in
yann@383
    10
        nocona|athlon*64|k8|athlon-fx|opteron)
yann@383
    11
            CT_DoError "Architecture is x86 (32-bit) but selected processor is \"${arch}\" (64-bit)";;
yann@383
    12
        "")                           CT_TARGET_ARCH=i386;;
yann@383
    13
        i386|i486|i586|i686)          CT_TARGET_ARCH="${arch}";;
yann@383
    14
        winchip*)                     CT_TARGET_ARCH=i486;;
yann@383
    15
        pentium|pentium-mmx|c3*)      CT_TARGET_ARCH=i586;;
yann@383
    16
        pentiumpro|pentium*|athlon*)  CT_TARGET_ARCH=i686;;
yann@383
    17
        *)                            CT_TARGET_ARCH=i586;;
yann@383
    18
    esac
yann@383
    19
yann@387
    20
    # The kernel ARCH:
yann@387
    21
    CT_KERNEL_ARCH=i386
yann@383
    22
}