scripts/showSamples.sh
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Thu Apr 17 20:26:25 2008 +0000 (2008-04-17)
changeset 446 d205527c5e01
parent 168 45811aef4097
child 474 2904d77fe117
permissions -rwxr-xr-x
Move config files around, and clean up the mess in the config/ directory.

config/kernel/kernel_linux.in | 12 6 6 0 +-
config/paths.in | 89 0 89 0 ----------------
config/kernel_linux_headers_install.in | 168 0 168 0 ------------------------------
config/kernel.in | 2 1 1 0
config/kernel_linux_headers_copy.in | 42 0 42 0 --------
config/cc.in | 2 1 1 0
config/logging.in | 110 0 110 0 --------------------
config/build-behave.in | 45 0 45 0 --------
config/libc_uClibc.in | 101 0 101 0 ------------------
config/kernel_linux_headers_sanitised.in | 62 0 62 0 -----------
config/ct-behave.in | 82 0 82 0 ---------------
config/kernel_linux.in | 134 0 134 0 ------------------------
config/global.in | 10 5 5 0 +-
config/download_extract.in | 171 0 171 0 -------------------------------
config/cc_gcc.in | 130 0 130 0 ------------------------
config/libc_glibc.in | 124 0 124 0 ----------------------
config/libc.in | 4 2 2 0
17 files changed, 15 insertions(+), 1273 deletions(-)
     1 #!/bin/bash
     2 
     3 # Parses all samples on the command line, and for each of them, prints
     4 # the versions of the main tools
     5 
     6 # GREP_OPTIONS screws things up.
     7 export GREP_OPTIONS=
     8 
     9 # Dump a single sample
    10 dump_single_sample() {
    11     local width="$1"
    12     local sample="$2"
    13     if [ -f "${CT_TOP_DIR}/samples/${sample}/crosstool.config" ]; then
    14         sample_top="${CT_TOP_DIR}"
    15         sample_type="local"
    16     else
    17         sample_top="${CT_LIB_DIR}"
    18         sample_type="global"
    19     fi
    20     printf "  %-*s  (%s" ${width} "${sample}" "${sample_type}"
    21     [ -f "${sample_top}/samples/${sample}/broken" ] && printf ",broken"
    22     echo ")"
    23 }
    24 
    25 # Get largest sample width
    26 width=0
    27 for sample in "${@}"; do
    28     [ ${#sample} -gt ${width} ] && width=${#sample}
    29 done
    30 
    31 for sample in "${@}"; do
    32     ( dump_single_sample ${width} "${sample}" )
    33 done