Using OpenEmbedded to create a Qt toolchain for Apalis iMX6Q

Hi there,

I’ve facing some errors during the build process to generate a valid toolchain to be used in Qt creator to develop applications targeting toradex Apalis iMX6Q. First of all I’m using Linux Mint 18.1 Serena based on Ubuntu 16.04 as host machine.

I followed this tutorial here as suggested by toradex team.

On the first part (Prerequisites section) I ran the following code related to Ubuntu 16.04 64bit version:

sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install g++-5-multilib
sudo apt-get install curl dosfstools gawk g++-multilib gcc-multilib lib32z1-dev libcrypto++9v5:i386 libcrypto++-dev:i386 liblzo2-dev:i386 lzop libsdl1.2-dev libstdc++-5-dev:i386 libusb-1.0-0:i386 libusb-1.0-0-dev:i386 uuid-dev:i386 texinfo chrpath
cd /usr/lib; sudo ln -s libcrypto++.so.9.0.0 libcryptopp.so.6

On the Installation section:

mkdir ~/bin
export PATH=~/bin:$PATH
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo

and then:

mkdir oe-core
cd oe-core
repo init -u http://git.toradex.com/toradex-bsp-platform.git -b LinuxImageV2.7
repo sync

Exported the system variables as in:

. export

Once in the build directory I had to modify my local.conf file, located at build/conf/local.conf to setup the MACHINE variable to MACHINE ?= "apalis-imx6" and added the ACCEPT_FSL_EULA = "1" to the file.

At the end, in the Building section I tried to generate the toolchain targeting Qt Creator:

bitbake angstrom-qt-x11-image -c populate_sdk

but I just got this error here:

ERROR: Execution of event handler 'config_reparse_eventhandler' failed
Traceback (most recent call last):
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/build.py", line 261, in exec_func(func='oecore_update_bblayers', d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>, dirs=None, pythonexception=True):
             if ispython:
    >            exec_func_python(func, d, runfile, cwd=adir, pythonexception=pythonexception)
             else:
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/build.py", line 306, in exec_func_python(func='oecore_update_bblayers', d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>, runfile='/home/prjs/apalis/oe-core/build/tmp-glibc/work/armv7at2hf-neon-angstrom-linux-gnueabi/defaultpkgname/1.0-r0/temp/run.oecore_update_bblayers.18168', cwd=None, pythonexception=True):
             comp = utils.better_compile(code, func, "exec_python_func() autogenerated")
    >        utils.better_exec(comp, {"d": d}, code, "exec_python_func() autogenerated", pythonexception=pythonexception)
         except (bb.parse.SkipRecipe, bb.build.FuncFailed):
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/utils.py", line 399, in better_exec(code=<code object <module> at 0x7faa9cee4f60, file "exec_python_func() autogenerated", line 2>, context={'d': <bb.data_smart.DataSmart object at 0x7faa9d3cd630>}, text='\noecore_update_bblayers(d)\n', realfile='exec_python_func() autogenerated', pythonexception=True):
         try:
    >        exec(code, get_context(), context)
         except (bb.BBHandledException, bb.parse.SkipRecipe, bb.build.FuncFailed, bb.data_smart.ExpansionError):
  File "exec_python_func() autogenerated", line 2, in <module>
  File "/home/prjs/apalis/oe-core/build/../layers/openembedded-core/meta/classes/sanity.bbclass", line 84, in oecore_update_bblayers(d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>):
         current_lconf = int(d.getVar('LCONF_VERSION', True))
    >    lconf_version = int(d.getVar('LAYER_CONF_VERSION', True))
     
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'

ERROR: Error parsing configuration files
Traceback (most recent call last):
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/build.py", line 261, in exec_func(func='oecore_update_bblayers', d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>, dirs=None, pythonexception=True):
             if ispython:
    >            exec_func_python(func, d, runfile, cwd=adir, pythonexception=pythonexception)
             else:
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/build.py", line 306, in exec_func_python(func='oecore_update_bblayers', d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>, runfile='/home/prjs/apalis/oe-core/build/tmp-glibc/work/armv7at2hf-neon-angstrom-linux-gnueabi/defaultpkgname/1.0-r0/temp/run.oecore_update_bblayers.18168', cwd=None, pythonexception=True):
             comp = utils.better_compile(code, func, "exec_python_func() autogenerated")
    >        utils.better_exec(comp, {"d": d}, code, "exec_python_func() autogenerated", pythonexception=pythonexception)
         except (bb.parse.SkipRecipe, bb.build.FuncFailed):
  File "/home/prjs/apalis/oe-core/layers/openembedded-core/bitbake/lib/bb/utils.py", line 399, in better_exec(code=<code object <module> at 0x7faa9cee4f60, file "exec_python_func() autogenerated", line 2>, context={'d': <bb.data_smart.DataSmart object at 0x7faa9d3cd630>}, text='\noecore_update_bblayers(d)\n', realfile='exec_python_func() autogenerated', pythonexception=True):
         try:
    >        exec(code, get_context(), context)
         except (bb.BBHandledException, bb.parse.SkipRecipe, bb.build.FuncFailed, bb.data_smart.ExpansionError):
  File "exec_python_func() autogenerated", line 2, in <module>
  File "/home/prjs/apalis/oe-core/build/../layers/openembedded-core/meta/classes/sanity.bbclass", line 84, in oecore_update_bblayers(d=<bb.data_smart.DataSmart object at 0x7faa9d3cd630>):
         current_lconf = int(d.getVar('LCONF_VERSION', True))
    >    lconf_version = int(d.getVar('LAYER_CONF_VERSION', True))
     
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'

Could someone help me on this issue? I already tried different solutions, but none of them solved this error.

Best regards,

Layon

Could it be that you failed mentioning that you also got a similar error message during repo sync as outlined in the following thread?

Hello Marcel,

During my repo sync step I got success as you can see here:

layon-VirtualBox oe-core # repo sync
Fetching project meta-qt5.git
Fetching project meta-toradex-demos.git
Fetching project meta-toradex-nxp.git
Fetching project meta-angstrom.git
Fetching projects:   5% (1/17)  Fetching project meta-jetson-tk1.git
Fetching projects:  11% (2/17)  Fetching project meta-toradex-bsp-common.git
Fetching projects:  17% (3/17)  Fetching project meta-toradex-tegra.git
Fetching projects:  23% (4/17)  Fetching project meta-freescale-3rdparty.git
Fetching projects:  29% (5/17)  Fetching project bitbake.git
Fetching projects:  35% (6/17)  Fetching project meta-browser.git
Fetching projects:  41% (7/17)  Fetching project meta-qt4
Fetching projects:  47% (8/17)  Fetching project openembedded-core.git
Fetching projects:  52% (9/17)  Fetching project meta-freescale-distro.git
Fetching projects:  58% (10/17)  Fetching project meta-lxde.git
Fetching projects:  64% (11/17)  Fetching project meta-linaro.git
Fetching projects:  70% (12/17)  Fetching project meta-openembedded.git
From http://github.com/openembedded/openembedded-core
   7f3c3d8..7f9806a  master     -> repo/master
Fetching projects:  76% (13/17)  Fetching project meta-freescale.git
Fetching projects: 100% (17/17), done.  

Already put my credentials using:

git config --global user.email "layonluciano@gmail.com"
git config --global user.name "Layon Luciano"

but the real problem is during the bitbake step ( bitbake angstrom-qt-x11-image -c populate_sdk ) , once I got that error as I mentioned before:

ERROR: Execution of event handler 'config_reparse_eventhandler' failed

Thanks in advance,

Layon

Could someone help me? I really got stuck on this issue.

Thanks!

Does building meta-toolchain-qt5 as per here succeed?