This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM5728: SDK build error

Part Number: AM5728

I am building SDK using yocto for AM572X Evaluation module. I have referred http://processors.wiki.ti.com/index.php/Processor_SDK_Building_The_SDK and followed steps under "Build Steps" section.

The build was failed with the following error.


libtool: link:  arm-linux-gnueabihf-gcc  -march=armv7-a -marm -mfpu=neon  -mfloat-abi=hard --sysroot=/home/user/tisdk/oe-layersetup/build/arago-tmp-external-linaro-toolchain/sysroots/am57xx-evm -shared  zbar/.libs/zbar_libzbar_la-config.o zbar/.libs/zbar_libzbar_la-error.o zbar/.libs/zbar_libzbar_la-symbol.o zbar/.libs/zbar_libzbar_la-image.o zbar/.libs/zbar_libzbar_la-convert.o zbar/.libs/zbar_libzbar_la-processor.o zbar/processor/.libs/zbar_libzbar_la-lock.o zbar/.libs/zbar_libzbar_la-refcnt.o zbar/.libs/zbar_libzbar_la-window.o zbar/.libs/zbar_libzbar_la-video.o zbar/.libs/zbar_libzbar_la-img_scanner.o zbar/.libs/zbar_libzbar_la-scanner.o zbar/.libs/zbar_libzbar_la-decoder.o zbar/decoder/.libs/zbar_libzbar_la-ean.o zbar/decoder/.libs/zbar_libzbar_la-code128.o zbar/decoder/.libs/zbar_libzbar_la-code39.o zbar/decoder/.libs/zbar_libzbar_la-i25.o zbar/decoder/.libs/zbar_libzbar_la-qr_finder.o zbar/qrcode/.libs/zbar_libzbar_la-qrdec.o zbar/qrcode/.libs/zbar_libzbar_la-qrdectxt.o zbar/qrcode/.libs/zbar_libzbar_la-rs.o zbar/qrcode/.libs/zbar_libzbar_la-isaac.o zbar/qrcode/.libs/zbar_libzbar_la-bch15_5.o zbar/qrcode/.libs/zbar_libzbar_la-binarize.o zbar/qrcode/.libs/zbar_libzbar_la-util.o zbar/processor/.libs/zbar_libzbar_la-posix.o zbar/video/.libs/zbar_libzbar_la-null.o zbar/.libs/zbar_libzbar_la-jpeg.o zbar/processor/.libs/zbar_libzbar_la-null.o zbar/window/.libs/zbar_libzbar_la-null.o   -L/media/ToolChain/gcc-linaro-5.3-2016.02-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/lib /usr/lib/libjpeg.so -lpthread  -march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -Wl,-rpath-link -Wl,/media/ToolChain/gcc-linaro-5.3-2016.02-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/lib -Wl,-O1 -Wl,--hash-style=gnu   -Wl,-soname -Wl,libzbar.so.0 -Wl,-version-script -Wl,zbar/.libs/libzbar.ver -o zbar/.libs/libzbar.so.0.2.0
/usr/lib/libjpeg.so: file not recognized: File format not recognized
collect2: error: ld returned 1 exit status
Makefile:1141: recipe for target 'zbar/libzbar.la' failed




From the log the error is related to "libjpeg.so", but the jpeg library for 32-bit and 64-bit is available. My host PC is running with 64-bit Ubuntu 16.04.


user:/usr/lib$ ls -l /usr/lib/libjpeg.so
lrwxrwxrwx 1 root root 36 Apr  4  2016 /usr/lib/libjpeg.so -> /usr/lib/x86_64-linux-gnu/libjpeg.so
user:/usr/lib$ ls -l /usr/lib/x86_64-linux-gnu/libjpeg.so
lrwxrwxrwx 1 root root 17 Aug 18  2015 /usr/lib/x86_64-linux-gnu/libjpeg.so -> libjpeg.so.62.0.0
user:/usr/lib$ ls -l /usr/lib/i386-linux-gnu/libjpeg.so*
lrwxrwxrwx 1 root root     17 Aug 18  2015 /usr/lib/i386-linux-gnu/libjpeg.so.62 -> libjpeg.so.62.0.0
-rw-r--r-- 1 root root 149188 Aug 18  2015 /usr/lib/i386-linux-gnu/libjpeg.so.62.0.0
lrwxrwxrwx 1 root root     16 Feb 22  2016 /usr/lib/i386-linux-gnu/libjpeg.so.8 -> libjpeg.so.8.0.2
-rw-r--r-- 1 root root 382732 Feb 22  2016 /usr/lib/i386-linux-gnu/libjpeg.so.8.0.2
user:/usr/lib$




I have removed zbar package at "EXTRA_PACKAGES_append = " zbar hidapi"" in "packagegroup-arago-tisdk-addons.bbappend" file now it is giving error for hidapi package as shown below.


NOTE: Resolving any missing task queue dependencies
ERROR: Nothing RPROVIDES 'voxelsdkhidapi' (but /home/user/tisdk/oe-layersetup/sources/meta-arago/meta-arago-distro/recipes-core/packagegroups/packagegroup-arago-tisdk-addons.bb RDEPENDS on or otherwise requires it)
NOTE: Runtime target 'voxelsdkhidapi' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['voxelsdkhidapi']
NOTE: Runtime target 'packagegroup-arago-tisdk-addons' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['packagegroup-arago-tisdk-addons', 'voxelsdkhidapi']
ERROR: Required build target 'arago-core-tisdk-image' has no buildable providers.
Missing or unbuildable dependency chain was: ['arago-core-tisdk-image', 'tisdk-rootfs-image', 'packagegroup-arago-tisdk-addons', 'voxelsdkhidapi']




After removing "hidapi" package name from "EXTRA_PACKAGES_append" in packagegroup-arago-tisdk-addons.bbappend file build completed successfully.

Can you guide me how can I build those packages.

  • The software team have been notified. They will respond here.
  • Hello Ravi,

    You can build those packages by adding EXTRA_OECONF = "--with-jpeg8 " line to <tisdk>/sources/oe-core/meta/recipes-graphics/jpeg/libjpeg-turbo_8d+1.4.2.bb recipe file.

    Best regards,
    Kemal

  • Hi Kemal,

    Thanks for the reply. I tried by adding EXTRA_OECONF for jpeg, but still it is giving same error. Do I need to add EXTRA_OECONF after a specific line or anywhere in the recipe file is fine.

    I could see few ipk files for jpeg are created after adding EXTRA_OECONF.


    ./deploy/ipk/armv7ahf-neon/libjpeg-doc_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/jpeg-tools_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/libjpeg-dbg_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/libjpeg8_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/libjpeg-dev_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/libturbojpeg0_8d+1.4.2-r0_armv7ahf-neon.ipk
    ./deploy/ipk/armv7ahf-neon/libjpeg-staticdev_8d+1.4.2-r0_armv7ahf-neon.ipk



    Following is the same error after adding EXTRA_OECONF = "--with-jpeg8".


    | libtool: link:  arm-linux-gnueabihf-gcc  -march=armv7-a -marm -mfpu=neon  -mfloat-abi=hard --sysroot=/home/user/tisdk/oe-layersetup/build/arago-tmp-external-linaro-toolchain/sysroots/am57xx-evm -shared  zbar/.libs/zbar_libzbar_la-config.o zbar/.libs/zbar_libzbar_la-error.o zbar/.libs/zbar_libzbar_la-symbol.o zbar/.libs/zbar_libzbar_la-image.o zbar/.libs/zbar_libzbar_la-convert.o zbar/.libs/zbar_libzbar_la-processor.o zbar/processor/.libs/zbar_libzbar_la-lock.o zbar/.libs/zbar_libzbar_la-refcnt.o zbar/.libs/zbar_libzbar_la-window.o zbar/.libs/zbar_libzbar_la-video.o zbar/.libs/zbar_libzbar_la-img_scanner.o zbar/.libs/zbar_libzbar_la-scanner.o zbar/.libs/zbar_libzbar_la-decoder.o zbar/decoder/.libs/zbar_libzbar_la-ean.o zbar/decoder/.libs/zbar_libzbar_la-code128.o zbar/decoder/.libs/zbar_libzbar_la-code39.o zbar/decoder/.libs/zbar_libzbar_la-i25.o zbar/decoder/.libs/zbar_libzbar_la-qr_finder.o zbar/qrcode/.libs/zbar_libzbar_la-qrdec.o zbar/qrcode/.libs/zbar_libzbar_la-qrdectxt.o zbar/qrcode/.libs/zbar_libzbar_la-rs.o zbar/qrcode/.libs/zbar_libzbar_la-isaac.o zbar/qrcode/.libs/zbar_libzbar_la-bch15_5.o zbar/qrcode/.libs/zbar_libzbar_la-binarize.o zbar/qrcode/.libs/zbar_libzbar_la-util.o zbar/processor/.libs/zbar_libzbar_la-posix.o zbar/video/.libs/zbar_libzbar_la-null.o zbar/.libs/zbar_libzbar_la-jpeg.o zbar/processor/.libs/zbar_libzbar_la-null.o zbar/window/.libs/zbar_libzbar_la-null.o   -L/media/ToolChain/gcc-linaro-5.3-2016.02-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/lib /usr/lib/libjpeg.so -lpthread  -march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -Wl,-rpath-link -Wl,/media/ToolChain/gcc-linaro-5.3-2016.02-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/lib -Wl,-O1 -Wl,--hash-style=gnu   -Wl,-soname -Wl,libzbar.so.0 -Wl,-version-script -Wl,zbar/.libs/libzbar.ver -o zbar/.libs/libzbar.so.0.2.0
    | /usr/lib/libjpeg.so: file not recognized: File format not recognized
    | collect2: error: ld returned 1 exit status
    | Makefile:1141: recipe for target 'zbar/libzbar.la' failed
    | make[1]: *** [zbar/libzbar.la] Error 1


  • The error "/usr/lib/libjpeg.so: file not recognized: File format not recognized" indicates that the zbar expects an arm cross-compiled lib. In general the Ubuntu doesn't have a libjpeg.so library at this path /usr/lib/libjpeg.so which in your case confuses the libtool and causes the build to fail. So if you delete the sudo rm -rf /usr/lib/libjpeg.so the build should not fail.

  • Thanks. After removing the /usr/lib/libjpeg.so zbar package built successfully.
  • I have built SDK in "64-bit Ubuntu 14.04.2" and didn't observe any error while building zbar package, because "/usr/lib/libjpeg.so" is not present in Ubuntu 14.04.2. The failure for zbar package was observed only in 64-bit Ubuntu 16.04 due to /usr/lib/libjpeg.so .