blob: f2f2d318efa9f1ebc3c01e067970e2666c394dd5 [file] [log] [blame]
Saqib Khana8433f52017-09-22 10:21:30 -05001inherit image_version
2
Adriana Kobylak48c8fa32017-08-19 09:32:18 -05003SRC_URI += "file://0001-configs-ast-Add-redundnant-env.patch"
4
Patrick Williams0f19eb52017-07-27 13:32:33 -05005SRC_URI += "${@bb.utils.contains('MACHINE_FEATURES', 'obmc-ubi-fs', \
Adriana Kobylak57ba9982017-08-15 20:08:42 -05006 'file://0001-config-ast-common-hack-bootopts.patch \
Edward A. Jamesa1cb3232017-11-09 16:03:14 -06007 file://0004-config-ast-common-ubi-bootops.patch \
8 file://0001-config-ast-common-Add-conditional-factory-reset-comm.patch', '', d)}"
Patrick Williams0f19eb52017-07-27 13:32:33 -05009
Saqib Khana8433f52017-09-22 10:21:30 -050010python do_configure () {
Michael Tritz687c74e2018-01-25 10:06:21 -060011 if "obmc-ubi-fs" in d.getVar("MACHINE_FEATURES", True):
Saqib Khana8433f52017-09-22 10:21:30 -050012 version_id=do_get_versionID(d)
13 d.setVar('VERSION_ID', version_id)
14 bb.build.exec_func("patch_uboot", d)
15}
16
17patch_uboot () {
18 sed -i "s/kernel-0/kernel-${VERSION_ID}/g" \
19 ${S}/patches/0004-config-ast-common-ubi-bootops.patch &> /dev/null
20 sed -i "s/kernel-0/kernel-${VERSION_ID}/g" \
21 ${S}/include/configs/ast-common.h &> /dev/null
22}