./configure --without-chroot will configure tcpdump with "no" as the
value of chroot directory and cause tcpdump to fail with:
tcpdump: Couldn't chroot/chdir to 'no': No such file or directory
This patch makes ./configure to avoid chroot directory when called with
--without-chroot.
AC_ARG_WITH(chroot, [ --with-chroot=DIRECTORY when dropping privileges, chroot to DIRECTORY])
AC_MSG_CHECKING([whether to chroot])
-if test ! -z "$with_chroot" ; then
+if test ! -z "$with_chroot" && test "$with_chroot" != "no" ; then
AC_DEFINE_UNQUOTED(WITH_CHROOT, "$withval")
AC_MSG_RESULT(to \"$withval\")
else