Thread overview | ||||||
---|---|---|---|---|---|---|
|
December 13, 2003 Call mysql failed | ||||
---|---|---|---|---|
| ||||
Hi, what happen to me when i compile it, prompt me this error message... Error 42: Symbol Undefined _mysql_init@4 #include <stdio.h> #include <mysql/mysql.h> main(){ MYSQL *mysql; mysql_init(&mysql); } Thank you. |
December 13, 2003 Re: Call mysql failed | ||||
---|---|---|---|---|
| ||||
Posted in reply to mooncake | Well, I think you would have to include the MySQL library into your link phase. Probably more of an issue... You might have to recompile the MySQL library for Digital Mars C++. HTH mooncake wrote: > Hi, what happen to me when i compile it, prompt me this error message... > > Error 42: Symbol Undefined _mysql_init@4 > > > #include <stdio.h> > #include <mysql/mysql.h> > > main(){ > MYSQL *mysql; > mysql_init(&mysql); > > } > > Thank you. > > -- ManiaC++ Jan Knepper |
December 14, 2003 Re: Call mysql failed | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jan Knepper | Hi, Would you mind to teach me how to include the MySQL library into my link phase? How to recompile the MySQL library? Thank you... In article <brf6v2$1dlq$1@digitaldaemon.com>, Jan Knepper says... > >Well, I think you would have to include the MySQL library into your link >phase. >Probably more of an issue... You might have to recompile the MySQL >library for Digital Mars C++. > >HTH > >mooncake wrote: >> Hi, what happen to me when i compile it, prompt me this error message... >> >> Error 42: Symbol Undefined _mysql_init@4 >> >> >> #include <stdio.h> >> #include <mysql/mysql.h> >> >> main(){ >> MYSQL *mysql; >> mysql_init(&mysql); >> >> } >> >> Thank you. >> >> > > >-- >ManiaC++ >Jan Knepper > |
December 14, 2003 Re: Call mysql failed | ||||
---|---|---|---|---|
| ||||
Posted in reply to mooncake | Well, this requires some study if you have never done anything like it. Is the MySQL library you are using C or C++? If it is C you might be able to just add it to the project and link it. If it is C++ you more likely will have to recompile it. I think the sources to the MySQL client are freely available, so what you could do it research them and look for the existing project(s) / makefile(s) on how they build the .lib for specific compilers and build something like it for DMC++ HTH mooncake wrote: > Hi, Would you mind to teach me how to include the MySQL library into my link phase? > How to recompile the MySQL library? > > Thank you... > > In article <brf6v2$1dlq$1@digitaldaemon.com>, Jan Knepper says... > >>Well, I think you would have to include the MySQL library into your link phase. >>Probably more of an issue... You might have to recompile the MySQL library for Digital Mars C++. >> >>HTH >> >>mooncake wrote: >> >>>Hi, what happen to me when i compile it, prompt me this error message... >>> >>>Error 42: Symbol Undefined _mysql_init@4 >>> >>> >>>#include <stdio.h> >>>#include <mysql/mysql.h> >>> >>>main(){ >>>MYSQL *mysql; >>>mysql_init(&mysql); >>> >>>} >>> >>>Thank you. >>> >>> >> >> >>-- >>ManiaC++ >>Jan Knepper >> > > > -- ManiaC++ Jan Knepper |
Copyright © 1999-2021 by the D Language Foundation