From c46c9f43742bc5d7a28ae9ef969dc648d4d7d2fc Mon Sep 17 00:00:00 2001 From: Jonathan Hui Date: Thu, 9 Jan 2020 09:35:08 -0800 Subject: [PATCH] [examples-posix] fix undefined config macro warnings (#4458) --- examples/platforms/posix/alarm.c | 4 ++++ examples/platforms/posix/openthread-core-posix-config.h | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/examples/platforms/posix/alarm.c b/examples/platforms/posix/alarm.c index ef6d61f86..808b2e654 100644 --- a/examples/platforms/posix/alarm.c +++ b/examples/platforms/posix/alarm.c @@ -36,6 +36,10 @@ #include "utils/code_utils.h" +#ifndef __linux__ +#define __linux__ 0 +#endif + // linux microsecond timer #if __linux__ diff --git a/examples/platforms/posix/openthread-core-posix-config.h b/examples/platforms/posix/openthread-core-posix-config.h index 627d76cbe..465c69b22 100644 --- a/examples/platforms/posix/openthread-core-posix-config.h +++ b/examples/platforms/posix/openthread-core-posix-config.h @@ -35,6 +35,10 @@ #ifndef OPENTHREAD_CORE_POSIX_CONFIG_H_ #define OPENTHREAD_CORE_POSIX_CONFIG_H_ +#ifndef OPENTHREAD_RADIO +#define OPENTHREAD_RADIO 0 +#endif + /** * @def OPENTHREAD_CONFIG_PLATFORM_INFO *