2

I try to (re)install libpng++-dev, but i got this error message:

 [...]
 The following packages have unmet dependencies:
 libpng++-dev : Depends: libpng-dev
 E: Unable to correct problems, you have held broken packages.

I tried to handle it like Can't solve unmet dependencies

But i couldn't solve the problem. Has anyone an idea?

Edit: The output from sudo apt-cache search libpng*:

libpng12-0 - PNG library - runtime
libpng12-dev - PNG library - development
fp-units-gfx - Free Pascal - graphics-library units dependency package
fp-units-gfx-3.0.0 - Free Pascal - graphics-library units
libpnetcdf-dev - Development files for the parallel netCDF library
libpnetcdf0d - Libraryfor reading and writing parallel NetCDF files
libpng++-dev - C++ interface to the PNG (Portable Network Graphics) library
libpng-sixlegs-java - Sixlegs Java PNG Decoder
libpng-sixlegs-java-doc - Documentation for Sixlegs Java PNG Decoder
libpng16-16 - PNG library - runtime (version 1.6)
libpng16-dev - PNG library - development (version 1.6)
libpng16-devtools - PNG library - tools (version 1.6)
libpng16-tools - PNG library - tools (version 1.6)
libpng3 - PNG library - runtime
libpnglite-dev - lightweight C library for loading and writing PNG images
pngquant - PNG (Portable Network Graphics) image optimising utility
ruby-oily-png - native mixin to speed up ChunkyPNG
tkpng - PNG photo image support to Tcl/Tk

Edit2:

Sorry, but now i got another error message (after compiling a c++ programm):

/usr/include/png++/reader.hpp:110: error: undefined reference to 'png_set_longjmp_fn'

Google said i should link against the right version from libpng but how can i do this?

D_H
  • 23

1 Answers1

1

Run:

sudo apt-cache search libpng*

sample output:

libpng12-0 - PNG library - runtime
libpng12-dev - PNG library - development
fp-units-gfx - Free Pascal - graphics-library units dependency package
fp-units-gfx-3.0.0 - Free Pascal - graphics-library units
libpnetcdf-dev - Development files for the parallel netCDF library
libpnetcdf0d - Libraryfor reading and writing parallel NetCDF files
libpng++-dev - C++ interface to the PNG (Portable Network Graphics) library
libpng-sixlegs-java - Sixlegs Java PNG Decoder
libpng-sixlegs-java-doc - Documentation for Sixlegs Java PNG Decoder
libpng16-16 - PNG library - runtime (version 1.6)
libpng16-dev - PNG library - development (version 1.6)
libpng16-devtools - PNG library - tools (version 1.6)
libpng16-tools - PNG library - tools (version 1.6)
libpng3 - PNG library - runtime
libpnglite-dev - lightweight C library for loading and writing PNG images
pngquant - PNG (Portable Network Graphics) image optimising utility
ruby-oily-png - native mixin to speed up ChunkyPNG
tkpng - PNG photo image support to Tcl/Tk

Then run:

sudo apt install libpng12-dev
sudo apt install libpng++-dev

Edit

The latest libpng can be download from here : libpng-1.6.26.tar.xz , install it as follows:

tar xvf libpng-1.6.26.tar.xz
cd libpng-1.6.26
./configure 
make check
make install

You can run ./configure --prefix=/path , path = the path to the directory where you want to install the binary

GAD3R
  • 3,507