Qt cross compile for jetson orin nx

Hi i have jetson orin nx devkit i wanna cross compile qt in my laptop for jetson devkit to develop a program that use cuda and tensorRT would you please help me step by step ?

I can’t give you step-by-step information (and I’ve not compiled anything QT in over a decade). I will tell you something perhaps useful about the environment though.

When cross compiling a kernel it is simple because you only need the cross tools (it is bare metal). As soon as you get to user space (with libraries and linking) it gets more difficult. You then need a cross linker and you also need all of the development headers and the libraries you will link against. The cross tools are usually simple, but getting a cross arch set of headers and the cross linker and expecially the libraries, you must suddenly do much more manual install piece by piece. However, there is a shortcut.

On the host you would do your normal procedure for installing cross tools, and the cross linker. On the Jetson itself you can set up for development. You would add all development headers and all libraries. Then clone the rootfs (which gives you both a sparse and raw clone; delete the sparse clone, keep the raw clone), and loopback mount that on your host PC. This mount point becomes the sysroot. No more need to install individual headers and libraries one at a time…anything your Jetson could compile can now be cross compiled if you use that sysroot and you have the cross compiler and cross linker.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.