I am trying to build and run a 32bit application on the Tx2.
The libraries I need to use are complied for 32bit for Tx1. I was able to use arm-linux-gnueabihf-gcc and arm-linux-gnueabihf-g++ to successful compile the source code and link to the the 32bit libraries but I still am unable to run the built binary. All of this has been done on the Tx2 device, not on an external host.
I followed the suggestions in this thread to get to where I am now. https://devtalk.nvidia.com/default/topic/960942/jetson-tx1/l4t-24-2-does-not-support-32-bit-user-space-program-/
Is what im attempting even possible; build and link 32bit libraries to produce 32bit binary and run it on the tx2?
Is there something I can enable and rebuild the kernel that will allow 32bit applications to run?
Here is the library
nvidia@tegra-ubuntu:~/DUOSDK/SDK/linux/arm$ file libDUO.so
libDUO.so: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, BuildID[sha1]=efb9534c40dad70bffd8e0e0a8b7b3cf276ee3aa, stripped
This is the final complied binary:
nvidia@tegra-ubuntu:~/DUOSDK/Samples/C++/bin/arm$ file Sample-01-Motion
Sample-01-Motion: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, BuildID[sha1]=056d82c7d43dede5a0ec257ce39bc0acef932d7d, not stripped
These are some other configuration on the Tx2
sudo apt-get install g++-4.8-arm-linux-gnueabihf gcc-4.8-arm-linux-gnueabihf`
export CC=/usr/bin/arm-linux-gnueabihf-gcc`
export CXX=/usr/bin/arm-linux-gnueabihf-g++`
ADD to CMakeLists.txt
#Set the RPATH to be used when installing
SET(CMAKE_INSTALL_RPATH "/usr/arm-linux-gnueabihf/")
and create arm-linux-gnueabi.conf
inside /etc/ld.so.conf.d
#/etc/ld.so.conf.d/arm-linux-gnueabihf.conf
# Multiarch support
/usr/arm-linux-gnueabihf
/lib/arm-linux-gnueabihf
/usr/lib/arm-linux-gnueabihf
When i try and run the binary i get.
nvidia@tegra-ubuntu:~/DUOSDK/Samples/C++/bin/arm$ ls
Sample-01-Motion Sample-03-Parameters Sample-05-Polling
Sample-02-Images Sample-04-Sequences
nvidia@tegra-ubuntu:~/DUOSDK/Samples/C++/bin/arm$ ./Sample-01-Motion
-bash: ./Sample-01-Motion: No such file or directory