From c81bb426a9f2ba90d945b4041a6164384769a236 Mon Sep 17 00:00:00 2001 From: Michal Paszta Date: Wed, 24 Oct 2018 14:35:25 +0300 Subject: [PATCH] Fix for unit test build on Windows machines In case MINGW is detected - define MBED_WEAK to be empty, as Windows executables cannot handle the weak attribute. --- platform/mbed_toolchain.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/platform/mbed_toolchain.h b/platform/mbed_toolchain.h index d5864295da..99e1cc1178 100644 --- a/platform/mbed_toolchain.h +++ b/platform/mbed_toolchain.h @@ -144,6 +144,8 @@ #ifndef MBED_WEAK #if defined(__ICCARM__) #define MBED_WEAK __weak +#elif defined(__MINGW32__) +#define MBED_WEAK #else #define MBED_WEAK __attribute__((weak)) #endif