使用ICE遇到的编译问题
2007-08-23 15:45
525 查看
使用ICE遇到的编译问题
使用前,先要进行如下设置:
添加/GR编译选项 Enable C++ RTTI。
添加ice的include、StlPort的include、ice的lib路径,并将这些路径提到最前,以免与VC的冲突。
为Link Object/Library modles 加上iced.lib iceutild.lib 。
1、编译中出现
Linking
LINK : fatal error LNK1104: cannot open file "stlport_vc6_static.lib"
Error executing link.exe.
解决办法:
Porject->Setting->C++->CodeGeneration 设置Use Run-time library=Debug Multithreaded DLL
2、编译中出现
warning C4005: '_STLP_DEBUG_CHECK' : macro redefinition
解决办法:在包含ice/ice.h之前添加以下代码
#if !defined(NDEBUG) && !defined(_STLP_DEBUG)
# define _STLP_DEBUG
#endif
3、编译中出现
error C2065: 'TryEnterCriticalSection' : undeclared identifier
解决办法:
在stdafx.h中,加上
#ifndef _WIN32_WINNT
# define _WIN32_WINNT 0x400
#endif
4、编译中出现
error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall IceUtil::GCRecMutexInit::GCRecMutexInit(void)" (__imp_??0GCRecMutexInit@IceUtil@@QAE@XZ)
error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall IceUtil::GCRecMutexInit::~GCRecMutexInit(void)" (__imp_??1GCRecMutexInit@IceUtil@@QAE@XZ)
D
解决办法:
Porject->Setting->Link-> Object/Library modles:加上iced.lib iceutild.lib
5、编译中出现
error C2061: syntax error : identifier 'SC_HANDLE'
error C2061: syntax error : identifier 'SERVICE_STATUS'
error C2146: syntax error : missing ';' before identifier '_statusHandle'
error C2501: 'SERVICE_STATUS_HANDLE' : missing storage-class or type specifiers
error C2501: '_statusHandle' : missing storage-class or type specifiers
error C2146: syntax error : missing ';' before identifier '_status'
error C2501: 'SERVICE_STATUS' : missing storage-class or type specifiers
error C2501: '_status' : missing storage-class or type specifiers
解决办法:
在stdafx.h或其他文件中增加
#include <WINSVC.H>
作者:李珍宝(http://zhenbaodao51.51.net ,http://www.lizhenbao.com , http://www.cnitblog.com/lizhenbao/ )
使用前,先要进行如下设置:
添加/GR编译选项 Enable C++ RTTI。
添加ice的include、StlPort的include、ice的lib路径,并将这些路径提到最前,以免与VC的冲突。
为Link Object/Library modles 加上iced.lib iceutild.lib 。
1、编译中出现
Linking
LINK : fatal error LNK1104: cannot open file "stlport_vc6_static.lib"
Error executing link.exe.
解决办法:
Porject->Setting->C++->CodeGeneration 设置Use Run-time library=Debug Multithreaded DLL
2、编译中出现
warning C4005: '_STLP_DEBUG_CHECK' : macro redefinition
解决办法:在包含ice/ice.h之前添加以下代码
#if !defined(NDEBUG) && !defined(_STLP_DEBUG)
# define _STLP_DEBUG
#endif
3、编译中出现
error C2065: 'TryEnterCriticalSection' : undeclared identifier
解决办法:
在stdafx.h中,加上
#ifndef _WIN32_WINNT
# define _WIN32_WINNT 0x400
#endif
4、编译中出现
error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall IceUtil::GCRecMutexInit::GCRecMutexInit(void)" (__imp_??0GCRecMutexInit@IceUtil@@QAE@XZ)
error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall IceUtil::GCRecMutexInit::~GCRecMutexInit(void)" (__imp_??1GCRecMutexInit@IceUtil@@QAE@XZ)
D
解决办法:
Porject->Setting->Link-> Object/Library modles:加上iced.lib iceutild.lib
5、编译中出现
error C2061: syntax error : identifier 'SC_HANDLE'
error C2061: syntax error : identifier 'SERVICE_STATUS'
error C2146: syntax error : missing ';' before identifier '_statusHandle'
error C2501: 'SERVICE_STATUS_HANDLE' : missing storage-class or type specifiers
error C2501: '_statusHandle' : missing storage-class or type specifiers
error C2146: syntax error : missing ';' before identifier '_status'
error C2501: 'SERVICE_STATUS' : missing storage-class or type specifiers
error C2501: '_status' : missing storage-class or type specifiers
解决办法:
在stdafx.h或其他文件中增加
#include <WINSVC.H>
作者:李珍宝(http://zhenbaodao51.51.net ,http://www.lizhenbao.com , http://www.cnitblog.com/lizhenbao/ )
相关文章推荐
- 使用ICE遇到的编译问题
- 使用ICE遇到的编译问题
- 使用CMake + MinGW + Eclipse 开发OpenCV --编译,使用以及可能遇到的问题详解
- 使用PROC编译.pc文件成.c后遇到的问题
- 使用map迭代器中遇到的问题——非const转成const类型造成的编译错误
- 使用eclipse编译qt程序遇到问题的解决方法
- 使用QtWebKit加载网页,编译时遇到的问题
- 使用嵌入式linux完全手册光盘的arm-linux-gcc 遇到问题 自己编译
- 使用eclipse编译jni代码遇到的问题记录
- Android下jni开发之ndk的使用(下载、配置、编译遇到的问题)
- g++使用第三方库编译时遇到的一个小问题
- 亲笔,spark编译、安装、部署、使用的经历中所遇到的问题
- iOS开发遇到的坑之六--使用cocopods管理第三方库时,编译出现Library not found for -lPods问题的解决办法
- VS2010下使用STLport编译boost时遇到的一些问题
- 使用VIM开发软件项目 - (16) vim编译中遇到的问题及解决方法
- Clion 在使用cmake编译 apue.h遇到的问题
- 解决android使用gson解析json字符串,并使用混淆编译方式打包apk遇到的问题
- mini2440交叉编译工具安装及使用过程中可能会遇到的问题及解决办法
- Linux下使用Gradle编译Android工程时遇到的问题及解决方法
- 使用web3.js编译Solidity之遇到的问题