cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Observer
Observer
8,305 Views
Registered: ‎03-01-2016

Failed to load shared libraries

Jump to solution

I am having trouble creating custom applications for my zynq chip running petalinux.  First of all, I am not using the petalinux tools, as I have a complicated device tree.  

 

I am able to compile my application on my host machine, then when I move it over to my board to be run, I get the following error:

 

error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory

 

What am I missing?  How do I get libstdc++ to my ramdisk?

 

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Explorer
Explorer
14,791 Views
Registered: ‎11-22-2015

Re: Failed to load shared libraries

Jump to solution

Go to where your toolchain is installed, in my case its

 

/opt/Xilinx/SDK/2015.4/gnu/arm/lin

 

then run the following

 

find . -name libstdc*

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so.6

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so.6.0.20

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.a

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so

 

I copied the shared library and created the links(some of those are links) into my ramdisk directory and then repack my ramdisk

 

Also, I build everything with a script that I wrote so if you use petalinux I can't tell you how to fix that but this info should point you in the right direction.

 

jeff

 

 

View solution in original post

0 Kudos
4 Replies
Highlighted
Explorer
Explorer
8,294 Views
Registered: ‎11-22-2015

Re: Failed to load shared libraries

Jump to solution

Not sure what release you are using but libstdc++ was not in the prebuilt ramdisk for 2015.4.  I just pulled it in from the toolchain install and then repacked the ramdisk.  Of if you are just trying to test something, you can just scp it onto the system.

 

jeff.

 

 

0 Kudos
Observer
Observer
8,139 Views
Registered: ‎03-01-2016

Re: Failed to load shared libraries

Jump to solution

Thanks for the info.  I am a bit of a novice, can you explain what you mean by pulled it in from the toolchain?

0 Kudos
Highlighted
Explorer
Explorer
14,792 Views
Registered: ‎11-22-2015

Re: Failed to load shared libraries

Jump to solution

Go to where your toolchain is installed, in my case its

 

/opt/Xilinx/SDK/2015.4/gnu/arm/lin

 

then run the following

 

find . -name libstdc*

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so.6

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so.6.0.20

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.a

./arm-xilinx-linux-gnueabi/libc/usr/lib/libstdc++.so

 

I copied the shared library and created the links(some of those are links) into my ramdisk directory and then repack my ramdisk

 

Also, I build everything with a script that I wrote so if you use petalinux I can't tell you how to fix that but this info should point you in the right direction.

 

jeff

 

 

View solution in original post

0 Kudos
Highlighted
Observer
Observer
7,927 Views
Registered: ‎03-01-2016

Re: Failed to load shared libraries

Jump to solution

Thanks for the help. This worked!

 

-Matt

0 Kudos