mirror of https://github.com/ArduPilot/ardupilot
waf: don't build CAN libraries if CAN not supported
This commit is contained in:
parent
2fe08b6177
commit
a136c28122
|
@ -17,6 +17,13 @@ SOURCE_EXTS = [
|
|||
'*.cpp',
|
||||
]
|
||||
|
||||
COMMON_VEHICLE_DEPENDENT_CAN_LIBRARIES = [
|
||||
'AP_CANManager',
|
||||
'AP_KDECAN',
|
||||
'AP_PiccoloCAN',
|
||||
'AP_PiccoloCAN/piccolo_protocol',
|
||||
]
|
||||
|
||||
COMMON_VEHICLE_DEPENDENT_LIBRARIES = [
|
||||
'AP_Airspeed',
|
||||
'AP_AccelCal',
|
||||
|
@ -27,7 +34,6 @@ COMMON_VEHICLE_DEPENDENT_LIBRARIES = [
|
|||
'AP_BattMonitor',
|
||||
'AP_BoardConfig',
|
||||
'AP_Camera',
|
||||
'AP_CANManager',
|
||||
'AP_Common',
|
||||
'AP_Compass',
|
||||
'AP_Declination',
|
||||
|
@ -35,7 +41,6 @@ COMMON_VEHICLE_DEPENDENT_LIBRARIES = [
|
|||
'AP_HAL',
|
||||
'AP_HAL_Empty',
|
||||
'AP_InertialSensor',
|
||||
'AP_KDECAN',
|
||||
'AP_Math',
|
||||
'AP_Mission',
|
||||
'AP_DAL',
|
||||
|
@ -74,8 +79,6 @@ COMMON_VEHICLE_DEPENDENT_LIBRARIES = [
|
|||
'AP_SBusOut',
|
||||
'AP_IOMCU',
|
||||
'AP_Parachute',
|
||||
'AP_PiccoloCAN',
|
||||
'AP_PiccoloCAN/piccolo_protocol',
|
||||
'AP_RAMTRON',
|
||||
'AP_RCProtocol',
|
||||
'AP_Radio',
|
||||
|
@ -249,11 +252,8 @@ def ap_get_all_libraries(bld):
|
|||
def ap_common_vehicle_libraries(bld):
|
||||
libraries = COMMON_VEHICLE_DEPENDENT_LIBRARIES
|
||||
|
||||
if bld.env.DEST_BINFMT == 'pe':
|
||||
libraries += [
|
||||
'AC_Fence',
|
||||
'AC_AttitudeControl',
|
||||
]
|
||||
if bld.env.with_can or bld.env.HAL_NUM_CAN_IFACES:
|
||||
libraries.extend(COMMON_VEHICLE_DEPENDENT_CAN_LIBRARIES)
|
||||
|
||||
return libraries
|
||||
|
||||
|
|
Loading…
Reference in New Issue