Make: *** [sapi/cli/php] Error 1

  
                  

Today, when configuring a new server to install php-5.5.19, there is a make: *** [sapi/cli/php] error 1 problem. I looked at the reason because the configure environment variable is not set. The reason, here is make: *** [sapi/cli/php] The solution to error 1 is written down and may be used later.

Solution:

Step 1: Execute "ld Makefile" in the terminal.

Step 2: Find about 106 lines of code EXTRA_LIBS. The following is the complete default code of the author here.

EXTRA_LIBS = -lcrypt -lz -lcrypt -lrt -lmysqlclient -lmcrypt -lltdl -lpng -lz -ljpeg -lcurl -lz -lrt -lm -ldl -lnsl -lrt -lxml2 -lz -lm -lssl -lcrypto -ldl -lz -lcurl -lxml2 -lz -lm -lssl -lcrypto -ldl -lz -lfreetype -lmysqlclient -lz -lm -lrt -ldl -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt

Step 3: Add “ -liconv” at the end, add the following as shown below.

EXTRA_LIBS = -lcrypt -lz -lcrypt -lrt -lmysqlclient -lmcrypt -lltdl -lpng -lz -ljpeg -lcurl -lz -lrt -lm -ldl -lnsl -lrt -lxml2 -lz -lm -lssl -lcrypto -ldl -lz -lcurl -lxml2 -lz -lm -lssl -lcrypto -ldl -lz -lfreetype -lmysqlclient -lz -lm -lrt -ldl -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt -liconv

Note: If you can't find it, you can go directly to sftp and directly make the makefile Download the file, full-text search "EXTRA_LIBS", you can, because different php versions, may be in different lines.

Copyright © Windows knowledge All Rights Reserved