paulloal
(usa Debian)
Enviado em 23/02/2008 - 18:25h
vlw consegui.. surgiu outro problema huihiuhiu
vo compilar esse cod
->>
#include <stdio.h>
#include <mysql/mysql.h>
void main(void)
{
MYSQL conexao;
mysql_init(&conexao);
mysql_real_connect(&conexao, "localhost", "guest", "guest", "aluno", 0, NULL, 0);
printf("conectado com sucesso!\n");
mysql_close(&conexao);
}
da esse erro
st.c: In function ‘main’:
st.c:5: warning: return type of ‘main’ is not ‘int’
/tmp/ccYZ0zs4.o: In function `main':
st.c:(.text+0x29): undefined reference to `mysql_init'
st.c:(.text+0x6f): undefined reference to `mysql_real_connect'
st.c:(.text+0x89): undefined reference to `mysql_close'
collect2: ld returned 1 exit status