From f198c6ba49784df2c905f85543eb44fc21653aa9 Mon Sep 17 00:00:00 2001 From: gojimmypi Date: Fri, 31 Oct 2025 11:11:05 -0700 Subject: [PATCH] Hard fail if the wrong user settings is detected --- hal/library.c | 6 ++++++ src/image.c | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/hal/library.c b/hal/library.c index ca7f83827d..00e0b5230b 100644 --- a/hal/library.c +++ b/hal/library.c @@ -46,6 +46,12 @@ #undef NO_FILESYSTEM #endif +#ifdef WOLFBOOT_KEYTOOLS + /* this code needs to use the Use ./include/user_settings.h file */ + #error "The wrong user_settings.h has been included." +#endif + + /* HAL Stubs */ void hal_init(void) { diff --git a/src/image.c b/src/image.c index 16312dcc8a..cb0572dc5f 100644 --- a/src/image.c +++ b/src/image.c @@ -30,6 +30,11 @@ #include #endif #include /* for wolfCrypt hash/sign routines */ +#ifdef WOLFBOOT_KEYTOOLS + /* this code needs to use the Use ./include/user_settings.h, not keytools */ + #error "The wrong user_settings.h has been included." +#endif + #include #include