Error message configure: error: ZLib not installed when installing libpng in Centos 6.2

Source: Internet
Author: User

Centos 6.2 installation libpng error message configure: error: ZLib not installed

When compiling libpng-1.5.8.tar.gz, an error is reported. configure: error: ZLib not installed. I used the following package for compilation.

Zlib-1.2.6.tar.gz libpng-1.5.8.tar.gz

Solution:

1. Enter the source file directory of the zlib-1.2.6, execute the command make clean, clear zlib;

2. reconfigure./configure. Do not use the -- prefix parameter later;

3. Compile make & install make install;

4. Go to the libpng-1.5.8 directory and run the command./configure -- prefix =/usr/local/libpng;

5. Compile make & install make install;

6. The installation is successful;

Make [2]: Leaving directory '/tmp/libpng-1.5.8'
Test-z "/usr/local/libpng/share/man/man3" |/bin/mkdir-p "/usr/local/libpng/s hare/man/man3"
/Usr/bin/install-c-m 644 libpng.3 libpngpf.3 '/usr/local/libpng/share/man 3'
Test-z "/usr/local/libpng/share/man/man5" |/bin/mkdir-p "/usr/local/libpng/s hare/man/man5"
/Usr/bin/install-c-m 644 png.5 '/usr/local/libpng/share/man/man5'
Test-z "/usr/local/libpng/include/libpng15" |/bin/mkdir-p "/usr/local/libpng/include/libpng15"
/Usr/bin/install-c-m 644 pnglibconf. h '/usr/local/libpng/include/libpng15'
Test-z "/usr/local/libpng/lib/pkgconfig" |/bin/mkdir-p "/usr/local/libpng/li B/pkgconfig"
/Usr/bin/install-c-m 644 libpng15.pc '/usr/local/libpng/lib/pkgconfig'
Test-z "/usr/local/libpng/include/libpng15" |/bin/mkdir-p "/usr/local/libpng/include/libpng15"
/Usr/bin/install-c-m 644 png. h pngconf. H'/usr/local/libpng/include/libpng15'
Make install-data-hook
Make [2]: Entering directory '/tmp/libpng-1.5.8'
Cd/usr/local/libpng/include; rm-f png. h pngconf. h pnglibconf. h
Cd/usr/local/libpng/include; ln-s libpng15/png. h png. h
Cd/usr/local/libpng/include; ln-s libpng15/pngconf. h \
Pngconf. h
Cd/usr/local/libpng/include; ln-s libpng15/pnglibconf. h \
Pnglibconf. h
Cd/usr/local/libpng/lib/pkgconfig; rm-f libpng. pc
Cd/usr/local/libpng/lib/pkgconfig; ln-s libpng15.pc libpng. pc
Make [2]: Leaving directory '/tmp/libpng-1.5.8'
Make [1]: Leaving directory '/tmp/libpng-1.5.8'
[Root @ centos libpng-1.5.8] #

The directory has been created:

[Root @ centos tmp] # cd/usr/local/libpng/
[Root @ centos libpng] # ls
Bin include lib share
[Root @ centos libpng] #

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.