summaryrefslogtreecommitdiff
path: root/m4/ax_boost_chrono.m4
diff options
context:
space:
mode:
authorVasil Dimov <vd@FreeBSD.org>2018-03-13 12:13:21 +0100
committerPeter Simons <simons@cryp.to>2018-03-13 20:07:31 +0100
commitfe85abafcf7d881f102399ac50b4fb13cbeca9c2 (patch)
tree3ab40b461f86299b6fdbaf7a5fd44f1ec56dced0 /m4/ax_boost_chrono.m4
parentc469e3d2c84721019bca0e0cc4c27cf67350ebbb (diff)
downloadautoconf-archive-fe85abafcf7d881f102399ac50b4fb13cbeca9c2.tar.gz
fix checks for boost chrono and unit_test
The two test programs could produce a compiler warnings (or errors if -Werror is engaged) about unused variables and fail the checks. It is better to have test programs that do not produce warnings. Closes https://github.com/peti/autoconf-archive/pull/148.
Diffstat (limited to 'm4/ax_boost_chrono.m4')
-rw-r--r--m4/ax_boost_chrono.m44
1 files changed, 2 insertions, 2 deletions
diff --git a/m4/ax_boost_chrono.m4 b/m4/ax_boost_chrono.m4
index 5763769..6ea77b9 100644
--- a/m4/ax_boost_chrono.m4
+++ b/m4/ax_boost_chrono.m4
@@ -29,7 +29,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 3
+#serial 4
AC_DEFUN([AX_BOOST_CHRONO],
[
@@ -68,7 +68,7 @@ AC_DEFUN([AX_BOOST_CHRONO],
CXXFLAGS_SAVE=$CXXFLAGS
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include <boost/chrono.hpp>]],
- [[boost::chrono::system_clock::time_point time;]])],
+ [[boost::chrono::system_clock::time_point* time = new boost::chrono::system_clock::time_point; delete time;]])],
ax_cv_boost_chrono=yes, ax_cv_boost_chrono=no)
CXXFLAGS=$CXXFLAGS_SAVE
AC_LANG_POP([C++])