diff --git a/config/kernel.m4 b/config/kernel.m4 index 639d183771..ec61e2c8f1 100644 --- a/config/kernel.m4 +++ b/config/kernel.m4 @@ -394,11 +394,11 @@ AC_DEFUN([ZFS_AC_KERNEL], [ utsrelease1=$kernelbuild/include/linux/version.h utsrelease2=$kernelbuild/include/linux/utsrelease.h utsrelease3=$kernelbuild/include/generated/utsrelease.h - AS_IF([test -r $utsrelease1 && fgrep -q UTS_RELEASE $utsrelease1], [ + AS_IF([test -r $utsrelease1 && grep -qF UTS_RELEASE $utsrelease1], [ utsrelease=$utsrelease1 - ], [test -r $utsrelease2 && fgrep -q UTS_RELEASE $utsrelease2], [ + ], [test -r $utsrelease2 && grep -qF UTS_RELEASE $utsrelease2], [ utsrelease=$utsrelease2 - ], [test -r $utsrelease3 && fgrep -q UTS_RELEASE $utsrelease3], [ + ], [test -r $utsrelease3 && grep -qF UTS_RELEASE $utsrelease3], [ utsrelease=$utsrelease3 ]) diff --git a/config/zfs-build.m4 b/config/zfs-build.m4 index d516f3d296..726b4b420c 100644 --- a/config/zfs-build.m4 +++ b/config/zfs-build.m4 @@ -173,7 +173,7 @@ AC_DEFUN([ZFS_AC_DEBUG_KMEM_TRACKING], [ ]) AC_DEFUN([ZFS_AC_DEBUG_INVARIANTS_DETECT_FREEBSD], [ - AS_IF([sysctl -n kern.conftxt | fgrep -qx $'options\tINVARIANTS'], + AS_IF([sysctl -n kern.conftxt | grep -Fqx $'options\tINVARIANTS'], [enable_invariants="yes"], [enable_invariants="no"]) ]) diff --git a/tests/zfs-tests/tests/functional/cli_root/zpool_wait/zpool_wait.kshlib b/tests/zfs-tests/tests/functional/cli_root/zpool_wait/zpool_wait.kshlib index b413f6e9f9..ccb9791496 100644 --- a/tests/zfs-tests/tests/functional/cli_root/zpool_wait/zpool_wait.kshlib +++ b/tests/zfs-tests/tests/functional/cli_root/zpool_wait/zpool_wait.kshlib @@ -120,5 +120,5 @@ function check_while_waiting # Whether any vdev in the given pool is initializing function is_vdev_initializing # pool { - zpool status -i "$1" | grep 'initialized, started' >/dev/null + zpool status -i "$1" | grep -q 'initialized, started' }