Próbuję skompilować php 5.0.4 tak, aby obsługiwało MySQL i MySQLi.
MySQL 4.0.25 znajduje się w /usr/.
MySQL 4.1.13 jest w /usr/local/mysql41/.
Ponieważ mają działać równocześnie, MySQL 4.1 dostał port 3307 i inny socket, wprowadziłem te zmiany w /usr/local/mysql41/bin/mysql_config.
Konfiguracja poleceniem
Kod
./configure --with-apache=../apache_1.3.33 --with-libxml-dir=/usr/local/lib --with-gd --with-gettext --enable-sockets --with-jpeg-dir=/usr/local/lib --with-png-dir=/usr/local/lib --with-zlib-dir=/usr/local/lib --enable-gd-native-ttf --with-freetype-dir=/usr/local/lib --with-xmlrpc --with-dom --enable-xslt --with-expat-dir=/usr/local/lib --with-xsl --with-mysql=/usr/ --with-mysqli=/usr/local/mysql41/bin/mysql_config
przebiegła pomyślnie.Jednak podczas kompilacji wyskakuje cała masa problemów. Wszystkie są bliźniaczo podobne, więc wkleję tylko końcówkę:
Cytat
ext/mysqli/mysqli_nonapi.o(.text+0x4a7): In function `zif_mysqli_multi_query':
/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:236: undefined reference to `mysql_sqlstate'
ext/mysqli/mysqli_nonapi.o(.text+0x521):/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:249: undefined reference to `mysql_set_server_option'
ext/mysqli/mysqli_nonapi.o(.text+0x578):/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:248: undefined reference to `mysql_set_server_option'
ext/mysqli/mysqli_nonapi.o(.text+0x7ca): In function `zif_mysqli_query':
/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:289: undefined reference to `mysql_set_server_option'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:236: undefined reference to `mysql_sqlstate'
ext/mysqli/mysqli_nonapi.o(.text+0x521):/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:249: undefined reference to `mysql_set_server_option'
ext/mysqli/mysqli_nonapi.o(.text+0x578):/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:248: undefined reference to `mysql_set_server_option'
ext/mysqli/mysqli_nonapi.o(.text+0x7ca): In function `zif_mysqli_query':
/home/termit/php-5.0.4/ext/mysqli/mysqli_nonapi.c:289: undefined reference to `mysql_set_server_option'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
Nie mam kompletnie pomysłu co tu jest nie tak...