LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   libpng12.so.0: cannot open shared object file: No such file or directory (https://www.linuxquestions.org/questions/linux-newbie-8/libpng12-so-0-cannot-open-shared-object-file-no-such-file-or-directory-787618/)

MTK358 02-07-2010 01:24 PM

libpng12.so.0: cannot open shared object file: No such file or directory
 
Neither VirtualBox nor FVWM2 can start because of this error:

libpng12.so.0: cannot open shared object file: No such file or directory

What should I do?

MS3FGX 02-07-2010 02:06 PM

Is libpng installed? Otherwise, where did you get the packages for these programs? They might not have been the right ones for your system.

Tinkster 02-07-2010 02:07 PM

Look at however arch manages packages and find which version is
installed (if any) and which package holds it, or if it's part of
removed (currently not installed) packages, install it.


A good start is always
Code:

ls -ld $(locate -r libpng.*\.so.*)

John VV 02-07-2010 02:25 PM

Quote:

Neither VirtualBox nor FVWM2 can start because of this error:
How old are these two ?
What versions are they ?
libpng 12 is very old - VERY OLD

MTK358 02-07-2010 03:02 PM

Code:

$ sudo ls -ld $(locate -r libpng.*\.so.*)
Password:
lrwxrwxrwx 1 root root    18 Jan 27 20:48 /usr/lib/libpng14.so -> libpng14.so.14.0.0
lrwxrwxrwx 1 root root    18 Jan 27 20:48 /usr/lib/libpng14.so.14 -> libpng14.so.14.0.0
-rwxr-xr-x 1 root root 183348 Jan 27 20:48 /usr/lib/libpng14.so.14.0.0
lrwxrwxrwx 1 root root    11 Jan 27 20:48 /usr/lib/libpng.so -> libpng14.so
-rwxr-xr-x 1 root root  12464 Jan 30 21:28 /usr/lib/vlc/codec/libpng_plugin.so


MTK358 02-07-2010 03:02 PM

Quote:

Originally Posted by John VV (Post 3855931)
How old are these two ?
What versions are they ?
libpng 12 is very old - VERY OLD

The latest versions.

Tinkster 02-07-2010 03:09 PM

The presence of libpng14 makes me wonder where you dug up
VirtualBox or FVWM2 from ... are they packages that are
made for your distro?

If they're not, there's always the ugly kludge approach
of simply creating a symlink from libpng14.so to the 12 version
and hope the programming interface hasn't changed too much
between those versions.



Cheers,
Tink

MTK358 02-07-2010 03:24 PM

Quote:

Originally Posted by Tinkster (Post 3855965)
The presence of libpng14 makes me wonder where you dug up
VirtualBox or FVWM2 from ... are they packages that are
made for your distro?

If they're not, there's always the ugly kludge approach
of simply creating a symlink from libpng14.so to the 12 version
and hope the programming interface hasn't changed too much
between those versions.



Cheers,
Tink

They aren't because I prefer the unstable version of FVWM and I got VirtualBox from the VirtualBox website.

smeezekitty 02-07-2010 03:27 PM

Code:

ln -s /usr/lib/libpng.so /usr/lib/libpng12.so.0

MTK358 02-07-2010 04:10 PM

Still FVWM won't compile, it complains about something having to do with PNG. It did that before.

itsbrad212 02-15-2010 07:20 AM

I am also trying to run PlaneShift (a RPG) and it complains about not having libpng12. The latest version is very recent, so I don't have a clue why they are clinging to linpng12

(BTW, to confirm MTK358's error, I get "./pslaunch.bin: /usr/lib/libpng12.so.0: version `PNG12_0' not found (required by ./pslaunch.bin)")

MTK358 02-15-2010 07:43 AM

At least I don't have to worry about FVWM anymore because I found that the "unstable" version can be gotten from the repos as "fvwm-devel". The only reason I wanted to compile is because I thought that the repos didn't have this newer version.

And I uninstalled VirtualBox (I haven't even used it), but if I ever need it I will do it via AUR so pacman will know about it, instead of me having to remember where that binary installer is all the time, in case I want to upgrade or uninstall it.

Because of this, I deleted the libpng12 -> libpng14 link, too.

I wonder why does the program specify the version it wants. Shouldn't it not care about the version and use whatever is here?

Tinkster 02-15-2010 01:52 PM

Quote:

Originally Posted by MTK358 (Post 3864334)
I wonder why does the program specify the version it wants. Shouldn't it not care about the version and use whatever is here?

The potential pitfall with that is that the guys
making the libraries may change the interface they
use from version to version; and that may only surface
in one out of say 200 functions; now, your program
compiled against a different (I'm not saying older or
newer specifically because they regression from your
programs point of view may be either direction) library
may work 99% of the time but display funny behaviour
you can't assess easily .... so it's safer to make it
quite clear which version of the library the program
builds against and runs as expected.



Cheers,
Tink


All times are GMT -5. The time now is 11:55 AM.