Override device-identity script

Hello,

I’m trying to override mender-integrity script in yocto warrior for orange-pi-zero but seems it fails with below:

ERROR: ExpansionError during parsing /home/marek/projects/test/mender-test/mender/meta-mender-core/recipes-mender/mender/mender_git1.x.bb                                                       | ETA:  --:--:--
Traceback (most recent call last):
  File "/home/marek/projects/test/mender-test/poky/bitbake/lib/bb/utils.py", line 423, in better_eval(source=<code object <module> at 0x7f8442c09780, file "Var <SRCPV>", line 1>, locals={'d': <bb.data_smart.DataSmart object at 0x7f843fdca668>}, extraglobals={'d': <bb.data_smart.DataSmart object at 0x7f843fdca668>}):
                 ctx[g] = extraglobals[g]
    >    return eval(source, ctx, locals)
     
  File "Var <SRCPV>", line 1, in <module>
  File "/home/marek/projects/test/mender-test/poky/bitbake/lib/bb/fetch2/__init__.py", line 747, in get_srcrev(d=<bb.data_smart.DataSmart object at 0x7f843fdca668>, method_name='sortable_revision'):
         scms = []
    >    fetcher = Fetch(d.getVar('SRC_URI').split(), d)
         urldata = fetcher.ud
  File "/home/marek/projects/test/mender-test/poky/bitbake/lib/bb/fetch2/__init__.py", line 1603, in Fetch.__init__(urls=['git://github.com/mendersoftware/mender;protocol=https;branch=2.3.x', 'files://mender-device-identity', 'file://mender.service'], d=<bb.data_smart.DataSmart object at 0x7f843fdca668>, cache=True, localonly=False, connection_cache=None):
                     try:
    >                    self.ud[url] = FetchData(url, d, localonly)
                     except NonLocalMethod:
  File "/home/marek/projects/test/mender-test/poky/bitbake/lib/bb/fetch2/__init__.py", line 1264, in FetchData.__init__(url='files://mender-device-identity', d=<bb.data_smart.DataSmart object at 0x7f843fdca668>, localonly=False):
             if not self.method:
    >            raise NoMethodError(url)
     
bb.data_smart.ExpansionError: Failure expanding variable SRCPV, expression was ${@bb.fetch2.get_srcrev(d)} which triggered exception NoMethodError: Could not find a fetcher which supports the URL: 'files://mender-device-identity'

I created in my layer mender_%.bbappend recipe with this content:

FILESEXTRAPATHS_prepend := "${THISDIR}/files:"

SRC_URI += "files://mender-device-identity"

do_install_append() {
        install -d ${D}${datadir}/mender/identity
        install -m 755 ${WORKDIR}/mender-device-identity ${D}${datadir}/mender/identity
}

Am I missing something here? Thanks.

marek

should be 's/files:/file/g'. Sorry for the noise :). I probably need more :coffee: in the morning.

2 Likes