dnl ---------------- lua5.1 ----------------
PKG_CHECK_MODULES(LUA,lua5.1,[
CPPFLAGS="$CPPFLAGS $LUA_CFLAGS"
- LDFLAGS="$LDFLAGS $LUA_LIBS"
+ MUTTLIBS="$MUTTLIBS $LUA_LIBS"
],[AC_MSG_ERROR([could not find lua5.1])])
dnl ---------------- gpgme ----------------
if test -d $srcdir/../slang; then
mutt_cv_slang=$srcdir/../slang/src
CFLAGS="$CFLAGS -I${mutt_cv_slang}"
- LDFLAGS="$LDFLAGS -L${mutt_cv_slang}/objs"
+ MUTTLIBS="$MUTTLIBS -L${mutt_cv_slang}/objs"
else
if test -d ${prefix}/include/slang; then
CFLAGS="$CFLAGS -I${prefix}/include/slang"
if test -f $withval/src/slang.h; then
mutt_cv_slang=$withval/src
CFLAGS="$CFLAGS -I${mutt_cv_slang}"
- LDFLAGS="$LDFLAGS -L${mutt_cv_slang}/objs"
+ MUTTLIBS="$MUTTLIBS -L${mutt_cv_slang}/objs"
else
dnl ---Must be installed somewhere
mutt_cv_slang=$withval
elif test -d $withval/include; then
CFLAGS="$CFLAGS -I${withval}/include"
fi
- LDFLAGS="$LDFLAGS -L${withval}/lib"
+ MUTTLIBS="$MUTTLIBS -L${withval}/lib"
fi
fi
AC_MSG_RESULT($mutt_cv_slang)
mutt_cv_curses=$withval
fi
if test x$mutt_cv_curses != x/usr; then
- LDFLAGS="-L${mutt_cv_curses}/lib $LDFLAGS"
+ MUTTLIBS="-L${mutt_cv_curses}/lib $MUTTLIBS"
CPPFLAGS="$CPPFLAGS -I${mutt_cv_curses}/include"
fi
])
[CF_CURSES_LIBS])
])
- old_LIBS="$LIBS"
- LIBS="$LIBS $MUTTLIBS"
+ LIBS="$MUTTLIBS"
CF_CHECK_FUNCDECLS([#include <${cf_cv_ncurses_header-curses.h}>],
[start_color typeahead bkgdset curs_set meta use_default_colors resizeterm])
if test "$ac_cv_func_decl_start_color" != yes; then
AC_MSG_ERROR([Your curses library does not supports color.])
fi
- LIBS="$old_LIBS"
+ LIBS=""
])
AC_CHECK_HEADERS(stdarg.h sys/ioctl.h ioctl.h sysexits.h)
])
AC_CHECK_LIB(sasl2, sasl_client_init,,AC_MSG_ERROR([could not find libsasl2]))
-MUTTLIBS="$MUTTLIBS -lsasl2"
+MUTTLIBS="$MUTTLIBS $LIBS"
+LIBS=""
AC_ARG_WITH(idn, AC_HELP_STRING([--with-idn], [Use GNU libidn for domain names]),[
if test x$with_idn != xno ; then
AC_MSG_ERROR([libidn is too old, want 0.6 at least])
fi
CPPFLAGS="$CPPFLAGS $IDN_CFLAGS"
- LDFLAGS="$LDFLAGS $IDN_LIBS"
+ MUTTLIBS="$MUTTLIBS $IDN_LIBS"
AC_DEFINE(HAVE_LIBIDN, 1, [IDN Support])
],[AC_MSG_ERROR([could not find libidn])])
fi
AC_ARG_ENABLE(hcache, AC_HELP_STRING([--enable-hcache], [Enable header caching]),
[if test x$enableval = xyes; then
AC_DEFINE(USE_HCACHE, 1, [Enable header caching])
-
OLDCPPFLAGS="$CPPFLAGS"
- OLDLIBS="$LIBS"
-
need_md5="yes"
ac_prefer_qdbm=yes
GDBM_INC="-I$d/include"
GDBM_LIB="-L$d/lib"
CPPFLAGS="$OLDCPPFLAGS $GDBM_INC"
- LIBS="$OLDLIBS $GDBM_LIB -lgdbm"
+ LIBS="$MUTTLIBS $GDBM_LIB -lgdbm"
AC_TRY_LINK([#include <gdbm.h>],[gdbm_open(0,0,0,0,0);],[ac_cv_gdbmopen=yes])
fi
done
BDB_LIB_DIR="$d/lib/$v"
for l in `echo $BDB_VERSIONS`; do
CPPFLAGS="-I$BDB_INCLUDE_DIR $OLDCPPFLAGS"
- LIBS="$OLDLIBS -L$BDB_LIB_DIR -l$l"
+ LIBS="$MUTTLIBS -L$BDB_LIB_DIR -l$l"
AC_TRY_LINK([
#include <stdlib.h>
#include <db.h>
if test x$ac_qdbm_here = xyes; then
CPPFLAGS="$OLDCPPFLAGS $QDBM_CFLAGS"
- LIBS="$OLDLIBS $QDBM_LIBS"
+ MUTTLIBS="$MUTTLIBS $QDBM_LIBS"
AC_DEFINE(HAVE_QDBM, 1, [QDBM Support])
elif test x$ac_cv_gdbmopen = xyes; then
CPPFLAGS="$OLDCPPFLAGS $GDBM_INC"
- LIBS="$OLDLIBS $GDBM_LIB -lgdbm";
+ MUTTLIBS="$MUTTLIBS $GDBM_LIB -lgdbm";
AC_DEFINE(HAVE_GDBM, 1, [GDBM Support])
elif test x$ac_cv_dbcreate = xyes; then
CPPFLAGS="-I$BDB_INCLUDE_DIR $OLDCPPFLAGS"
- LIBS="$OLDLIBS -L$BDB_LIB_DIR -l$BDB_LIB"
+ MUTTLIBS="$MUTTLIBS -L$BDB_LIB_DIR -l$BDB_LIB"
AC_DEFINE(HAVE_DB4, 1, [Sleepycat DB4 Support])
else
AC_MSG_ERROR([You need one of: QDBM, GDBM or Sleepycat DB4 for --enable-hcache])
fi
+ LIBS=""
fi])
dnl -- end cache --
dnl (2) In glibc-2.1.2 and earlier there is a bug that messes up ob and
dnl obl when args 2 and 3 are 0 (fixed in glibc-2.1.3).
AC_CACHE_CHECK([whether this iconv is good enough], mutt_cv_iconv_good,
- mutt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
+ LIBS="$LIBICONV"
AC_TRY_RUN([
#include <iconv.h>
int main()
mutt_cv_iconv_good=yes,
mutt_cv_iconv_good=no,
mutt_cv_iconv_good=yes)
- LIBS="$mutt_save_LIBS")
+ LIBS="")
if test "$mutt_cv_iconv_good" = no; then
AC_MSG_ERROR(Try using libiconv instead)
fi