libpng15.so.15()(64bit) and libpng15.so.15(PNG15_0) is needed by

error:
Failed dependencies:

libpng15.so.15()(64bit) is needed by xxxxxxxx.el7.x86_64

libpng15.so.15(PNG15_0)(64bit) is needed by xxxxxxxxx.el7.x86_64

 

I got the above error while trying to install a package on centOS 7 server. Error shows few dependencies are needed by the package it is not installed on your Linux server. Do the below steps to fix the error.

1. Log into Linux server as ‘root’ user

2. Run the below command to check whether ‘libpng’ package is installed on the server

 

# rpm -qa | grep libpng

OR

# yum list installed | grep libpng

 

If the above command didn’t return any errors then it means ‘libpng’ package is not installed on your CentOS 7 server.

You can either install the ‘libpng’ package using ‘yum’ command or you can download and install the rpm package from centos 7 rpm repository

3. Execute the command ‘yum install libpng’ to install the package.

 

# yum install libpng

Resolving Dependencies
–> Running transaction check
—> Package libpng.x86_64 2:1.5.13-7.el7_2 will be installed
–> Finished Dependency Resolution

Total download size: 213 k
Installed size: 602 k
Is this ok [y/d/N]: y

Installing : 2:libpng-1.5.13-7.el7_2.x86_64 1/1
Verifying : 2:libpng-1.5.13-7.el7_2.x86_64 1/1

Installed:
libpng.x86_64 2:1.5.13-7.el7_2

 

libpng is the official Portable Network Graphics reference library. Type ‘y’ and hit enter if yum ask for confirmation before installing the package

4. You have installed the required dependency and now you can try installing the package.