Running build-debug-arm64 stop

Hello,
I have Apalis im8 board, with Torizon system installed on it. And on the development machine I have VS code / Windows 10, and I added Toradex extension last version.

I followed the steps at the developer pages to compile my first Qt6/Qml program, but at the build-debug-arm64 the building stops always with messages:
Errors were encountered while processing:
/tmp/apt-dpkg-install-AHpHbB/084-libvulkan-dev_1.3.239.0-1_arm64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

I checked all the dependencies, everything is Ok.

What is the problem please? How can I solve this issue?

Thanks a lot in advance

Hi, I’m the Toradex AI Assistant. I’m in early beta, and I would appreciate your feedback.
The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello,

The error you’re encountering during the build-debug-arm64 process with the message related to libvulkan-dev package installation failure is typically indicative of a problem with the package itself or a dependency issue that isn’t immediately obvious. Here are a few steps you can take to troubleshoot and potentially resolve the issue:

  1. Update and Upgrade the System: Ensure your development environment and the Torizon system on the Apalis iMX8 board are fully updated. Sometimes, package dependencies require the latest versions of other packages, and updating can resolve these issues.

    On your Torizon device, you can execute the following commands:

    sudo apt-get update
    sudo apt-get upgrade
    
  2. Check for Specific Dependency Errors: The error message you provided suggests there might be a more specific dependency issue at play. Look closely at the output before the error message for hints on what might be causing the problem with libvulkan-dev.

  3. Manually Install the Problematic Package: Try manually installing libvulkan-dev on your Torizon device to see if the error provides more details. Use the command:

    sudo apt-get install libvulkan-dev
    

    This might give you more insight into what’s going wrong.

  4. Investigate Vulkan Support: The libvulkan-dev package is related to Vulkan development. Ensure that the Apalis iMX8 and your current Torizon configuration support Vulkan. Not all hardware configurations may support Vulkan or may require specific drivers or settings to do so.

  5. Use Docker Containers for Dependency Management: If you’re not already doing so, consider using Docker containers for your development. Containers can help encapsulate dependencies and might bypass the issue you’re encountering. The Toradex extension for VS Code and TorizonCore make it straightforward to develop within Docker containers.

  6. Review Qt6/QML Project Configuration: Ensure that your Qt6/QML project configuration in VS Code does not inadvertently specify a version of libvulkan-dev or related packages that is incompatible with what’s available or expected by Torizon.

If after these steps the issue persists, it might be beneficial to look into the specifics of the libvulkan-dev package version compatibility with the Torizon version on your Apalis iMX8 board. Sometimes, specific versions of libraries or packages have known issues that are documented in release notes or forums.

Best regards,
Toradex AI Assistant

Please, also check if these links can help you solve your problem:

Building Machine Learning Software with Reference Images for Yocto Project | Toradex Developer Center.

Greetings @tarekmhnds,

First of all, is this issue reproducible for you? For example, if you create a new VSCode project with our extension from scratch, does the issue happen again?

If this is reproducible, then can you please detail your exact process from the start to reproduce this issue.

Best Regards,
Jeremias

Greetings Jeremias,

Yes it is reproducible. I tried to compile many new Qt/Qml projects, and everytime I got the same issue.

I start the Apalis board with Torizon os image installed on it, then from my computer (With Windows 10), I start VS code, then I connect WSL with Torizon, then I connect the Apalis device with username: Torizon, password: Torizon from Torizon left tab in VS code, then from explorer tab: I create a new Qt/Qml6 project with a new name for the project and the Docker container, according to this page:
Remote Deploy and Debug Projects
After RUN and Debug with Torizon ARMv8 I got this issue everytime.
Can you check this please? How to solve this please?

Best regards,
Tarek

I attempted to reproduce this on my own Windows 10 setup and it worked as expected. I was able to build and debug the application without issues.

There must be some difference on your setup that is causing this issue. I’ll need more information however, as it’s not obvious yet why this is happening only on your setup. Could you share the full logs from the VSCode terminal when you run the debug task. I want to see the entire log output not just the error message.

Best Regards,
Jeremias

Hi Jeremias,

Thanks a lot for your support.

I sent the logs file from VS code terminal to you by WeTransfer, I cann’t upload it here. And the length is big, and more than 2 attachment is not allowed.

This is the download link:
https://we.tl/t-ZYwIhzrGcs

Best regards,
Tarek

I can’t seem to access the logs from WeTransfer for some reason. Could you instead upload them via our file-sharing server: https://share.toradex.com/

Best Regards,
Jeremias

I uploaded the file to your file-sharing server, this is the link:
https://share.toradex.com/pdca1uaur1cbznj

Thanks a lot.

Best regards,
Tarek

Okay with your logs I think I know what the issue is.

So in your setup the command used to build the SDK container is:

docker build --pull -f /home/tarekmh/VanSystemTest/Dockerfile.sdk /home/tarekmh/VanSystemTest -t cross-toolchain-arm64-vansys --build-arg IMAGE_ARCH=arm64 --build-arg GPU=-imx8 --build-arg APP_ROOT=/home/torizon/app

In my setup it’s:

docker build --pull -f /home/coj/test/Dockerfile.sdk /home/coj/test -t cross-toolchain-arm64-test --build-arg IMAGE_ARCH=arm64 --build-arg GPU=-vivante --build-arg APP_ROOT=/home/torizon/app

Notice the difference? You have the GPU set to -imx8 while I have it set to -vivante. By default it should be set to -vivante if you’re using an imx8* device like in my setup. You can change this via torizon_gpu in settings.json file.

Furthermore, in your logs I can see for the base container of the SDK build you’re using torizon/qt6-wayland-imx8:next. This is partially because of the GPU variable as I said before, but even your tag (next) is wrong here. By default in the Dockerfile.sdk file the ARG BASE_VERSION should be set to 3.2.0.

Basically your issue was caused by using a different/wrong base container than normal. In summary to resolve this this:

  • Change torizon_gpu in settings.json to -vivante.
  • Change ARG BASE_VERSION in Dockerfile.sdk to 3.2.0

Finally, do you know why these variables were not using the default values? Did you change these or something?

Best Regards,
Jeremias

Hi Jeremias,

Ok, I will try your solutions and let you know.

I didn’t change any variables, when I installed the Toradex extension to VS code, I left everything as default, .

Thanks a lot for your support.

Best regards,
Tarek

I didn’t change any variables, when I installed the Toradex extension to VS code, I left everything as default, .

If that is the case, you might have old outdated versions of the templates. If that is true you’ll want to update your templates so that your projects are generated with the latest correct default values.

Best Regards,
Jeremias

Hi Jeremais,

I replaced the gpu to -vivante in settings.json, and I changed the G BASE_VERSION in DockerFile.sdk to 3.2.0, now the run and debug stops with error message:

=> ERROR [van_sys_container-debug internal] load metadata for docker.io/torizon/qt6-wayland-vivante:next

For updating the project templates, I couldn’t find out how to do that, so I switched the Toradex Extension to pre-release version: Pre Release Version (v2.5.176), but those two settings stays: “-imx8” and “next” no difference.

I uploaded the complete log file from VS code, and the “settings.json” and “Dockerfile.sdk” files for a newly created Qt/Qml project.
This is the upload link:
https://share.toradex.com/wx483tnj5ulc7b7

Best regards,
Tarek

I replaced the gpu to -vivante in settings.json, and I changed the G BASE_VERSION in DockerFile.sdk to 3.2.0, now the run and debug stops with error message:

You need to change this in the Dockerfile.debug file which is used for the debug process.

For updating the project templates, I couldn’t find out how to do that, so I switched the Toradex Extension to pre-release version: Pre Release Version (v2.5.176), but those two settings stays: “-imx8” and “next” no difference.

For a current project you may need to do the following: Update Project from Template | Toradex Developer Center

Alternatively you can try to manually update (or delete) the templates cache in your /home/<username>/.apollox directory. Though you would need to create a new project as this won’t dynamically update your pre-existing projects.

Best Regards,
Jeremias

Hi Jeremias,

The value -imx8 for torizon_gpu was set when I select my Apalis device as the default device,
even after I updated all of my templates.

So I figured there was something wrong with the installation, so I deleted all the extensions, and the wsl and the linux image in it, and I started again with the installation step by step.

After that all the problems were solved and the default values ​​became as required, and I was able to implement my first program and run it on the board.

Thanks a lot for your support

Best Regards,
Tarek

Glad I was able to help.