summaryrefslogtreecommitdiff
path: root/source4/popt
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2003-12-02 11:10:56 +0000
committerJelmer Vernooij <jelmer@samba.org>2003-12-02 11:10:56 +0000
commit47702c85524afceba520cc3c2d2bc0d9a4e02e40 (patch)
tree4af410fdae9bca347bdfa23f78ebaa0026e51873 /source4/popt
parent10ad200350e304f1ca7b4080a04f4fe4eeb80763 (diff)
downloadsamba-47702c85524afceba520cc3c2d2bc0d9a4e02e40.tar.gz
samba-47702c85524afceba520cc3c2d2bc0d9a4e02e40.tar.bz2
samba-47702c85524afceba520cc3c2d2bc0d9a4e02e40.zip
Initial step at cleaning and splitting up configure.in.
(This used to be commit 369a9c1ac1ff94a1d3f51eac20a39577f9cf2155)
Diffstat (limited to 'source4/popt')
-rw-r--r--source4/popt/config.m431
1 files changed, 31 insertions, 0 deletions
diff --git a/source4/popt/config.m4 b/source4/popt/config.m4
new file mode 100644
index 0000000000..7532c5826e
--- /dev/null
+++ b/source4/popt/config.m4
@@ -0,0 +1,31 @@
+#################################################
+# Check to see if we should use the included popt
+
+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_LIB(popt, poptGetContext,
+ INCLUDED_POPT=no, INCLUDED_POPT=yes)
+fi
+
+AC_MSG_CHECKING(whether to use included popt)
+if test x"$INCLUDED_POPT" = x"yes"; then
+ AC_MSG_RESULT(yes)
+ BUILD_POPT='$(POPT_OBJS)'
+ FLAGS1="-I$srcdir/popt"
+else
+ AC_MSG_RESULT(no)
+ LIBS="$LIBS -lpopt"
+fi
+AC_SUBST(BUILD_POPT)
+AC_SUBST(FLAGS1)