blob: eef1b1c6700774eaeba7ba2971ad35bb3f6fb193 [file] [log] [blame]
Brad Bishop97cce002017-07-22 14:49:25 -04001# Base image class extension, inlined into every image.
2
3def build_uboot(d):
4 fstypes = d.getVar('IMAGE_FSTYPES', True).split()
5 if any([x.endswith('u-boot') for x in fstypes]):
6 return 'image_types_uboot'
7 return ''
8
9
10# Inherit u-boot classes if legacy uboot images are in use.
11IMAGE_TYPE_uboot = '${@build_uboot(d)}'
12inherit ${IMAGE_TYPE_uboot}
13
14# Inherit the overlay class if overlay is in use.
15IMAGE_TYPE_overlay = '${@bb.utils.contains("IMAGE_FSTYPES", "overlay", "image-overlay", "", d)}'
16inherit ${IMAGE_TYPE_overlay}