AP_Vehicle: correct compilation when AP_Vehicle not available

This commit is contained in:
Peter Barker 2023-12-12 23:10:18 +11:00 committed by Peter Barker
parent 0f4262de3d
commit 8e1fc60550
3 changed files with 16 additions and 0 deletions

View File

@ -1,3 +1,7 @@
#include "AP_Vehicle_config.h"
#if AP_VEHICLE_ENABLED
#include "AP_Vehicle.h"
#include <AP_BLHeli/AP_BLHeli.h>
@ -1029,3 +1033,4 @@ AP_Vehicle *vehicle()
};
#endif // AP_VEHICLE_ENABLED

View File

@ -14,6 +14,10 @@
*/
#pragma once
#include "AP_Vehicle_config.h"
#if AP_VEHICLE_ENABLED
/*
this header holds a parameter structure for each vehicle type for
parameters needed by multiple libraries
@ -490,3 +494,5 @@ extern const AP_HAL::HAL& hal;
extern const AP_Param::Info vehicle_var_info[];
#include "AP_Vehicle_Type.h"
#endif // AP_VEHICLE_ENABLED

View File

@ -0,0 +1,5 @@
#pragma once
#ifndef AP_VEHICLE_ENABLED
#define AP_VEHICLE_ENABLED 1
#endif