diff --git a/libraries/AP_RCMapper/AP_RCMapper.cpp b/libraries/AP_RCMapper/AP_RCMapper.cpp index fc09016e1d..39af6944ae 100644 --- a/libraries/AP_RCMapper/AP_RCMapper.cpp +++ b/libraries/AP_RCMapper/AP_RCMapper.cpp @@ -1,3 +1,7 @@ +#include "AP_RCMapper_config.h" + +#if AP_RCMAPPER_ENABLED + #include #include "AP_RCMapper.h" @@ -75,3 +79,5 @@ RCMapper::RCMapper(void) RCMapper *AP::rcmap() { return RCMapper::get_singleton(); } + +#endif // AP_RCMAPPER_ENABLED diff --git a/libraries/AP_RCMapper/AP_RCMapper_config.h b/libraries/AP_RCMapper/AP_RCMapper_config.h index ad11cb1785..021ff08c25 100644 --- a/libraries/AP_RCMapper/AP_RCMapper_config.h +++ b/libraries/AP_RCMapper/AP_RCMapper_config.h @@ -1,5 +1,7 @@ #pragma once +#include + #ifndef AP_RCMAPPER_ENABLED #define AP_RCMAPPER_ENABLED 1 #endif