Portál AbcLinuxu, 16. července 2025 05:25
pokousim se na Ubuntu 6.10 zprovoznit webserver (Apache 2.2.4 a PHP 5.2.1). Configure probehne OK, ale pri make skoncim s hromadou nize uvedenych chyb:
...
...
/www/install/php-5.2.1/ext/iconv/iconv.c:1141: undefined reference to `libiconv'
/www/install/php-5.2.1/ext/iconv/iconv.c:1209: undefined reference to `libiconv'
/www/install/php-5.2.1/ext/iconv/iconv.c:1240: undefined reference to `libiconv'
ext/iconv/iconv.o:/www/install/php-5.2.1/ext/iconv/iconv.c:1284: more undefined references to `libiconv' follow
collect2: ld returned 1 exit status
make: *** [sapi/cgi/php] Error 1
---
Vzdy jsem postupoval podle tohoto "http://www.root.cz/clanky/kompilace-apache-php-a-mysql-na-linuxu-ze-zdroje/" a nemel jsem problem. A ted toto
PHP kompiluji s temito parametry:
EXTRA_LIBS
v Makefile
přidat "-liconv
". A libiconf
údajně není třeba (glibc by měla stačit).
ldconfig updates the shared libraries links, so new installed libraries are found by ld and the undefined reference should go away There is no other parameter, you run ldconfig and it updates links following /etc/ld.so.conf (In fact ldconfig has more option but none will be usefull here)
Tiskni
Sdílej:
ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.