LAMP Strategy re-compile PHP installation extension and GD library installation and configuration (1)

Source: Internet
Author: User

 

Figure-LAMP

LAMPLowerPHPThe installation is very troublesome.GD library. This is one of our most common modules. Installing the GD library in Linux is much more troublesome than windows. This configuration is in

CentOS-5.3 under

Php-5.2.9

. Source code used for installation:

Gd-2.0.35

Freetype-2.2.1

Libpng-1.2.12

Using SRC. v6b

You can directly click to download.

If you choose to install X software during linux installation. It is very likely that these libraries have been installed on your system. For how to check whether the installation and uninstallation are complete, refer to the previous LAMP Introduction: Build a LAMP environment, install and configure Apache, MySQL, and PHP in Linux.

This configuration also applies to the configuration in red hat as 5 or fedora.

I have downloaded the required source code package to/usr/local/src.

Cd/usr/local/src

Go to the source code package directory and use ls to list the source code packages,

Ls | grep-E 'jpeg | png | gd | free'

Install freetype first.

Extract

Tar-zxvf freetype-2.2.1.tar.gz

Enter the decompressed directory

Cd freetype-2.2.1

Install to/usr/local/freetype

./Configure -- prefix =/usr/local/freetype

Compile and install

Make & make install

Install png after installation

Run

Cd ../

Return to the source package directory

Extract

Tar-zxvf libpng-1.2.12.tar.gz

Run

Cd libpng-1.2.12

Enter the extract directory

Configure, compile, and install

./Configure & make install


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.