Results 1 to 6 of 6
Enjoy an ad free experience by logging in. Not a member yet? Register.
My reoccurring libpng nightmare...
$ libpng warning: Application was compiled with png.h from libpng-1.4.5 libpng warning: Application is running with png.c from libpng-1.2.40 libpng error: Incompatible libpng version in application and library could not load texture packages/textures/notexture.png could not find core textures
$ ls -l /usr/lib/libpng*.so lrwxrwxrwx 1 root root 11 Jul 22 01:20 /usr/lib/libpng.so -> libpng14.so lrwxrwxrwx 1 root root 18 Oct 14 2010 /usr/lib/libpng12.so -> libpng12.so.0.40.0 lrwxrwxrwx 1 root root 18 Jul 22 01:20 /usr/lib/libpng14.so -> libpng14.so.14.8.0
# mv libpng12.so old_libpng12.so # ln -s libpng14.so.14.8.0 libpng12.so
Any help or suggestions appreciated.
- Join Date
- May 2011
Have you tried putting the older version of libpng in /usr/local/lib, then when you run the game, do "export LD_LIBRARY_PATH=/usr/local/lib" first?
Thanks atreyu. Your response set me on a course that eventually enabled me to find a solution that is satisfactory for my particular situation.
The problem I kept running into was not being able to find a way for libpng12 and libpng14 to live together harmoniously. Many Linux games, (Cube2, VVVVVV, SuperTux and others) need libpng14 whereas my mainstay apps (Firefox, IceWM and Slim) need libpng12. I tried putting each in various locations... separately in /lib, /usr/lib, /usr/local/lib and every app would always want to find libpng12 first no matter where it was. I eventually put libpng12 in its own directory in /usr/lib and symlinked the existing libpng14.so to libpng12.so.0 in /usr/lib. This made Slim and all the games happy but Firefox and IceWM still complained of needed libpng12. I fixed both by telling them where libpng12 was relocated. For firefox:
Seems I spoke too soon. The games that need libpng14 have found libpng12 in the special directory I created for it. I guess telling Firefox and IceWM where it is gets configured somewhere so every other app calling on libpng will find it there too. Why can't libpng14 be backward compatible to libpng 12 like other libs are. I shouldn't have to make a choice between Firefox and Cube2.
My nightmare continues...
The only thing I can figure is, somewhere along the way, I misconfigured something and it has been with me ever since. I've noticed Linux Mint doesn't seem to have libpng14, only libpng12! Yes, I did try symlinking libpng14 to libpng12 but that is backwards from how these things appear to work and no, it didn't solve the problem.
I've beat my head against the wall over this long enough. For the first time in years, I'm going to re-install CRUX due to my inability to troubleshoot an issue.
#!/bin/bash # This here's a very messy "Rube Goldberg" contraption to satisfy Cube2's need # for libpng14 on a system that has other applications requiring libpng12. cd /usr/lib && mv libpng12* hold && ln -s libpng14.so.14.8.0 libpng12.so.0 && LD_PRELOAD=/usr/lib/libpng12.so.0 cd /usr/local/games/sauerbraten/ ./sauerbraten_unix && rm /usr/lib/libpng12.so.0 && cd /usr/lib/hold && mv libpng12* ../