From ed38aadc7272c7a41bd42cd3a07fe2009003e66c Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Sat, 16 Jul 2022 09:38:26 +1000 Subject: [PATCH] AP_EFI: add and use AP_EFI_config.h --- libraries/AP_EFI/AP_EFI.h | 9 ++++----- libraries/AP_EFI/AP_EFI_config.h | 7 +++++++ 2 files changed, 11 insertions(+), 5 deletions(-) create mode 100644 libraries/AP_EFI/AP_EFI_config.h diff --git a/libraries/AP_EFI/AP_EFI.h b/libraries/AP_EFI/AP_EFI.h index 8b60b0711a..b5c7973ad0 100644 --- a/libraries/AP_EFI/AP_EFI.h +++ b/libraries/AP_EFI/AP_EFI.h @@ -15,15 +15,14 @@ #pragma once +#include "AP_EFI_config.h" + +#if HAL_EFI_ENABLED + #include #include #include -#ifndef HAL_EFI_ENABLED -#define HAL_EFI_ENABLED !HAL_MINIMIZE_FEATURES && BOARD_FLASH_SIZE > 1024 -#endif - -#if HAL_EFI_ENABLED #include "AP_EFI_Backend.h" #include "AP_EFI_State.h" diff --git a/libraries/AP_EFI/AP_EFI_config.h b/libraries/AP_EFI/AP_EFI_config.h new file mode 100644 index 0000000000..9cbc0a059e --- /dev/null +++ b/libraries/AP_EFI/AP_EFI_config.h @@ -0,0 +1,7 @@ +#pragma once + +#include + +#ifndef HAL_EFI_ENABLED +#define HAL_EFI_ENABLED !HAL_MINIMIZE_FEATURES && BOARD_FLASH_SIZE > 1024 +#endif