Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_init@4,该符号在函数 "bool __cdecl ConnectDatabase(void"/> Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_init@4,该符号在函数 "bool __cdecl ConnectDatabase(void">
Home > Database > Mysql Tutorial > body text

vs2012-win764 + VS2012 + mysql 5.7.4 X86_64 在VS编译不了。

WBOY
Release: 2016-06-06 09:44:04
Original
1214 people have browsed it

mysqlvs2012

1>Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_server_init@12,该符号在函数 "bool __cdecl ConnectDatabase(void)" (?ConnectDatabase@@YA_NXZ) 中被引用
1>Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_init@4,该符号在函数 "bool __cdecl ConnectDatabase(void)" (?ConnectDatabase@@YA_NXZ) 中被引用
1>Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_free_result@4,该符号在函数 "void __cdecl CloseSql(void)" (?CloseSql@@YAXXZ) 中被引用
1>Demo.obj : error LNK2019: 无法解析的外部符号 _mysql_close@4,该符号在函数 "void __cdecl CloseSql(void)" (?CloseSql@@YAXXZ) 中被引用

包含目录添加了D:\Program Files\MySQL\MySQL Server 5.7\include;
库目录添加了D:\Program Files\MySQL\MySQL Server 5.7\lib;
就是编译错误。
请大神帮帮我, 太纠结了

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!