Fix docs and build system.

This commit is contained in:
Jack Moffitt
2012-02-07 22:40:55 -07:00
parent 90d4c54d81
commit 9b50b56dbb
6 changed files with 77 additions and 76 deletions

View File

@@ -6,7 +6,7 @@ AC_PROG_RANLIB
AM_PROG_CC_C_O
AC_CHECK_HEADER(openssl/ssl.h, [], [AC_MSG_ERROR([couldn't find openssl headers, openssl required])])
PKG_CHECK_MODULES([check], [check >= 0.9.4])
PKG_CHECK_MODULES([check], [check >= 0.9.4], [], [AC_MSG_WARN([libcheck not found; unit tests will not be compilable])])
AC_ARG_WITH([libxml2],
[AS_HELP_STRING([--with-libxml2], [use libxml2 for XML parsing])],
@@ -18,8 +18,7 @@ if test "x$with_libxml2" != xno; then
[with_libxml2=yes],
[AC_MSG_ERROR([couldn't find libxml2])])
else
AC_CHECK_FUNCS(memmove)
AC_C_BIGENDIAN([byteorder=1234], [byteorder=4321], [], [])
AC_CHECK_HEADER(expat.h, [], [AC_MSG_ERROR([couldn't find expat headers; expat required])])
fi
if test "x$with_libxml2" = xyes; then
@@ -28,18 +27,16 @@ if test "x$with_libxml2" = xyes; then
PARSER_CFLAGS=\$\(libxml2_CFLAGS\)
PARSER_LIBS=\$\(libxml2_LIBS\)
else
with_parser=builtin
with_parser=expat
PARSER_NAME=expat
PARSER_CFLAGS=\$\(builtin_CFLAGS\)
PARSER_LIBS=\$\(builtin_LIBS\)
PARSER_CFLAGS=
PARSER_LIBS=-lexpat
fi
AC_MSG_NOTICE([libstrophe will use the $with_parser XML parser])
AC_SEARCH_LIBS([socket], [socket])
AM_CONDITIONAL([BUILD_EXPAT], [test x$with_parser = xbuiltin])
AM_CONDITIONAL([PARSER_EXPAT], [test x$with_parser != xlibxml2])
AC_DEFINE_UNQUOTED([BYTEORDER], [$byteorder])
AC_SUBST(PARSER_NAME)
AC_SUBST(PARSER_CFLAGS)
AC_SUBST(PARSER_LIBS)