本文共 918 字,大约阅读时间需要 3 分钟。
今天在移植一个EVC的程序到VS2005底下是碰到一些问题 :(以解决,写到此以防忘记) fatal error C1189: #error : Please use the /MD switch for _AFXDLL builds 打开Project properties对话框里,切换到C/C++->Code generation页,将Runtime Libarary 设置成“Multi-threaded DLL(/MD)”。即可解决此问题。 接着编译工程,此时会提示如下错误: fatal error RC1015: cannot open include file 'wceres.rc'.这里我们需要在TXDEMO.RC文件里,将#include "wceres.rc"注释掉。 //#include "wceres.rc" // WCE-specific components 接着编译工程,此时会提示如下错误: corelibc.lib(wwinmain.obj) : error LNK2019: unresolved external symbol wWinMain referenced in function wWinMainCRTStartup 此时,我们依旧打开project properties对话框,切换到Linker->Advanced页,将Entry Point由wWinMainCRTStartup改成WinMainCRTStartup。 此时再次编译,系统不在提示错误,但是编译好的程序,还不能在模拟器或者MOBILE5.0 POCKET PC的机器上运行。 我们接着设置项目属性,在Configuration Properties->Gengeral页将Use of MFC ,改成静态连接。 将 IDD_RECOED_DIALOG DIALOG 0, 0, 139, 141 STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION| WS_VISIBLE中的 DS_MODALFRAME 删除。 OK在ARM2440上跑没有问题 |
转载地址:http://owyob.baihongyu.com/