Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

(RESOLVED) error while loading shared libraries: libpng12.so.0

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.

Georgie Porgie

New member
Hi!!
I am trying to set up WRF on Kubuntu WRF compiled successfully and it seemed like WPS build all the executables, since they appeared and are not zero-sized, but the compile log (attached) didn't end with a message about executables being successfully built. Geogrid runs successfully but when I try to run ungrib I get this error message:

./ungrib.exe: error while loading shared libraries: libpng12.so.0: cannot open shared object file: No such file or directory

View attachment lib.txt
 

Attachments

  • lib.txt
    1.2 KB · Views: 76
I think you may need to add the directory containing the 'libpng12.so.0' file to your LD_LIBRARY_PATH environment variable.
 
You'll need to set your LD_LIBRARY_PATH environment variable rather than your PATH environment variable.

Assuming that the file $DIR/grib2/lib/libpng12.so.0 exists, you could try:
Code:
export LD_LIBRARY_PATH=$DIR/grib2/lib:$LD_LIBRARY_PATH
 
Thanks for following up, and I'm glad to hear that setting your LD_LIBRARY_PATH variable worked!
 
Top