From 787dbed6c3f8000307da77ef93dceefdd7d390ea Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 22 Aug 2006 05:27:33 +0000 Subject: r17696: attempt to allow ldb to use an external popt directory, so we can point it at the popt sources in the samba source tree when building in the build farm (This used to be commit 13e14e0f8decbb7f3bafed9d980950d825a985e6) --- source4/lib/ldb/popt.m4 | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 source4/lib/ldb/popt.m4 (limited to 'source4/lib/ldb/popt.m4') diff --git a/source4/lib/ldb/popt.m4 b/source4/lib/ldb/popt.m4 new file mode 100644 index 0000000000..7c7969fa9d --- /dev/null +++ b/source4/lib/ldb/popt.m4 @@ -0,0 +1,29 @@ +################################################# +# Check to see if we should use an external src dir + +POPTDIR="" +AC_ARG_WITH(popt-src, +[ --with-popt-src set location of popt source], +[ +case "$withval" in + yes|no) + AC_MSG_ERROR([--with-popt-src called without argument]) + ;; + *) + POPTDIR="$withval" + ;; +esac ], +) + +if test x"$POPTDIR" = x; then + AC_CHECK_HEADERS(popt.h) + AC_CHECK_LIB(popt, poptGetContext) +else + POPTOBJ="findme.o popt.o poptconfig.o popthelp.o poptparse.o" + CFLAGS="$CFLAGS -I$POPTDIR" +fi + +AC_CHECK_HEADERS([float.h alloca.h]) +AC_CHECK_FUNCS(strerror) +AC_SUBST(POPTOBJ) +AC_SUBST(POPTDIR) -- cgit