summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorRay Donnelly <mingw.android@gmail.com>2015-05-29 20:40:51 (GMT)
committerRay Donnelly <mingw.android@gmail.com>2015-06-01 23:01:22 (GMT)
commit9cdbc7b1998c24b501af9b6a9c6730cc716fb220 (patch)
tree213596ca85a35b4d6a0e052a4979e6a4e52455ec /scripts
parent541199de3a6dc195898b880b4ef2084c106b53ae (diff)
showSamples: Update showSamples.sh for multiple compilers
This change adds support to show samples for multiple compilers. Signed-off-by: Ray Donnelly <mingw.android@gmail.com> Reviewed-by: Bryan Hundven <bryanhundven@gmail.com> Reviewed-by: Yann Diorcet <diorcetyann@gmail.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/showSamples.sh22
1 files changed, 18 insertions, 4 deletions
diff --git a/scripts/showSamples.sh b/scripts/showSamples.sh
index 011c75a..684e118 100755
--- a/scripts/showSamples.sh
+++ b/scripts/showSamples.sh
@@ -76,7 +76,15 @@ dump_single_sample() {
[ -z "${CT_LIBELF}" -a -z "${CT_LIBELF_TARGET}" ] || printf " libelf-%s" "${CT_LIBELF_VERSION}"
[ -z "${complibs}" ] || printf "\n"
printf " %-*s : %s\n" ${width} "binutils" "binutils-${CT_BINUTILS_VERSION}"
- printf " %-*s : %s" ${width} "C compiler" "${CT_CC}-${CT_CC_VERSION} (C"
+ printf " %-*s :" ${width} "C compilers"
+ for cc in $(env | ${sed} -n 's/^CT_CC_\(.*\)_VERSION.*/\1/p'); do
+ cc_variable=CT_CC_${cc}_VERSION
+ version=${!cc_variable}
+ compiler=$(echo $cc | ${awk} '{print tolower($0)}')
+ printf " $compiler-$version"
+ done
+ printf "\n"
+ printf " %-*s : %s" ${width} "Languages" "C"
[ "${CT_CC_LANG_CXX}" = "y" ] && printf ",C++"
[ "${CT_CC_LANG_FORTRAN}" = "y" ] && printf ",Fortran"
[ "${CT_CC_LANG_JAVA}" = "y" ] && printf ",Java"
@@ -85,7 +93,7 @@ dump_single_sample() {
[ "${CT_CC_LANG_OBJCXX}" = "y" ] && printf ",Objective-C++"
[ "${CT_CC_LANG_GOLANG}" = "y" ] && printf ",Go"
[ -n "${CT_CC_LANG_OTHERS}" ] && printf ",${CT_CC_LANG_OTHERS}"
- printf ")\n"
+ printf "\n"
printf " %-*s : %s (threads: %s)\n" ${width} "C library" "${CT_LIBC}${CT_LIBC_VERSION:+-}${CT_LIBC_VERSION}" "${CT_THREADS}"
printf " %-*s :" ${width} "Tools"
[ "${CT_TOOL_sstrip}" ] && printf " sstrip"
@@ -120,8 +128,14 @@ dump_single_sample() {
fi
fi
printf "| ${CT_BINUTILS_VERSION} "
- printf "| ''${CT_CC}'' "
- printf "| ${CT_CC_VERSION} "
+ printf "| "
+ for cc in $(env | ${sed} -n 's/^CT_CC_\(.*\)_VERSION.*/\1/p'); do
+ cc_variable=CT_CC_${cc}_VERSION
+ version=${!cc_variable}
+ compiler=$(echo $cc | ${awk} '{print tolower($0)}')
+ printf " $compiler-$version"
+ done
+ printf " "
printf "| ''${CT_LIBC}'' |"
if [ "${CT_LIBC}" != "none" ]; then
printf " ${CT_LIBC_VERSION} "