# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.61])
-AC_INIT(libwebsockets, 1.0, andy@warmcat.com)
+AC_INIT(libwebsockets, 1.1, andy@warmcat.com, libwebsockets, http://libwebsockets.org)
AC_CONFIG_SRCDIR([test-server/test-server.c])
AC_CONFIG_HEADERS([config.h])
AC_PROG_MAKE_SET
AC_CONFIG_MACRO_DIR([m4])
+applyhash='CFLAGS+= -DLWS_LIBRARY_VERSION=\"$(PACKAGE_VERSION)\" -DLWS_BUILD_HASH=\"${shell git log -n 1 --pretty=%h}\"'
+AC_SUBST([applyhash])
+AM_SUBST_NOTMAKE([applyhash])
+
#
#
#
#
#
#
-AC_ARG_ENABLE(nofork,
- [ --enable-nofork Disables fork-related options],
- [ nofork=yes
- ])
-
-if test "x$nofork" = "xyes" ; then
-CFLAGS="$CFLAGS -DLWS_NO_FORK"
-else
-AC_FUNC_FORK
-fi
-
-#
-#
-#
AC_ARG_ENABLE(libcrypto,
[ --enable-libcrypto Use libcrypto MD5 and SHA1 implementations],
[ libcrypto=yes
fi
AM_CONDITIONAL(LIBCRYPTO, test x$libcrypto = xyes)
-
-#
-#
-#
-AC_ARG_ENABLE(x-google-mux,
- [ --enable-x-google-mux Build experimental x-google-mux],
- [ x_google_mux=yes
- ])
-if test "x$x_google_mux" = "xyes" ; then
-CFLAGS="$CFLAGS -DLWS_EXT_GOOGLE_MUX"
-fi
-AM_CONDITIONAL(EXT_GOOGLE_MUX, test x$x_google_mux = xyes)
-
#
#
#
fi
AM_CONDITIONAL(NO_CLIENT, test x$no_client = xyes)
+#
+#
+#
+AC_ARG_WITH(server,
+ [ --without-server dont build the client part of the library ],
+ [ no_server=yes
+ ])
+
+if test "x$no_server" = "xyes" ; then
+CFLAGS="$CFLAGS -DLWS_NO_SERVER"
+fi
+AM_CONDITIONAL(NO_SERVER, test x$no_server = xyes)
+
+#
+#
+#
+AC_ARG_WITH(extensions,
+ [ --without-extensions dont build any stuff related to extensions ],
+ [ no_extensions=yes
+ ])
+
+if test "x$no_extensions" = "xyes" ; then
+CFLAGS="$CFLAGS -DLWS_NO_EXTENSIONS"
+fi
+AM_CONDITIONAL(NO_EXTENSIONS, test x$no_extensions = xyes)
+
+#
+#
+#
+AC_ARG_WITH(latency,
+ [ --with-latency Build latency measuring code into the library ],
+ [ latency=yes
+ ])
+
+if test "x$latency" = "xyes" ; then
+CFLAGS="$CFLAGS -DLWS_LATENCY"
+fi
+AM_CONDITIONAL(LATENCY, test x$latency = xyes)
+
+#
+#
+#
+AC_ARG_WITH(daemonize,
+ [ --without-daemonize dont build the daemonization api ],
+ [ no_daemonize=yes
+ ])
+
+if test "x$no_daemonize" = "xyes" ; then
+CFLAGS="$CFLAGS -DLWS_NO_DAEMONIZE"
+fi
+AM_CONDITIONAL(NO_DAEMONIZE, test x$no_daemonize = xyes)
+
+#
#
#
AC_ARG_ENABLE(mingw,