build: make NM_MORE_ASSERTS define numeric for different levels of more-asserts
Allows to enable more-asserts more granularly. Unfortunately, the old check was "${enable_more_asserts} == "yes", thus we cannot extend "--enable-more-assert=level" because that would mean that the same build script cannot set the option on both old and new NetworkManager. Thus, add a new option --with-more-asserts=level. If you put the following in your build script, it will work as expected whether you build a new or an old version of NetworkManager. ./configure --enable-more-asserts --with-more-asserts=5
This commit is contained in:
@@ -179,7 +179,7 @@
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
#ifdef NM_MORE_ASSERTS
|
||||
#if NM_MORE_ASSERTS
|
||||
#define nm_assert(cond) G_STMT_START { g_assert (cond); } G_STMT_END
|
||||
#else
|
||||
#define nm_assert(cond) G_STMT_START { if (FALSE) { if (cond) { } } } G_STMT_END
|
||||
|
Reference in New Issue
Block a user