1. 首次編譯的錯誤
>C:\Program Files\Microsoft Visual Studio 9.0\VC\atlmfc\include\..\src\mfc\afximpl.h(631) : error C2059: syntax error : '<L_TYPE_raw>'
>C:\Program Files\Microsoft Visual Studio 9.0\VC\atlmfc\include\..\src\mfc\afximpl.h(631) : error C2238: unexpected token(s) preceding ';'
>C:\Program Files\Microsoft Visual Studio 9.0\VC\atlmfc\include\..\src\mfc\afximpl.h(635) : error C2059: syntax error : '<L_TYPE_raw>'
>C:\Program Files\Microsoft Visual Studio 9.0\VC\atlmfc\include\..\src\mfc\afximpl.h(635) : error C2238: unexpected token(s) preceding ';'
解決方法:
找到 stdafx.h, 修改如下
#ifndef WINVER
#if _MSC_VER>=1500????????? // 1500 == Visual Studio 2008
#define WINVER 0x0501?????? // 0501 == Windows XP and Windows .NET Server
#else
#define WINVER 0x0400??// 0x0400 == Windows 98 and Windows NT 4.0 (because of '_WIN32_WINDOWS=0x0410')
#endif
#endif
#ifndef _WIN32_WINNT
#if _MSC_VER>=1500????????????? // 1500 == Visual Studio 2008
#define _WIN32_WINNT 0x0501??// 0501 == Windows XP
#else
#define _WIN32_WINNT 0x0400??// 0x0400 == Windows NT 4.0
#endif
#endif
2.
error C2011: 'tagMENUINFO' : 'struct' type redefinition
解決方法如下:
找到 .\src\UILayer\TitleMenu.h 修改如下
3.
C:\Program Files\Microsoft Visual Studio 9.0\VC\atlmfc\include\..\src\mfc\afximpl.h(54) : 參見“AUX_DATA”的聲明
解決方法如下:
AUX_DATA中已不再包含成員bWin95
#if _MSC_VER>=1500????????? // 1500 == Visual Studio 2008
lf.lfQuality = ANTIALIASED_QUALITY;
#else
lf.lfQuality = afxData.bWin95 ? NONANTIALIASED_QUALITY : ANTIALIASED_QUALITY;
#endif
大約有10 處
4.
.\WorkLayer\FtpClientReqSocket.cpp(51) : error C2440: “初始化”: 無法從“const char *”轉換為“char *”
解決方法如下:
?char *p=(char*)strstr(pData,"\r\n");
5.
.\Emule.cpp(18) : warning C4603: “_CRTDBG_MAP_ALLOC”: 未定義宏或在預編譯頭使用后定義發生改變
??????? 將宏添加到預編譯頭中,而不是在此處定義
??????? .\Emule.cpp(21) : 使用預編譯頭
.\Emule.cpp(294) : fatal error C1189: #error :? "You are using an MFC version which may require a special version of the above function!"
解決方法如下:
// Workaround for buggy 'AfxSocketTerm' (needed at least for MFC 7.0)
#if _MFC_VER==0x0700 || _MFC_VER==0x0710 || _MFC_VER==0x0800 || _MFC_VER==0x0900
?