Skip to content

Commit 85a2d02

Browse files
committed
add compat macro for cmake <2.0.0
1 parent b1ec95d commit 85a2d02

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/test.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,15 @@
77

88
#include <cmocka.h>
99

10+
/*
11+
* note: we can't use cmocka_version.h for our purpose because
12+
* cmoca_version.h and assert_uint_in_range were introduced
13+
* together by cmocka-2.0.0.
14+
*/
15+
#if !defined(assert_uint_in_range)
16+
#define assert_uint_in_range(a, b, c) assert_in_range(a, b, c)
17+
#endif
18+
1019
#include "endian.h"
1120
#include "idalloc.h"
1221
#include "leb128.h"

0 commit comments

Comments
 (0)