Use the source code package in Ubuntu to build a LAMP environment error note

Source: Internet
Author: User
Tags fully qualified domain name
1. compiling environment error: only the gcc compiling environment is pre-installed in Ubuntu10.04, but the source code package for installing this environment also requires the compiling environment of g ++ (c ++, g ++ must be installed, but the two versions must be synchronized. Otherwise, the installation may fail. A better solution is to use the following command: sudoapt-getinstallbuild-essential to install the complete compilation environment package (because it is possible to install gcc and g ++ separately

1. compilation environment error:

In Ubuntu 10.04, only the gcc compiling environment is pre-installed. However, to install the source code package of this environment, g ++ (c ++) compiling environment is required, and g ++ must be installed, however, the two versions must be synchronized. Otherwise, the installation may fail. A better solution is to use the following command:

SudoApt-getInstallBuild-essential

Install the software package for the entire compilation environment (because the separate installation of gcc and g ++ may cause the two versions not to be synchronized). After installation, the compilation environment is configured.

 

2. An error occurred while compiling libxml2:

The error message is as follows:




Solution:

OpenNanohttp.C, 1,588th rows from
Fd = open (filename, O_CREAT | O_WRONLY); Replace
Fd = open (filename, O_CREAT | O_WRONLY, 0777 );


I checked it online and said the error was caused by the gcc-4.3's strict syntax check.

3. zlib library decompression error:

If an error occurs when you decompress the zlib package using the tar command and confirm that the package is complete, use another graphical decompression software [or even winrar in windows] to decompress the package first, copy the decompressed folder and then compile and install it.

4. error: GNU M4 1.4 is required: 

This error occurs because the system does not install related software packages,Open the URL ftp.gnu.org/gnu/m4/download any part of the user's website. Use the following command to compile and install it:

(Sudo)./configure
(Sudo) make
(Sudo) make install

5. An error occurred while installing the gd library. Make [2]: *** [gd_png.lo] Error 1:

Error cause:

The png. h file cannot be found.

Solution:

Go to the decompressed directory of the gd library and edit the gd_png.c file. Find the following code:

# Include "png. g"

Modify it:

# Include "/usr/local/libpng/include/libpng12/png. h"


Note: The modified file directory is the directory of the corresponding file when you install the libpng library. You need to modify the directory according to your installation path.

6.Cocould not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName:


This isWarning appears when apache2 is started or restarted. This is mainly because the corresponding host name is not specified when apache2 is configured, that isServerName. Modify/etc/httpd. conf, Add at the beginningServerName localhost: 80You can. 

7. An error occurred while configuring mysql.Configure: error: No curses/termcap library found: 

It indicates that the curses/termcap library is not installed.

Apt-get install libncurses5-dev


8. An error occurred while configuring mysql auto-start:

Comment out the -- skip-federated in/etc/my. cnf.

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.