7 messages in com.mysql.lists.mysqlRe: C API
FromSent OnAttachments
Vinc...@alcatel.fr03 Jun 2003 09:45 
Roman Neuhauser03 Jun 2003 10:16 
Paul DuBois03 Jun 2003 10:17 
vze2...@verizon.net03 Jun 2003 10:25 
Vinc...@alcatel.fr03 Jun 2003 22:40 
Paul DuBois11 Jun 2003 20:01 
T R O D A T11 Jun 2003 20:22 
Subject:Re: C API
From:Vinc...@alcatel.fr (Vinc@alcatel.fr)
Date:06/03/2003 10:40:05 PM
List:com.mysql.lists.mysql

#include <conio.h> #include <stdarg.h> #include "winsock.h" #include <stdio.h> #include <stdlib.h> #include <string.h> #include <mysql.h>

int main(void) { MYSQL* toto;

toto = mysql_init(toto); }

/* this is the compler log */

Compiler: Default compiler Executing gcc.exe... gcc.exe "U:\mep\Dev\abr.c" -o "U:\mep\Dev\abr.exe" -I"C:\Dev-Cpp\include" -I"C:\mysql\include" -L"C:\Dev-Cpp\lib" C:\DOCUME~1\badier1\LOCALS~1\Temp/ccW8aaaa.o(.text+0x1d2):abr.c: undefined reference to `mysql_init@4'

Execution terminated

Does that command list the directory where the MySQL client library is located, so that the compiler can find it? -L"C:\mysql\lib\opt" or -L"C:\mysql\lib\debug" perhaps?

I also include thoses directories, where dll's are located, and error remain the same :

Compiler: Default compiler Executing gcc.exe... gcc.exe "U:\mep\Dev\abr.c" -o "U:\mep\Dev\abr.exe" -I"C:\Dev-Cpp\include" -I"C:\mysql\include" -L"C:\Dev-Cpp\lib" -L"c:\mysql\lib" -L"C:\mysql\lib\opt" -L"c:\mysql\lib\debug" C:\DOCUME~1\badier1\LOCALS~1\Temp/ccKIaaaa.o(.text+0x25):abr.c: undefined reference to `mysql_init@4'

Execution terminated