Placeholder for SCO bc bug detection
This commit is contained in:
parent
8dea52fa42
commit
c5e48d8b01
29
test/bctest
29
test/bctest
@ -29,16 +29,29 @@ then
|
|||||||
echo "bc does not work. Consider installing GNU bc." >&2
|
echo "bc does not work. Consider installing GNU bc." >&2
|
||||||
echo "cat >/dev/null"
|
echo "cat >/dev/null"
|
||||||
exit 1
|
exit 1
|
||||||
else
|
fi
|
||||||
# bc works, good.
|
|
||||||
# Now check if it knows the 'print' command.
|
|
||||||
if [ "OK" = "`bc 2>/dev/null <<\EOF
|
# insert SCO bc test case here:
|
||||||
|
if [ 0 != "`bc <<\EOF
|
||||||
|
0
|
||||||
|
EOF`" ]
|
||||||
|
then
|
||||||
|
echo "bc does not work. Consider installing GNU bc." >&2
|
||||||
|
echo "cat >/dev/null"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# bc works, good.
|
||||||
|
# Now check if it knows the 'print' command.
|
||||||
|
if [ "OK" = "`bc 2>/dev/null <<\EOF
|
||||||
print \"OK\"
|
print \"OK\"
|
||||||
EOF`" ]
|
EOF`" ]
|
||||||
then
|
then
|
||||||
echo "bc"
|
echo "bc"
|
||||||
else
|
else
|
||||||
echo "sed 's/print.*//' | bc"
|
echo "sed 's/print.*//' | bc"
|
||||||
fi
|
|
||||||
exit 0
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user