From bbb725a8b6ac412c44495f59bea4afdefef885f4 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 5 Sep 2006 23:48:05 +0000 Subject: r18110: renamed config.m4 for popt (This used to be commit 495fcdddb2ead6f2cd6d1479cade1f025997f8ba) --- source4/lib/popt/config.m4 | 38 -------------------------------------- source4/lib/popt/libpopt.m4 | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 38 deletions(-) delete mode 100644 source4/lib/popt/config.m4 create mode 100644 source4/lib/popt/libpopt.m4 (limited to 'source4/lib/popt') diff --git a/source4/lib/popt/config.m4 b/source4/lib/popt/config.m4 deleted file mode 100644 index af9cb27851..0000000000 --- a/source4/lib/popt/config.m4 +++ /dev/null @@ -1,38 +0,0 @@ -################################################# -# Check to see if we should use the included popt - -INCLUDED_POPT=auto -AC_ARG_WITH(included-popt, -[ --with-included-popt use bundled popt library, not from system], -[ -case "$withval" in - yes) - INCLUDED_POPT=yes - ;; - no) - INCLUDED_POPT=no - ;; -esac ], -) -if test x"$INCLUDED_POPT" != x"yes"; then - AC_CHECK_HEADERS(popt.h) - AC_CHECK_LIB_EXT(popt, TMP_LIBPOPT_LIBS, poptGetContext, [], [], INCLUDED_POPT=no) - if test x"$ac_cv_header_popt_h" = x"no"; then - INCLUDED_POPT=yes - TMP_LIBPOPT_LIBS="" - fi -fi - -AC_MSG_CHECKING(whether to use included popt) -if test x"$INCLUDED_POPT" != x"no"; then - SMB_SUBSYSTEM(LIBPOPT, - [lib/popt/findme.o lib/popt/popt.o lib/popt/poptconfig.o lib/popt/popthelp.o lib/popt/poptparse.o], [], [-I$srcdir/lib/popt]) - - AC_MSG_RESULT(yes) -else - SMB_EXT_LIB(LIBPOPT, [${TMP_LIBPOPT_LIBS}]) - SMB_ENABLE(LIBPOPT,YES) - AC_MSG_RESULT(no) -fi - -AC_CHECK_HEADERS([float.h alloca.h]) diff --git a/source4/lib/popt/libpopt.m4 b/source4/lib/popt/libpopt.m4 new file mode 100644 index 0000000000..19b99f2bd0 --- /dev/null +++ b/source4/lib/popt/libpopt.m4 @@ -0,0 +1,14 @@ +dnl find the popt sources. This is meant to work both for +dnl popt standalone builds, and builds of packages using popt +poptdir="" +for d in "$srcdir" "$srcdir/lib/popt" "$srcdir/popt" "$srcdir/../popt"; do + if test -f "$d/popt.c"; then + poptdir="$d" + AC_SUBST(poptdir) + break; + fi +done +POPTOBJ="popt.o findme.o poptconfig.o popthelp.o poptparse.o" +AC_SUBST(POPTOBJ) + +AC_CHECK_HEADERS([float.h alloca.h]) -- cgit