Já alerto que tenho duvida, se o local que estou postando esta certo.
PHP version: php-5.2.8
MySQL version: MySQL-server-5.1.30-0.glibc23.i386
Glibc version: glibc-2.9-3.i686
Make version: make-3.81-14.fc10.i386
Bison version: bison-2.3-5.fc9.i386
Flex version: flex-2.5.35-2.fc10.i386
GD Version: gd-2.0.35-6.fc10.i386 / gd-devel-2.0.35-6.fc10.i386
(http://img10.imageshack.us/img10/7236/lsmysql.th.png) (http://img10.imageshack.us/img10/7236/lsmysql.png)
./configure \
--disable-cgi \
--enable-cli \
--prefix=/usr/local/php-gtk2 \
--with-mysql \
--with-mysqli=/usr/bin/mysql_config \
--with-pdo-mysql \
--with-libxml-dir=/usr/lib \
--with-pdo-sqlite \
--with-gd \
--with-zlib \
--enable-dbase \
--enable-soap \
--enable-calendar \
--enable-sockets \
--enable-ftp \
--with-jpeg-dir=/usr \
--with-png-dir=/usr \
--with-xpm-dir=/usr
(http://img503.imageshack.us/img503/5519/configure.th.png) (http://img503.imageshack.us/img503/5519/configure.png)
Nunca mechi com bibliotecas GD, o gd que conheçe é gateway default.
make
(http://img5.imageshack.us/img5/4356/make.th.png) (http://img5.imageshack.us/img5/4356/make.png)
não sei o que pode estar ocorrendo, mas o problema é que ele acusa erro na link do mysql, não consigo entender.
O erro está aqui.
/usr/lib/mysql/libmysqlclient.so
O mysql está instalado,mais a libmysqlclient,não está no diretório que o makefile procura,precisamos criar um link simbólico com esse nome apontado para o libmysqlclient.so.
verifique no /usr/lib/mysql/ por uma lib chamada libmysqlclient.so.1 se ouver ela fazer um link apontando com ela.
#ln -s /usr/lib/mysql/libmysqlclient.so.1 /usr/lib/mysql/libmysqlclient.so
Após isso experimente rodar o make novamente :)
[]'s
Obrigado pela ajuda!
Então hermano, não entendi cara, não seria mais fácil renomear? huhsuhs.
tipo o que vejo que faz com esse comando é renomear-lo, pois o make não ira procurar libmysqlclient.so e libmysqlclient.so.1 ou um ou outro não?
Então, não há o link libmysqlclient.so.1 not found!
saca só:
# ls /usr/lib/mysql/libmysqlclient.
libmysqlclient.a libmysqlclient.la libmysqlclient.so/
# ls /usr/lib/mysql/libmysqlclient.so.1
ls: impossível acessar /usr/lib/mysql/libmysqlclient.so.1: Arquivo ou diretório não encontrado
O libmysqlclient.so está apontando pro lugar certo:
# ls -la /usr/lib/mysql/libmysqlclient.so
lrwxrwxrwx 1 root root 20 Fev 20 21:43 /usr/lib/mysql/libmysqlclient.so -> /var/lib/mysql/mysql
Isso aqui é só pra dizer mesmo pois acho que esta faltando coisa no ./configure mas é isso aqui:
E agora está dando erro no ./configure
Estou rodando isso:
./configure --prefix=/usr --with-mysql --with-mysqli=/usr/bin/mysql_config --disable-cgi --enable-cli --with-gd --with-zlib --with-calendar --with-jpeg-dir=/usr --with-png-dir=/usr --with-xpm-dir=/usr && make && makeinstall
E está dando isso
checking for mysql_close in -lmysqlclient... no
checking for mysql_error in -lmysqlclient... no
configure: error: mysql configure failed.
Vou rodar o outro ./configure pra ver o qeu dá (o antigo)
by KEst
Post Merge: 24 de February , 2009, 08:13:26 PM
Rodei o ./configure anterior.
Acho que é no fim que tem os erros né, então eis o fim do config.log:
configure:59985: checking for mysql_close in -lmysqlclient
configure:60004: gcc -o conftest -I/usr/include -g -O2 -Wl,-rpath,/usr/lib/mysql -L/usr/lib/mysql -L/usr/lib conftest.c -lmysqlclient -lX11 -lXpm -lpng -lz -ljpeg -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
/usr/lib/mysql/libmysqlclient.so: file not recognized: Is a directory
collect2: ld returned 1 exit status
configure: failed program was:
#line 59993 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
char mysql_close();
int main() {
mysql_close()
; return 0; }
configure:60227: checking for mysql_error in -lmysqlclient
configure:60246: gcc -o conftest -I/usr/include -g -O2 -Wl,-rpath,/usr/lib/mysql -L/usr/lib/mysql -L/usr/lib -Wl,-rpath,/usr -L/usr conftest.c -lmysqlclient -lz -lX11 -lXpm -lpng -lz -ljpeg -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
/usr/lib/mysql/libmysqlclient.so: file not recognized: Is a directory
collect2: ld returned 1 exit status
configure: failed program was:
#line 60235 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
char mysql_error();
int main() {
mysql_error()
; return 0; }
Quote from: KEst on 24 de February , 2009, 08:09:29 PM
Obrigado pela ajuda!
Então hermano, não entendi cara, não seria mais fácil renomear? huhsuhs.
tipo o que vejo que faz com esse comando é renomear-lo, pois o make não ira procurar libmysqlclient.so e libmysqlclient.so.1 ou um ou outro não?
Então, não há o link libmysqlclient.so.1 not found!
O que está acontecendo é o mysql não foi instalado com as opções padrões(default)então o php não consegue encontra-lo.
Renomer não seria bom,pois outro arquivo pode necessitar do arquivo que foi renomeado,então criar um link simbolico(um atalho) seria a melhor forma.
As vezes acontece de algumas aplicações(o mysql no seu caso) ter recebi alguma atualização que fez com que o a libmysqlclient.so esteja em outro diretorio ou tenha mudado de nome.
Experimente dar apena um ./configure é veja qual o resultado.
[]'s
Então, fera.
Sem opção de --with-mysql funciona, mas quando coloca mysql... not
Eu estive lendo reports bug no php.net e descobri que é por causa de um icc, nem sei o que é isso.
Mas que com a versão 5.2.6 não verifica icc poderia passar, mas agora caiu em outro erro.
Desta vez passou do configure, mas parou no make
/usr/lib/mysql/libmysqlclient.so: file not recognized: Is a directory
collect2: ld returned 1 exit status
make: ** [libphp5.la] Erro 1
[root@samsou php-5.2.6]# make clean
find . -name *.gcno -o -name *.gcda | xargs rm -f
find . -name *.lo -o -name *.o | xargs rm -f
find . -name *.la -o -name *.a | xargs rm -f
find . -name *.so | xargs rm -f
find . -name .libs -a -type d|xargs rm -rf
rm -f libphp5.la sapi/cli/php libphp5.la modules/* libs/*
Post Merge: 26 de February , 2009, 12:28:20 PM
Lance loko
./configure
--prefix=/usr/local/php5
--exec-prefix=/usr/local/php5
--with-apxs2=/usr/local/apache2/bin/apxs
--disable-cgi
--with-gd
--with-jpeg-dir=/usr
--with-png-dir=/usr
--with-mysql
--with-pdo-mysql
--with-mysqli=/usr/bin/mysql_config
/usr/local/apache2/bin/apachectl stop
/usr/local/apache2/bin/apachectl -f /usr/local/apache2/conf/httpd.conf
Está funcionando... ;D
Vou ver se a conexão funciona com mysql.
Post Merge: 26 de February , 2009, 12:44:16 PM
Heys o PHP Info, não entendo não há MySQL
http://rapidshare.com/files/202831285/php_info_version_5.2.8.pdf.html
Post Merge: 26 de February , 2009, 03:54:05 PM
Não funciona com mysql nao, da o mesmo erro, a ultima postagem minha foi um erro eu usei '--with-mysql-dir=/usr/include/mysql'
como --with-mysql-dir não existe deu certo, e incrivelmente nao mostrou erro no final, mas não tive sucesso com mysql ainda.
Espero ajudas
Post Merge: 26 de February , 2009, 08:26:25 PM
Oh bug é esse:
http://bugs.mysql.com/bug.php?id=21158
Post Merge: 26 de February , 2009, 08:32:00 PM
A solução disso pode ser encontrada hein:
http://lists.mysql.com/commits/42259
ps: Ainda vou testar!
by KEst
Post Merge: 27 de February , 2009, 07:05:44 PM
Hey boys!
Incrivel, não entendo nada, de nada!
Baixei a versão do MySQL 5.1.31 e o PHP 5.2.9
mandei um ./configure com a seguinte sintaxe
./configure \
--prefix=/usr/local/php5 \
--exec-prefix=/usr/local/php5 \
--with-apxs2=/usr/local/apache2/bin/apxs \
--disable-cgi \
--with-gd \
--with-jpeg-dir=/usr \
--with-png-dir=/usr \
--with-mysql
E o phpinfo() reconheceu o mysql.
Agora já até posso fazer um tutorial de LAMP + PHPGTK for Fedora, hushsh!
by KEst