mirror of
git://git.savannah.gnu.org/config.git
synced 2025-07-05 04:38:20 +12:00
* testsuite/config-guess.sh: Re-indent with tabs.
* testsuite/config-sub.sh: Likewise. Signed-off-by: Ben Elliston <bje@gnu.org>
This commit is contained in:

committed by
Ben Elliston

parent
8de5d27282
commit
f52be464ee
@ -13,14 +13,14 @@ PATH=$(pwd):$PATH
|
||||
|
||||
run_config_guess()
|
||||
{
|
||||
rc=0
|
||||
while IFS='|' read -r machine release system version processor triplet ; do
|
||||
sed \
|
||||
-e "s,@MACHINE@,$machine," \
|
||||
-e "s,@RELEASE@,$release," \
|
||||
-e "s,@SYSTEM@,$system," \
|
||||
-e "s,@VERSION@,$version," \
|
||||
-e "s,@PROCESSOR@,$processor," > uname << EOF
|
||||
rc=0
|
||||
while IFS='|' read -r machine release system version processor triplet ; do
|
||||
sed \
|
||||
-e "s,@MACHINE@,$machine," \
|
||||
-e "s,@RELEASE@,$release," \
|
||||
-e "s,@SYSTEM@,$system," \
|
||||
-e "s,@VERSION@,$version," \
|
||||
-e "s,@PROCESSOR@,$processor," > uname << EOF
|
||||
#!/bin/sh
|
||||
[ \$# -ne 1 ] && exec sh \$0 -s
|
||||
[ \$1 = -m ] && echo "@MACHINE@" && exit 0
|
||||
@ -29,29 +29,29 @@ run_config_guess()
|
||||
[ \$1 = -v ] && echo "@VERSION@" && exit 0
|
||||
[ \$1 = -p ] && echo "@PROCESSOR@" && exit 0
|
||||
EOF
|
||||
chmod +x uname
|
||||
output=$(sh -eu ../config.guess 2>/dev/null)
|
||||
if test $? != 0 ; then
|
||||
echo "FAIL: unable to guess $machine:$release:$system:$version"
|
||||
rc=1
|
||||
continue
|
||||
fi
|
||||
if test "$output" != "$triplet" ; then
|
||||
echo "FAIL: $output (expected $triplet)"
|
||||
rc=1
|
||||
continue
|
||||
fi
|
||||
$verbose && echo "PASS: $triplet"
|
||||
done
|
||||
return $rc
|
||||
chmod +x uname
|
||||
output=$(sh -eu ../config.guess 2>/dev/null)
|
||||
if test $? != 0 ; then
|
||||
echo "FAIL: unable to guess $machine:$release:$system:$version"
|
||||
rc=1
|
||||
continue
|
||||
fi
|
||||
if test "$output" != "$triplet" ; then
|
||||
echo "FAIL: $output (expected $triplet)"
|
||||
rc=1
|
||||
continue
|
||||
fi
|
||||
$verbose && echo "PASS: $triplet"
|
||||
done
|
||||
return $rc
|
||||
}
|
||||
|
||||
if sed 's, | ,|,g' < config-guess.data | run_config_guess ; then
|
||||
numtests=$(wc -l config-guess.data | cut -d' ' -f1)
|
||||
$verbose || echo "PASS: config.guess checks ($numtests tests)"
|
||||
numtests=$(wc -l config-guess.data | cut -d' ' -f1)
|
||||
$verbose || echo "PASS: config.guess checks ($numtests tests)"
|
||||
else
|
||||
echo "Unexpected failures."
|
||||
exit 1
|
||||
echo "Unexpected failures."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
Reference in New Issue
Block a user