diff --git a/ArduSub/system.cpp b/ArduSub/system.cpp index f3639b96ca..55d571e553 100644 --- a/ArduSub/system.cpp +++ b/ArduSub/system.cpp @@ -275,8 +275,11 @@ bool Sub::should_log(uint32_t mask) #include // dummy method to avoid linking AFS +#if AP_ADVANCEDFAILSAFE_ENABLED bool AP_AdvancedFailsafe::gcs_terminate(bool should_terminate, const char *reason) { return false; } AP_AdvancedFailsafe *AP::advancedfailsafe() { return nullptr; } +#endif + #if HAL_ADSB_ENABLED // dummy method to avoid linking AP_Avoidance AP_Avoidance *AP::ap_avoidance() { return nullptr; }