diff options
author | Keith Winstein <keithw@mit.edu> | 2012-04-20 11:11:00 -0400 |
---|---|---|
committer | Keith Winstein <keithw@mit.edu> | 2012-04-20 11:11:00 -0400 |
commit | 2dc748b7f65f2b473c516fd924f1352ac45f6ba5 (patch) | |
tree | 16dc0e2ca0efdd28edc2d3b076614ec83e29cc1e /configure.ac | |
parent | 46ec3b41450c1f388d7e48d6458237e3a3fef208 (diff) |
Make sure we always use -lutil, and make test work for FreeBSD too.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index e9d08d8..8f61543 100644 --- a/configure.ac +++ b/configure.ac @@ -264,8 +264,7 @@ AC_CACHE_CHECK([whether poll can handle ptys], AS_IF([test "x$poll_LIBS" != "x"], [LIBS="$LIBS $poll_LIBS"]) - AS_IF([test "x$FORKPTY_IN_LIBUTIL" != "x"], - [LIBS="$LIBS -lutil"]) + LIBS="$LIBS -lutil" AC_RUN_IFELSE([AC_LANG_PROGRAM([[ #include <unistd.h> @@ -276,6 +275,9 @@ AC_CACHE_CHECK([whether poll can handle ptys], #elif HAVE_UTIL_H #include <util.h> #endif +#if FORKPTY_IN_LIBUTIL +#include <libutil.h> +#endif #include <sys/poll.h> int master, slave; |