1 # https://github.com/BrianAker/ddm4
2 # ===========================================================================
6 # AX_LIBUV([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
14 # Copyright (c) 2012 Brian Aker <brian@tangent.org>
15 # Copyright (c) 2014 Andrew Hutchings <andrew@linuxjedi.co.uk>
17 # Copying and distribution of this file, with or without modification, are
18 # permitted in any medium without royalty provided the copyright notice
19 # and this notice are preserved. This file is offered as-is, without any
26 AC_CACHE_CHECK([test for a working libuv],[ax_cv_libuv],
30 AC_RUN_IFELSE([AC_LANG_PROGRAM([[
38 [AC_MSG_WARN([test program execution failed])])
43 AS_IF([test "x$ax_cv_libuv" = "xyes"],
44 [AC_SUBST([LIBUV_LIB],[-luv])
45 AC_DEFINE([HAVE_LIBUV],[1],[Define if uv_loop_new is present in uv.h.])],
46 [AC_DEFINE([HAVE_LIBUV],[0],[Define if uv_loop_new is present in uv.h.])])
48 AM_CONDITIONAL(HAVE_LIBUV, test "x$ax_cv_libuv" = "xyes")
49 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
50 AS_IF([test "x$ax_cv_libuv" = xyes],