什么错?我想应该是能够协调的,就像刚开始在ATL中用MFC一样,编译也很麻烦,久而久之,就找到窍门了。

解决方案 »

  1.   

    --------------------Configuration: MySql_test - Win32 Release--------------------
    Compiling...
    Database.cpp
    C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\math.h(514) : error C2894: templates cannot be declared to have 'C' linkage
    C:\APACHE\MYSQL\INCLUDE\config-win.h(154) : error C2084: function 'double __cdecl rint(double)' already has a body
    C:\APACHE\MYSQL\INCLUDE\config-win.h(166) : error C2084: function 'double __cdecl ulonglong2double(unsigned __int64)' already has a body
    C:\APACHE\MYSQL\INCLUDE\my_global.h(320) : warning C4005: '_PC' : macro redefinition
            C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\tchar.h(776) : see previous definition of '_PC'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2146: syntax error : missing ';' before identifier 'fd'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2501: 'SOCKET' : missing storage-class or type specifiers
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2501: 'fd' : missing storage-class or type specifiers
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(182) : error C2065: 'SOCKET' : undeclared identifier
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(182) : error C2146: syntax error : missing ')' before identifier 's'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(183) : error C2059: syntax error : ')'
    D:\C++Project\MySql_test\Database.cpp(142) : error C2065: 'mysql_create_db' : undeclared identifier
    D:\C++Project\MySql_test\Database.cpp(152) : error C2065: 'mysql_drop_db' : undeclared identifier
    Error executing cl.exe.MySql_test.exe - 11 error(s), 1 warning(s)
      

  2.   

    --------------------Configuration: MySql_test - Win32 Release--------------------
    Compiling...
    Database.cpp
    C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\math.h(514) : error C2894: templates cannot be declared to have 'C' linkage
    C:\APACHE\MYSQL\INCLUDE\config-win.h(154) : error C2084: function 'double __cdecl rint(double)' already has a body
    C:\APACHE\MYSQL\INCLUDE\config-win.h(166) : error C2084: function 'double __cdecl ulonglong2double(unsigned __int64)' already has a body
    C:\APACHE\MYSQL\INCLUDE\my_global.h(320) : warning C4005: '_PC' : macro redefinition
            C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\tchar.h(776) : see previous definition of '_PC'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2146: syntax error : missing ';' before identifier 'fd'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2501: 'SOCKET' : missing storage-class or type specifiers
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(118) : error C2501: 'fd' : missing storage-class or type specifiers
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(182) : error C2065: 'SOCKET' : undeclared identifier
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(182) : error C2146: syntax error : missing ')' before identifier 's'
    C:\APACHE\MYSQL\INCLUDE\mysql_com.h(183) : error C2059: syntax error : ')'
    D:\C++Project\MySql_test\Database.cpp(142) : error C2065: 'mysql_create_db' : undeclared identifier
    D:\C++Project\MySql_test\Database.cpp(152) : error C2065: 'mysql_drop_db' : undeclared identifier
    Error executing cl.exe.MySql_test.exe - 11 error(s), 1 warning(s)
      

  3.   

    我想你应该阅读一下里面的帮助文件, 我没有开发过但是我知道一些第三方的SDK要求一些编译配置, 比如Raitonal Purcoverage里面的头文件要求不能具备预编译头等等.
      

  4.   

    回复人: nne998(上上下下左右左右BABA) (  ) 信誉:99  2002-06-03 13:48:00  得分:0  
     
     
      up........
    uplllllllllll