svn commit: r187334 - head/tools/regression/fstest/tests
Pawel Jakub Dawidek
pjd at FreeBSD.org
Fri Jan 16 10:09:50 PST 2009
Author: pjd
Date: Fri Jan 16 18:09:49 2009
New Revision: 187334
URL: http://svn.freebsd.org/changeset/base/187334
Log:
Be more Solaris-friendly.
Submitted by: Milan Cermak <Milan.Cermak at Sun.COM>
Modified:
head/tools/regression/fstest/tests/conf
head/tools/regression/fstest/tests/misc.sh
Modified: head/tools/regression/fstest/tests/conf
==============================================================================
--- head/tools/regression/fstest/tests/conf Fri Jan 16 18:00:25 2009 (r187333)
+++ head/tools/regression/fstest/tests/conf Fri Jan 16 18:09:49 2009 (r187334)
@@ -6,15 +6,19 @@ os=`uname`
case "${os}" in
FreeBSD|Darwin)
+ GREP=grep
#fs=`df -T . | tail -1 | awk '{print $2}'`
pattern="`df . | tail -1 | awk '{printf("%s on %s \n", $1, $6)}'`"
fs=`mount | egrep "^${pattern}" | awk -F '[(,]' '{print $2}'`
;;
-Solaris)
- pattern="`df -k . | tail -1 | awk '{printf("%s on %s \n", $1, $6)}'`"
- fs=`mount -v | egrep "^${pattern}" | awk '{print $5}'`
+Solaris|SunOS)
+ GREP=ggrep
+ pattern=`df -k . | tail -1 | awk '{printf("%s on %s \n", $1, $6)}'`
+ fs=`mount -v | egrep "^${pattern}" | awk '{print $5}' | \
+ tr -s '[:lower:]' '[:upper:]'`
;;
Linux)
+ GREP=grep
fs=`df -PT . | tail -1 | awk '{print $2}'`
;;
*)
Modified: head/tools/regression/fstest/tests/misc.sh
==============================================================================
--- head/tools/regression/fstest/tests/misc.sh Fri Jan 16 18:00:25 2009 (r187333)
+++ head/tools/regression/fstest/tests/misc.sh Fri Jan 16 18:09:49 2009 (r187334)
@@ -87,7 +87,7 @@ test_check()
todo()
{
- echo "${os}" | grep -iq "${1}"
+ echo "${os}" | $GREP -iq "${1}"
if [ $? -eq 0 ]; then
todomsg="${2}"
fi
More information about the svn-src-all
mailing list