building libpng-1.6.37 fails with call to zlib, but zlib is installed
The hardware environment I am working in is a QNAP NAS with x86_64 architecture.
The software is a headless, embedded, QNAP-designed Debian-based Gnu/Linux distro based on kernel 4.14.24. The key constraint in this environment is that there is no package manager, and the dependencies etc needed to build and install programs must be installed by hand using the Entware system. Basically, a parallel environment is created in /opt/Entware. I have installed Please accept that this is the environment I have to work in to get the functionality I need on my NAS. it's just a lot more painful than in other distros.I have installed most of the standard functionality of a standard linux distro, including core-utils, pkg-config, cmake, gawk, gcc, glib2,ldconfig, libacl, and more. My current issue is in building libpng-1.6.37, which is depended on by gdk-pixbuf-2.42.6. libpng depends on zlib, which installed first time without complaint. my libpng-1.6.37 build fails with Code:
Built target png_static what is the process to debug errors like this? Many thanks for your help. |
Hi until you get a better reply as I am on Debian
Quote:
Code:
strings /usr/lib/x86_64-linux-gnu/libz.so |grep inflateValidate 2) I had a quick test and can report Code:
tar xvf libpng-1.6.37.tar.gz See mention of zlib? I have broken the configured with line with line breaks to reduce side scrolling Code:
configure --help Code:
./configure --help | grep zlib 3) Do you see any /opt pathway in your pc files?.....they should have them but mine is built to /usr Code:
cat /usr/lib/x86_64-linux-gnu/pkgconfig/zlib.pc |
This is a pretty darn good answer!
First, the zlib library I installed is in opt/lib When I added the --with-zlib-prefix flag to the configure Code:
./configure --prefix=/opt --with-zlib-prefix=/opt/lib Code:
[~/gdk_files/libpng-1.6.37] # make check Code:
[~/gdk_files/libpng-1.6.37] # ldconfig -v | grep libz The first entry reported is in /lib : Code:
libz.so.1 -> libz.so.1.2.8 Code:
libz.so.1 -> libz.so.1.2.11 Is having links to two libraries of the same name in different locations a problem? And, if it is, how do I fix it? I don't know which is more recent. Should I uninstall the one I just installed? Fun and games... Many thanks. |
Solved!
I found this One poster had success by adding linker information to the configure: Code:
./configure --prefix=/usr LDFLAGS="-L/usr/lib -lz" Code:
./configure --prefix=/opt LDFLAGS="-L/opt/lib -lz" CPPFLAGS=/opt/include |
All times are GMT -5. The time now is 07:12 PM. |