Skip to content

Commit

Permalink
build: use BOOST_MULTI_INDEX_ENABLE_SAFE_MODE when debugging
Browse files Browse the repository at this point in the history
Use of this macro enables precondition checks for iterators and
functions of the library. It's use is recommended in debug builds.

See:
https://www.boost.org/doc/libs/1_78_0/libs/multi_index/doc/tutorial/debug.html.
  • Loading branch information
fanquake committed May 19, 2022
1 parent fdb82a3 commit 06e18e0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1455,6 +1455,10 @@ if test "$use_boost" = "yes"; then
dnl we don't use multi_index serialization
BOOST_CPPFLAGS="$BOOST_CPPFLAGS -DBOOST_MULTI_INDEX_DISABLE_SERIALIZATION"

if test "$enable_debug" = "yes" || test "$enable_fuzz" = "yes"; then
BOOST_CPPFLAGS="$BOOST_CPPFLAGS -DBOOST_MULTI_INDEX_ENABLE_SAFE_MODE"
fi

if test "$suppress_external_warnings" != "no"; then
BOOST_CPPFLAGS=SUPPRESS_WARNINGS($BOOST_CPPFLAGS)
fi
Expand Down

0 comments on commit 06e18e0

Please sign in to comment.