免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12下一页
最近访问板块 发新帖
查看: 5112 | 回复: 11
打印 上一主题 下一主题

[C++] 用Visual Studio 2013和Codelite写C++,怎么连接到mysql。 [复制链接]

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2014-12-14 17:34 |只看该作者 |正序浏览
本帖最后由 fender0107401 于 2014-12-14 17:36 编辑

我下载了mysql connector,然后就是放到C盘的一个地方,然后就是设置IDE里面的include path、lib path、依赖的lib之类的东西。

用的这个:http://dev.mysql.com/downloads/connector/cpp/

但是编译测试代码的时候,Visual Studio 2013显示这么一堆:
  1. 1>mysqlcppconn-static.lib(mysql_art_resultset.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in main.obj
  2. 1>mysqlcppconn-static.lib(mysql_art_resultset.obj) : error LNK2005: "public: virtual __thiscall sql::InvalidArgumentException::~InvalidArgumentException(void)" (??1InvalidArgumentException@sql@@UAE@XZ) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  3. 1>mysqlcppconn-static.lib(mysql_art_resultset.obj) : error LNK2005: "public: __thiscall sql::SQLException::SQLException(class sql::SQLException const &)" (??0SQLException@sql@@QAE@ABV01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  4. 1>mysqlcppconn-static.lib(mysql_art_resultset.obj) : error LNK2005: "public: __thiscall sql::InvalidArgumentException::InvalidArgumentException(struct sql::InvalidArgumentException const &)" (??0InvalidArgumentException@sql@@QAE@ABU01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  5. 1>mysqlcppconn-static.lib(mysql_resultset_metadata.obj) : error LNK2038: mismatch detected for '_MSC_VER': value '1600' doesn't match value '1800' in main.obj
  6. 1>mysqlcppconn-static.lib(mysql_resultset_metadata.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in main.obj
  7. 1>mysqlcppconn-static.lib(mysql_resultset_metadata.obj) : error LNK2005: "public: virtual __thiscall sql::InvalidArgumentException::~InvalidArgumentException(void)" (??1InvalidArgumentException@sql@@UAE@XZ) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  8. 1>mysqlcppconn-static.lib(mysql_resultset_metadata.obj) : error LNK2005: "public: __thiscall sql::SQLException::SQLException(class sql::SQLException const &)" (??0SQLException@sql@@QAE@ABV01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  9. 1>mysqlcppconn-static.lib(mysql_resultset_metadata.obj) : error LNK2005: "public: __thiscall sql::InvalidArgumentException::InvalidArgumentException(struct sql::InvalidArgumentException const &)" (??0InvalidArgumentException@sql@@QAE@ABU01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  10. 1>mysqlcppconn-static.lib(mysql_art_rset_metadata.obj) : error LNK2038: mismatch detected for '_MSC_VER': value '1600' doesn't match value '1800' in main.obj
  11. 1>mysqlcppconn-static.lib(mysql_art_rset_metadata.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in main.obj
  12. 1>mysqlcppconn-static.lib(mysql_art_rset_metadata.obj) : error LNK2005: "public: virtual __thiscall sql::InvalidArgumentException::~InvalidArgumentException(void)" (??1InvalidArgumentException@sql@@UAE@XZ) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  13. 1>mysqlcppconn-static.lib(mysql_art_rset_metadata.obj) : error LNK2005: "public: __thiscall sql::SQLException::SQLException(class sql::SQLException const &)" (??0SQLException@sql@@QAE@ABV01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  14. 1>mysqlcppconn-static.lib(mysql_art_rset_metadata.obj) : error LNK2005: "public: __thiscall sql::InvalidArgumentException::InvalidArgumentException(struct sql::InvalidArgumentException const &)" (??0InvalidArgumentException@sql@@QAE@ABU01@@Z) already defined in mysqlcppconn.lib(mysqlcppconn.dll)
  15. 1>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
复制代码
用Codelite编译测试代码的时候,结果发现这个库的头文件里面定义的一些东西和mingw提供的头文件有冲突,所以也没法用。

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
12 [报告]
发表于 2014-12-17 21:05 |只看该作者

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
11 [报告]
发表于 2014-12-17 21:02 |只看该作者
本帖最后由 fender0107401 于 2014-12-17 21:04 编辑

回复 9# action08

问个问题,使用OTL的时候,需要链接什么库吗,我在尝试连MySQL。
  1. #include <iostream>
  2. using namespace std;

  3. #include <stdio.h>

  4. #define OTL_ODBC_MYSQL

  5. #define OTL_UNICODE

  6. #include "otlv4.h"

  7. otl_connect db;

  8. int main()
  9. {
  10.         otl_connect::otl_initialize();

  11.         return 0;
  12. }
复制代码
报错如下:

1>main.obj : error LNK2001: unresolved external symbol __fltused
1>main.obj : error LNK2019: unresolved external symbol "extern "C" double __cdecl _hypot(double,double)" (?_hypot@@$$J0YANNN@Z) referenced in function "extern "C" double __cdecl hypot(double,double)" (?hypot@@$$J0YANNN@Z)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl __ExceptionPtrCopy(void *,void const *)" (?__ExceptionPtrCopy@@$$FYAXPAXPBX@Z) referenced in function "public: __thiscall std::exception_ptr::exception_ptr(class std::exception_ptr const &)" (??0exception_ptr@std@@$$FQAE@ABV01@@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void * __cdecl memcpy(void *,void const *,unsigned int)" (?memcpy@@$$J0YAPAXPAXPBXI@Z) referenced in function "public: static char * __cdecl std::char_traits<char>::copy(char *,char const *,unsigned int)" (?copy@?$char_traits@D@std@@$$FSAPADPADPBDI@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void * __cdecl memmove(void *,void const *,unsigned int)" (?memmove@@$$J0YAPAXPAXPBXI@Z) referenced in function "public: static char * __cdecl std::char_traits<char>::move(char *,char const *,unsigned int)" (?move@?$char_traits@D@std@@$$FSAPADPADPBDI@Z)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl std::_Debug_message(wchar_t const *,wchar_t const *,unsigned int)" (?_Debug_message@std@@$$FYAXPB_W0I@Z) referenced in function "public: void __thiscall std::_Iterator_base12::_Orphan_me(void)" (?_Orphan_me@_Iterator_base12@std@@$$FQAEXXZ)
1>main.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall std::exception::~exception(void)" (??1exception@std@@$$FUAE@XZ) referenced in function "public: virtual __thiscall std::runtime_error::~runtime_error(void)" (??1runtime_error@std@@$$FUAE@XZ)
1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall std::exception::exception(class std::exception const &)" (??0exception@std@@$$FQAE@ABV01@@Z) referenced in function "public: __thiscall std::runtime_error::runtime_error(class std::runtime_error const &)" (??0runtime_error@std@@$$FQAE@ABV01@@Z)
1>main.obj : error LNK2001: unresolved external symbol "const type_info::`vftable'" (??_7type_info@@6B@)
1>main.obj : error LNK2001: unresolved external symbol "public: virtual char const * __thiscall std::exception::what(void)const " (?what@exception@std@@UBEPBDXZ)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void __clrcall ___CxxCallUnwindDtor(void (__clrcall*)(void *),void *)" (?___CxxCallUnwindDtor@@$$J0YMXP6MXPAX@Z0@Z) referenced in function "public: __thiscall std::runtime_error::runtime_error(class std::runtime_error const &)" (??0runtime_error@std@@$$FQAE@ABV01@@Z)
1>main.obj : error LNK2001: unresolved external symbol __purecall
1>main.obj : error LNK2019: unresolved external symbol "bool __cdecl std::uncaught_exception(void)" (?uncaught_exception@std@@$$FYA_NXZ) referenced in function "bool __cdecl otl_uncaught_exception(void)" (?otl_uncaught_exception@@$$FYA_NXZ)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl operator delete[](void *)" (??_V@$$FYAXPAX@Z) referenced in function "public: __thiscall otl_column_desc::~otl_column_desc(void)" (??1otl_column_desc@@$$FQAE@XZ)
1>main.obj : error LNK2019: unresolved external symbol "void * __cdecl operator new[](unsigned int)" (??_U@$$FYAPAXI@Z) referenced in function "public: __thiscall otl_column_desc::otl_column_desc(class otl_column_desc const &)" (??0otl_column_desc@@$$FQAE@ABV0@@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl strcpy_s(char *,unsigned int,char const *)" (?strcpy_s@@$$J0YAHPADIPBD@Z) referenced in function "public: __thiscall otl_column_desc::otl_column_desc(class otl_column_desc const &)" (??0otl_column_desc@@$$FQAE@ABV0@@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void * __cdecl memset(void *,int,unsigned int)" (?memset@@$$J0YAPAXPAXHI@Z) referenced in function "public: __thiscall otl_long_string::otl_long_string(int,int)" (??0otl_long_string@@$$FQAE@HH@Z)
1>main.obj : error LNK2019: unresolved external symbol "void __clrcall `eh vector destructor iterator'(void *,unsigned int,int,void (__clrcall*)(void *))" (??_M@$$FYMXPAXIHP6MX0@Z@Z) referenced in function "public: void * __thiscall otl_datetime::`vector deleting destructor'(unsigned int)" (??_Eotl_datetime@@$$FQAEPAXI@Z)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl operator delete(void *)" (??3@$$FYAXPAX@Z) referenced in function "public: void * __thiscall otl_datetime::`vector deleting destructor'(unsigned int)" (??_Eotl_datetime@@$$FQAEPAXI@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl strncpy_s(char *,unsigned int,char const *,unsigned int)" (?strncpy_s@@$$J0YAHPADIPBDI@Z) referenced in function "public: __thiscall otl_tmpl_exception<class otl_exc,class otl_conn,class otl_cur>::otl_tmpl_exception<class otl_exc,class otl_conn,class otl_cur>(class otl_conn &,char const *)" (??0?$otl_tmpl_exception@Votl_exc@@Votl_conn@@Votl_cur@@@@$$FQAE@AAVotl_conn@@PBD@Z)
1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall std::_Container_base12::~_Container_base12(void)" (??1_Container_base12@std@@$$FQAE@XZ) referenced in function "public: __thiscall std::_String_val<struct std::_Simple_types<char> >::~_String_val<struct std::_Simple_types<char> >(void)" (??1?$_String_val@U?$_Simple_types@D@std@@@std@@$$FQAE@XZ)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl std::_Xlength_error(char const *)" (?_Xlength_error@std@@$$FYAXPBD@Z) referenced in function "public: void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Xlen(void)const " (?_Xlen@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@$$FQBEXXZ)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl std::_Xout_of_range(char const *)" (?_Xout_of_range@std@@$$FYAXPBD@Z) referenced in function "public: void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Xran(void)const " (?_Xran@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@$$FQBEXXZ)
1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall std::_Container_base12::_Container_base12(void)" (??0_Container_base12@std@@$$FQAE@XZ) referenced in function "public: __thiscall std::_String_val<struct std::_Simple_types<char> >::_String_val<struct std::_Simple_types<char> >(void)" (??0?$_String_val@U?$_Simple_types@D@std@@@std@@$$FQAE@XZ)
1>main.obj : error LNK2019: unresolved external symbol "void * __cdecl operator new(unsigned int)" (??2@$$FYAPAXI@Z) referenced in function "struct std::_Container_proxy * __cdecl std::_Allocate<struct std::_Container_proxy>(unsigned int,struct std::_Container_proxy *)" (??$_Allocate@U_Container_proxy@std@@@std@@$$FYAPAU_Container_proxy@0@IPAU10@@Z)
1>main.obj : error LNK2019: unresolved external symbol "void __cdecl std::_Xbad_alloc(void)" (?_Xbad_alloc@std@@$$FYAXXZ) referenced in function "struct std::_Container_proxy * __cdecl std::_Allocate<struct std::_Container_proxy>(unsigned int,struct std::_Container_proxy *)" (??$_Allocate@U_Container_proxy@std@@@std@@$$FYAPAU_Container_proxy@0@IPAU10@@Z)
1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall std::_Lockit::_Lockit(int)" (??0_Lockit@std@@$$FQAE@H@Z) referenced in function "public: void __thiscall std::_Iterator_base12::_Adopt(struct std::_Container_base12 const *)" (?_Adopt@_Iterator_base12@std@@$$FQAEXPBU_Container_base12@2@@Z)
1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall std::_Lockit::~_Lockit(void)" (??1_Lockit@std@@$$FQAE@XZ) referenced in function "public: void __thiscall std::_Iterator_base12::_Adopt(struct std::_Container_base12 const *)" (?_Adopt@_Iterator_base12@std@@$$FQAEXPBU_Container_base12@2@@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void __stdcall _CxxThrowException(void *,struct _s__ThrowInfo const *)" (?_CxxThrowException@@$$J18YGXPAXPBU_s__ThrowInfo@@@Z) referenced in function "public: void __thiscall otl_tmpl_connect<class otl_exc,class otl_conn,class otl_cur>::logoff(void)" (?logoff@?$otl_tmpl_connect@Votl_exc@@Votl_conn@@Votl_cur@@@@$$FQAEXXZ)
1>main.obj : error LNK2019: unresolved external symbol "public: void __thiscall std::_Container_base12::_Orphan_all(void)" (?_Orphan_all@_Container_base12@std@@$$FQAEXXZ) referenced in function "public: void __thiscall std::_String_alloc<0,struct std::_String_base_types<char,class std::allocator<char> > >::_Free_proxy(void)" (?_Free_proxy@?$_String_alloc@$0A@U?$_String_base_types@DV?$allocator@D@std@@@std@@@std@@$$FQAEXXZ)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl __CxxQueryExceptionSize(void)" (?__CxxQueryExceptionSize@@$$J0YAHXZ) referenced in function "public: void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Copy(unsigned int,unsigned int)" (?_Copy@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@$$FQAEXII@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl __CxxExceptionFilter(void *,void *,int,void *)" (?__CxxExceptionFilter@@$$J0YAHPAX0H0@Z) referenced in function $LN14
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl __CxxRegisterExceptionObject(void *,void *)" (?__CxxRegisterExceptionObject@@$$J0YAHPAX0@Z) referenced in function $LN55
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __cdecl __CxxDetectRethrow(void *)" (?__CxxDetectRethrow@@$$J0YAHPAX@Z) referenced in function $LN23
1>main.obj : error LNK2019: unresolved external symbol "extern "C" void __cdecl __CxxUnregisterExceptionObject(void *,int)" (?__CxxUnregisterExceptionObject@@$$J0YAXPAXH@Z) referenced in function __catch$?_Copy@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@$$FQAEXII@Z$3
1>main.obj : error LNK2019: unresolved external symbol "char const * __cdecl std::_Syserror_map(int)" (?_Syserror_map@std@@$$FYAPBDH@Z) referenced in function "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall std::_Generic_error_category::message(int)const " (?message@_Generic_error_category@std@@$$FUBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@H@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" unsigned int __cdecl strlen(char const *)" (?strlen@@$$J0YAIPBD@Z) referenced in function "public: static unsigned int __cdecl std::char_traits<char>::length(char const *)" (?length@?$char_traits@D@std@@$$FSAIPBD@Z)
1>main.obj : error LNK2019: unresolved external symbol "char const * __cdecl std::_Winerror_map(int)" (?_Winerror_map@std@@$$FYAPBDH@Z) referenced in function "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall std::_System_error_category::message(int)const " (?message@_System_error_category@std@@$$FUBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@H@Z)
1>main.obj : error LNK2019: unresolved external symbol "extern "C" int __clrcall _atexit_m(void (__clrcall*)(void))" (?_atexit_m@@$$J0YMHP6MXXZ@Z) referenced in function "void __clrcall `dynamic initializer for 'db''(void)" (???__Edb@@YMXXZ@?A0xbfeb62b6@@$$FYMXXZ)
1>LINK : error LNK2001: unresolved external symbol _mainCRTStartup
1>LINK : error LNK2001: unresolved external symbol __CorExeMain@0


我感觉还应该链接点什么库,要不然咱们这样啊?不过网上说OTL就是一个头文件就行了。

注:ODBC已经没问题了,我配置完了的时候点击了一下测试,显示可以链接。
   

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
10 [报告]
发表于 2014-12-16 21:02 |只看该作者
哎呀,兄弟们这么帮忙,太感动了。

论坛徽章:
224
2022北京冬奥会纪念版徽章
日期:2015-08-10 16:30:32操作系统版块每日发帖之星
日期:2016-02-18 06:20:00操作系统版块每日发帖之星
日期:2016-03-01 06:20:00操作系统版块每日发帖之星
日期:2016-03-02 06:20:0015-16赛季CBA联赛之上海
日期:2019-09-20 12:29:3219周年集字徽章-周
日期:2019-10-01 20:47:4815-16赛季CBA联赛之八一
日期:2020-10-23 18:30:5320周年集字徽章-20	
日期:2020-10-28 14:14:2615-16赛季CBA联赛之广夏
日期:2023-02-25 16:26:26CU十四周年纪念徽章
日期:2023-04-13 12:23:1015-16赛季CBA联赛之四川
日期:2023-07-25 16:53:45操作系统版块每日发帖之星
日期:2016-05-10 19:22:58
9 [报告]
发表于 2014-12-16 19:49 |只看该作者
以前有家公司用的http://otl.sourceforge.net/

配置也很简单

论坛徽章:
24
狮子座
日期:2013-12-31 10:48:0015-16赛季CBA联赛之吉林
日期:2016-04-18 14:43:1015-16赛季CBA联赛之北控
日期:2016-05-18 15:01:4415-16赛季CBA联赛之上海
日期:2016-06-22 18:00:1315-16赛季CBA联赛之八一
日期:2016-06-25 11:02:2215-16赛季CBA联赛之佛山
日期:2016-08-17 22:48:2615-16赛季CBA联赛之福建
日期:2016-12-27 22:39:272016科比退役纪念章
日期:2017-02-08 23:49:4315-16赛季CBA联赛之八一
日期:2017-02-16 01:05:3415-16赛季CBA联赛之山东
日期:2017-02-22 15:34:5615-16赛季CBA联赛之上海
日期:2017-11-25 16:17:5015-16赛季CBA联赛之四川
日期:2016-01-17 18:38:37
8 [报告]
发表于 2014-12-16 19:44 |只看该作者
fender0107401 发表于 2014-12-15 21:05
最新战况:

下载了一个CMake,下载了mysql connector的代码,又倒腾了一下。



       直接用编译好的得了: http://dev.mysql.com/downloads/windows/visualstudio/

论坛徽章:
1
2015年迎新春徽章
日期:2015-03-04 09:56:11
7 [报告]
发表于 2014-12-16 17:00 |只看该作者
别整IDE,直接makefile啊

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
6 [报告]
发表于 2014-12-15 21:05 |只看该作者
本帖最后由 fender0107401 于 2014-12-15 21:21 编辑

最新战况:

下载了一个CMake,下载了mysql connector的代码,又倒腾了一下。

使用codelite里面的mingw的话,那么可以顺利生成配置文件,但是没法编译,因为有一个头文件里面的int32什么的定义跟mingw里面提供的有冲突。于是乎,失败了。

使用visual studio 2013,也可以顺利生成配置文件,不过得指定一下libmysql.dll的具体位置,不过还是没法编译,编译的时候提示libmysql.dll有损坏什么的。于是乎,又失败了。

哈哈,不折腾了,真是麻烦。还是在Linux、BSD下面混吧,装什么都是不用操心的事情。

论坛徽章:
89
水瓶座
日期:2014-04-01 08:53:31天蝎座
日期:2014-04-01 08:53:53天秤座
日期:2014-04-01 08:54:02射手座
日期:2014-04-01 08:54:15子鼠
日期:2014-04-01 08:55:35辰龙
日期:2014-04-01 08:56:36未羊
日期:2014-04-01 08:56:27戌狗
日期:2014-04-01 08:56:13亥猪
日期:2014-04-01 08:56:02亥猪
日期:2014-04-08 08:38:58程序设计版块每日发帖之星
日期:2016-01-05 06:20:00程序设计版块每日发帖之星
日期:2016-01-07 06:20:00
5 [报告]
发表于 2014-12-15 11:27 |只看该作者
回复 4# hellioncu

好吧,我还得安装一个windows的cmake。


   

论坛徽章:
324
射手座
日期:2013-08-23 12:04:38射手座
日期:2013-08-23 16:18:12未羊
日期:2013-08-30 14:33:15水瓶座
日期:2013-09-02 16:44:31摩羯座
日期:2013-09-25 09:33:52双子座
日期:2013-09-26 12:21:10金牛座
日期:2013-10-14 09:08:49申猴
日期:2013-10-16 13:09:43子鼠
日期:2013-10-17 23:23:19射手座
日期:2013-10-18 13:00:27金牛座
日期:2013-10-18 15:47:57午马
日期:2013-10-18 21:43:38
4 [报告]
发表于 2014-12-15 11:20 |只看该作者
mysql connector的INSTALL中 BUILDING ON WINDOWS 一节说了要用CMake来生成项目文件
  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP