I am trying to port an application that uses various libs, like libjpeg, libpng, libcurl, etc to Jetson.
Using Jetpack 6, toolchain aarch64–glibc–stable-2022.08-1
Compiling the app with cmake works, but handling of the arm libraries is still unclear:
There is a number of static (.a) and shared (.so) libs already in the root filesys of the SDK.
Interestingly libjpeg seems to be missing and some others we need are also not there.
General question:
What is the recommended way to add additional libs to the root file system?
compiling from source?
installing at an actual Jetson unit and then copying the lib to the SDK at host?
Specific question about jpeglib:
I would have expected to find a Jetson-optimized one in the root-FS, but not.
the Argus lib provides Jpeg functionality, is this implemented separately of jpeglib?
what is the recommended way for a first, quick port to Jetson: add the standard jpeglib or
perhaps use the Argus lib from the beginning?
I can’t answer anything specific to libjpeg, I have no knowledge of that.
Are you speaking of cross compile from a PC for the Jetson? Or native compile on the Jetson? If you are natively compiling on the Jetson, then check out commands for checking a repository for the library. For example: apt search libjpeg
Then you might do something like “sudo apt-get install libjpeg8”. The -dev version of those also exist if you want development headers, but you might need to add a repository to apt for them to show up.
If you are cross compiling, then I recommend fully setting up the Jetson for building natively with the -dev packages, cloning the Jetson, discarding the “sparse” clone, and then using the “raw” clone loopback mounted on the host PC as the “sysroot” of the cross compile.