./configure--prefix=/usr/local/php52
Make when prompted:
.....................................................
EXT/ICONV/.LIBS/ICONV.O (. text+0x1738): In function ' Zif_iconv_mime_encode ':
/usr/src/php-5.2.0/ext/iconv/iconv.c:1017:undefined reference to ' Libiconv_open '
EXT/ICONV/.LIBS/ICONV.O (. text+0x1756):/usr/src/php-5.2.0/ext/iconv/iconv.c:1031:undefined reference to ' LIBICONV_ Open
EXT/ICONV/.LIBS/ICONV.O (. text+0x1993):/usr/src/php-5.2.0/ext/iconv/iconv.c:1290:undefined reference to ' LIBICONV_ Close
EXT/ICONV/.LIBS/ICONV.O (. text+0x19ad):/usr/src/php-5.2.0/ext/iconv/iconv.c:1293:undefined reference to ' LIBICONV_ Close
EXT/ICONV/.LIBS/ICONV.O (. text+0x1b01):/usr/src/php-5.2.0/ext/iconv/iconv.c:1102:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x1b33):/usr/src/php-5.2.0/ext/iconv/iconv.c:1134:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x1b5e):/usr/src/php-5.2.0/ext/iconv/iconv.c:1150:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. Text+0x1e10):/usr/src/php-5.2.0/ext/iconv/iconv.c:1202:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x1e3c):/usr/src/php-5.2.0/ext/iconv/iconv.c:1233:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x207f):/usr/src/php-5.2.0/ext/iconv/iconv.c:1277:more undefined references to ' Libiconv ' follow
EXT/ICONV/.LIBS/ICONV.O (. text+0x2c08): In function ' Php_iconv_stream_filter_dtor ':
/usr/src/php-5.2.0/ext/iconv/iconv.c:2393:undefined reference to ' Libiconv_close '
EXT/ICONV/.LIBS/ICONV.O (. text+0x2cf2): In function ' Php_iconv_stream_filter_append_bucket ':
/usr/src/php-5.2.0/ext/iconv/iconv.c:2543:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x2d34):/usr/src/php-5.2.0/ext/iconv/iconv.c:2543:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. Text+0x2de7):/usr/src/php-5.2.0/ext/iconv/iconv.c:2465:undefined reference to ' Libiconv '
EXT/ICONV/.LIBS/ICONV.O (. text+0x30e2): In function ' php_iconv_stream_filter_factory_create ':
/usr/src/php-5.2.0/ext/iconv/iconv.c:2419:undefined reference to ' Libiconv_open '
Collect2:ld returned 1 exit status
Make: * * * [sapi/cli/php] Error 1
Workaround:
#wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.13.1.tar.gz#tar -zxvf libiconv-1.13. 1. Tar . GZ#CD Libiconv-1.13. 1 # . /configure--prefix=/usr/local/make doinstall
Method One: The method for removing the Iconv module can also compile PHP normally, as follows:
Edit Makefile about 77 rows of places:
Extra_libs = ...-lcrypt
In the end, add-liconv, for example:
Extra_libs =-lcrypt -liconv
Check PHP again to specify the location of Iconv --with-iconv=/usr/local/libiconv#. /configure--prefix=/usr/local/php52--with-iconv=/usr/local/libiconv#make# Install
Run make again.
One last method:
#make zend_extra_libs= '-liconv '
#make Install
PHP cannot compile undefined reference to ' Libiconv_open