mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-04 02:18:37 +00:00
I tried using 'svn merge' to do the merge but it did a terrible job and there were bazillions of conflicts. So instead I just took the diff between the branch and trunk at r10155, applied the diff to the trunk, 'svn add'ed the added files (no files needed to be 'svn remove'd) and committed. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10156
38 lines
1.0 KiB
Bash
38 lines
1.0 KiB
Bash
#! /bin/sh
|
|
|
|
# This script determines which platforms that this Valgrind installation
|
|
# supports.
|
|
# We return:
|
|
# - 0 if the machine matches the asked-for platform
|
|
# - 1 if it didn't match, but did match the name of another platform
|
|
# - 2 otherwise
|
|
|
|
# Nb: When updating this file for a new platform, add the name to
|
|
# 'all_platforms'.
|
|
|
|
all_platforms=
|
|
all_platforms="$all_platforms x86-linux amd64-linux ppc32-linux ppc64-linux"
|
|
all_platforms="$all_platforms ppc32-aix5 ppc64-aix5"
|
|
all_platforms="$all_platforms x86-darwin amd64-darwin"
|
|
|
|
if [ $# -ne 2 ] ; then
|
|
echo "usage: platform_test <arch-type> <OS-type>"
|
|
exit 2;
|
|
fi
|
|
|
|
# Get the directory holding the arch_test and os_test, which will be the same
|
|
# as the one holding this script.
|
|
dir=`dirname $0`
|
|
|
|
if $dir/arch_test $1 && $dir/os_test $2 ; then
|
|
exit 0; # Matches this platform.
|
|
fi
|
|
|
|
for p in $all_platforms ; do
|
|
if [ $1-$2 = $p ] ; then
|
|
exit 1; # Matches another Valgrind-supported platform.
|
|
fi
|
|
done
|
|
|
|
exit 2; # Doesn't match any Valgrind-supported platform.
|