Don't use ac_save_* since they are overwritten by macro

This commit is contained in:
Tatsuhiro Tsujikawa 2016-02-03 00:48:47 +09:00
parent 4c05558273
commit 231665d67b
1 changed files with 14 additions and 14 deletions

View File

@ -189,18 +189,18 @@ else
d]) d])
fi fi
ac_save_CXXFLAGS="$CXXFLAGS" save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS= CXXFLAGS=
AX_CXX_COMPILE_STDCXX_11([noext], [optional]) AX_CXX_COMPILE_STDCXX_11([noext], [optional])
CXX1XCXXFLAGS="$CXXFLAGS" CXX1XCXXFLAGS="$CXXFLAGS"
CXXFLAGS="$ac_save_CXXFLAGS" CXXFLAGS="$save_CXXFLAGS"
AC_SUBST([CXX1XCXXFLAGS]) AC_SUBST([CXX1XCXXFLAGS])
AC_LANG_PUSH(C++) AC_LANG_PUSH(C++)
ac_save_CXXFLAGS="$CXXFLAGS" save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS="$CXXFLAGS $CXX1XCXXFLAGS" CXXFLAGS="$CXXFLAGS $CXX1XCXXFLAGS"
# Check that std::future is available. # Check that std::future is available.
@ -236,7 +236,7 @@ std::map<int, int>().emplace(1, 2);
[have_std_map_emplace=no [have_std_map_emplace=no
AC_MSG_RESULT([no])]) AC_MSG_RESULT([no])])
CXXFLAGS=$ac_save_CXXFLAGS CXXFLAGS=$save_CXXFLAGS
AC_LANG_POP() AC_LANG_POP()
@ -268,9 +268,9 @@ if test "x${have_zlib}" = "xno"; then
fi fi
# dl: openssl requires libdl when it is statically linked. # dl: openssl requires libdl when it is statically linked.
ac_save_LIBS=$LIBS save_LIBS=$LIBS
AC_SEARCH_LIBS([dlopen], [dl], [APPLDFLAGS="-ldl $APPLDFLAGS"], [], []) AC_SEARCH_LIBS([dlopen], [dl], [APPLDFLAGS="-ldl $APPLDFLAGS"], [], [])
LIBS=$ac_save_LIBS LIBS=$save_LIBS
# cunit # cunit
PKG_CHECK_MODULES([CUNIT], [cunit >= 2.1], [have_cunit=yes], [have_cunit=no]) PKG_CHECK_MODULES([CUNIT], [cunit >= 2.1], [have_cunit=yes], [have_cunit=no])
@ -303,7 +303,7 @@ AM_CONDITIONAL([HAVE_CUNIT], [ test "x${have_cunit}" = "xyes" ])
# libev (for src) # libev (for src)
# libev does not have pkg-config file. Check it in an old way. # libev does not have pkg-config file. Check it in an old way.
ac_save_LIBS=$LIBS save_LIBS=$LIBS
# android requires -lm for floor # android requires -lm for floor
AC_CHECK_LIB([ev], [ev_time], [have_libev=yes], [have_libev=no], [-lm]) AC_CHECK_LIB([ev], [ev_time], [have_libev=yes], [have_libev=no], [-lm])
if test "x${have_libev}" = "xyes"; then if test "x${have_libev}" = "xyes"; then
@ -315,7 +315,7 @@ if test "x${have_libev}" = "xyes"; then
AC_SUBST([LIBEV_CFLAGS]) AC_SUBST([LIBEV_CFLAGS])
fi fi
fi fi
LIBS=$ac_save_LIBS LIBS=$save_LIBS
# openssl (for src) # openssl (for src)
PKG_CHECK_MODULES([OPENSSL], [openssl >= 1.0.1], PKG_CHECK_MODULES([OPENSSL], [openssl >= 1.0.1],
@ -361,7 +361,7 @@ AM_CONDITIONAL([HAVE_LIBXML2], [ test "x${have_libxml2}" = "xyes" ])
# jemalloc # jemalloc
have_jemalloc=no have_jemalloc=no
if test "x${request_jemalloc}" != "xno"; then if test "x${request_jemalloc}" != "xno"; then
ac_save_LIBS=$LIBS save_LIBS=$LIBS
AC_SEARCH_LIBS([malloc_stats_print], [jemalloc], [have_jemalloc=yes], [], AC_SEARCH_LIBS([malloc_stats_print], [jemalloc], [have_jemalloc=yes], [],
[$PTHREAD_LDFLAGS]) [$PTHREAD_LDFLAGS])
@ -377,7 +377,7 @@ if test "x${request_jemalloc}" != "xno"; then
fi fi
fi fi
LIBS=$ac_save_LIBS LIBS=$save_LIBS
if test "x${have_jemalloc}" = "xyes" && if test "x${have_jemalloc}" = "xyes" &&
test "x${jemalloc_libs}" != "xnone required"; then test "x${jemalloc_libs}" != "xnone required"; then
@ -654,8 +654,8 @@ AM_CONDITIONAL([ENABLE_TINY_NGHTTPD],
[ test "x${have_epoll}" = "xyes" && [ test "x${have_epoll}" = "xyes" &&
test "x${have_timerfd_create}" = "xyes"]) test "x${have_timerfd_create}" = "xyes"])
ac_save_CFLAGS=$CFLAGS save_CFLAGS=$CFLAGS
ac_save_CXXFLAGS=$CXXFLAGS save_CXXFLAGS=$CXXFLAGS
CFLAGS= CFLAGS=
CXXFLAGS= CXXFLAGS=
@ -719,8 +719,8 @@ fi
WARNCFLAGS=$CFLAGS WARNCFLAGS=$CFLAGS
WARNCXXFLAGS=$CXXFLAGS WARNCXXFLAGS=$CXXFLAGS
CFLAGS=$ac_save_CFLAGS CFLAGS=$save_CFLAGS
CXXFLAGS=$ac_save_CXXFLAGS CXXFLAGS=$save_CXXFLAGS
AC_SUBST([WARNCFLAGS]) AC_SUBST([WARNCFLAGS])
AC_SUBST([WARNCXXFLAGS]) AC_SUBST([WARNCXXFLAGS])