TorizonCore Builder not working

Hello, I’m trying to use a device tree overlay on the Apalis IMX6 module with Torizon v5.0.0, using a Ixora V1.1A carrier board.

For that, i’m following the Toradex documentation: TorizonCore Builder Tool - Customization for Production Programming and Torizon OTA and Device Tree Overlays on Torizon

I was able to to successfully source the TorizonCore Builder version 2.5.4

I already have the correct TorizonCore image on my host machine, found here: https://artifacts.toradex.com/artifactory/torizoncore-oe-prerelease-frankfurt/dunfell-5.x.y/monthly/3/apalis-imx6/torizon-upstream/torizon-core-docker/oedeploy/torizon-core-docker-apalis-imx6-Tezi_5.0.0-devel-202010+build.3.tar

The issue is faced when i try to use some TorizonCore Builder features such as torizoncore-builder images unpack.

When trying to unpack the image:

$ torizoncore-builder images unpack torizon-core-docker-apalis-imx6-Tezi_5.0.0-devel-202010+build.3.tar
Unpacking Toradex Easy Installer image.
An unexpected Exception occured. Please provide the following stack trace to
the Toradex TorizonCore support team:


Traceback (most recent call last):
  File "/builder/torizoncore-builder", line 173, in <module>
    mainargs.func(mainargs)
  File "/builder/tcbuilder/cli/images.py", line 49, in do_images_unpack
    images.import_local_image(image_dir, dir_list[0], dir_list[1], dir_list[2])
  File "/builder/tcbuilder/backend/images.py", line 144, in import_local_image
    subprocess.check_output(tarcmd, shell=True, stderr=subprocess.STDOUT)
  File "/usr/lib/python3.9/subprocess.py", line 424, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/usr/lib/python3.9/subprocess.py", line 528, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'cat /workdir/torizon-core-docker-apalis-imx6-Tezi_5.0.0-devel-202010+build.3.tar | cat | tar -xf - -C /workdir' returned non-zero exit status 2.

Could you please come up with a solution for this?

Thanks!

Greetings @htoledo,

I couldn’t reproduce this on my side, it works without error.

Though I think I know what the issue here might be. When you first ran the setup script for the builder tool did you change directories since then?

To clarify, when you run the setup script it sets up an whatever directory you are currently in as the “working directory”. What this means is that the torizoncore-builder tool can only “see” files and directories that are in the working directory.

Therefore it might be a case where the tool can’t “see” the “torizon-core-docker-apalis-imx6-Tezi_5.0.0-devel-202010+build.3.tar” file. Either because the file exists outside of the context of the established working directory. Or you changed directories after you ran the setup script so you’re no longer in your working directory when running the tool.

In general it’s recommend to return to your working directory (wherever you ran the setup script) before running any torizoncore-builder commands.

Best Regards,
Jeremias

Thank you very much, Jeremias!

Best Regards,
Henrique

Glad I could help!