Issues with bitbake for building Angstrom

939 views Asked by At

The issue I'm having is that I'm trying to build an Angstrom image from scratch using bitbake (since Angstrom is now Yocto Compatible) but I've run into an error the moment I run the bitbake systemd-image

Traceback (most recent call last):
  File "/usr/bin/bitbake", line 234, in <module>
    ret = main()
  File "/usr/bin/bitbake", line 197, in main
    server = ProcessServer(server_channel, event_queue, configuration)
  File "/usr/lib/pymodules/python2.7/bb/server/process.py", line 78, in __init__
    self.cooker = BBCooker(configuration, self.register_idle_function)
  File "/usr/lib/pymodules/python2.7/bb/cooker.py", line 76, in __init__
    self.parseConfigurationFiles(self.configuration.file)
  File "/usr/lib/pymodules/python2.7/bb/cooker.py", line 510, in parseConfigurationFiles
    data = _parse(os.path.join("conf", "bitbake.conf"), data)
TypeError: getVar() takes exactly 3 arguments (2 given)
ERROR: Error evaluating '${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:build-${BUILD_OS}:pn-${PN}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}:forcevariable${@bb.utils.contains("TUNE_FEATURES", "thumb", ":thumb", "", d)}${@bb.utils.contains("TUNE_FEATURES", "no-thumb-interwork", ":thumb-interwork", "", d)}'
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 116, in expandWithRefs
    s = __expand_var_regexp__.sub(varparse.var_sub, s)
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 60, in var_sub
    var = self.d.getVar(key, 1)
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 260, in getVar
    return self.expand(value, var)
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 132, in expand
    return self.expandWithRefs(s, varname).value
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 117, in expandWithRefs
    s = __expand_python_regexp__.sub(varparse.python_sub, s)
TypeError: getVar() takes exactly 3 arguments (2 given)

ERROR: Error evaluating '${@bb.parse.BBHandler.vars_from_file(d.getVar('FILE'),d)[0] or 'defaultpkgname'}'
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 117, in expandWithRefs
    s = __expand_python_regexp__.sub(varparse.python_sub, s)
  File "/usr/lib/pymodules/python2.7/bb/data_smart.py", line 76, in python_sub
    value = utils.better_eval(codeobj, DataContext(self.d))
  File "/usr/lib/pymodules/python2.7/bb/utils.py", line 387, in better_eval
    return eval(source, _context, locals)
  File "PN", line 1, in <module>
TypeError: getVar() takes exactly 3 arguments (2 given)

I've been at this for a while now, searching on different sites. Originally I tried following the guide at the developer section on the Angstrom site, but once I got some errors (prior to this one I'm putting here), I found Derek Molloy's site http://derekmolloy.ie/building-angstrom-for-beaglebone-from-source/ which solved those errors and gave a little more detail into the process.

Eventually I stumbled onto another forum post which decribed my problem, but unfortunately the answers weren't really clear (for me anyway) http://comments.gmane.org/gmane.linux.distributions.angstrom.devel/7431. I'm at a loss on what could be wrong, and I'm pretty much new to Yocto project so I'm unsure if there's any steps missing or something that's implicit that I have overlooked, so I would deeply appreciate anyone who could point me on the right direction on this.

As side note, I've been thinking that it could be something having to do with the environment-angstrom-... file that I have, since mine is environment-angstrom-v2013.12 and all the other examples use previous versions, I'm wondering if there's a new step involved when working with this.

2

There are 2 answers

2
Ross Burton On

Is there a reason why you are using a system-wide bitbake instead of the one that is compatible with that release of Angstrom?

0
Ross Burton On

Don't use a system-wide bitbake, as the bitbake API can and does change over time. Use the corresponding bitbake for that release of angstrom.

(This is breaking because your bitbake requires getVar to take three arguments but your angstrom layers are only passing two)