error LNK2001: unresolved external symbol "int g_cTemplates" (?g_cTemplates@@3HA)(转)
原文转自:http://blog.sina.com.cn/s/blog_639a2ad70101kpen.html
编译directshow若干问题的解决
use vs2005 compiler directshow baseclasses has something error
1.ctlutil.h
modify as below:
//operator=(LONG);
COARefTime& operator=(LONG);
2.winutil.cpp
modify as below:
UINT Count;
for (Count = 0;Count < Result;Count++) {
3.outputq.cpp
modify as below:
long iDone;
for (iDone = 0;
4.wxdebug.cpp
modify as below:
//static g_dwLastRefresh = 0;
static DWORD g_dwLastRefresh = 0;
如果編譯程式出現
error LNK2019: 無法解析的外部符號 "int __stdcall lstrcmpWInternal
error LNK2019: 無法解析的外部符號 "int __cdecl wsprintfWInternal
error LNK2019: 無法解析的外部符號 "int __stdcall lstrcmpiWInternal
之類的錯誤
這是baseclasses編譯時有個設定要變更
就是project屬性->組態屬性->C/C++->語言之下的 "將wchar_t當作Built-in型別" 設為false
就可以解決上述link error的問題
如果編譯程式link strmbase.lib or strmbasd.lib出現以下的error
strmbasd.lib(dllentry.obj) : error LNK2001: unresolved external symbol "class CFactoryTemplate * g_Templates" (?g_Templates@@3PAVCFactoryTemplate@@A)strmbasd.lib(dllsetup.obj) : error LNK2001: unresolved external symbol "int g_cTemplates" (?g_cTemplates@@3HA)
则重新修改baseclasses project的内容
CFactoryTemplate g_Templates[1] = {
{ L"SystemClock", &CLSID_SystemClock, CSystemClock::CreateInstance} //修改后;
// {&CLSID_SystemClock, CSystemClock::CreateInstance} //原本的;
};
另外在baseclasses工程的 vc Project->Settings...->C/C++的 preprocessor definitions:加入FILTER_DLL
然后重新编译 strmbase.lib and strmbasd.lib 即可
error LNK2001: unresolved external symbol "int g_cTemplates" (?g_cTemplates@@3HA)(转)的更多相关文章
- 混合编程:error LNK2001: unresolved external symbol
Vs2006+matlab2010rb环境: 1:工具-选项-项目解决方案-VC++目录设置include和lib的路径 2:项目-属性-属性配置-链接器-输入-附加依赖项把库的名字添加进去 VIST ...
- VC++ : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall std::basic_string<wchar_t,struct std::char_traits<wchar_t>
最近学习Google Breakpad,将其用在了自己的项目中,编译的版本为VS2010,没有什么问题.但是为了和之前的程序兼容,需要使用VS2008版本的程序,于是又编译了VS2008版本的代码,但 ...
- [异常] VC6.0 error LNK2001: unresolved external symbol _main解决办法
来自:http://www.douban.com/note/65638800/ 学习VC++时经常会遇到链接错误LNK2001,该错误非常讨厌,因为对于编程者来说,最好改的错误莫过于编译错误,而一般说 ...
- VC6.0 error LNK2001: unresolved external symbol _main解决办法
学习VC++时经常会遇到链接错误LNK2001,该错误非常讨厌,因为对于编程者来说,最好改的错误莫过于编译错误,而一般说来发生连接错误时,编译都已通过.产生连接错误的原因非常多,尤其LNK2001错误 ...
- (转载)浅析error LNK2001: unresolved external symbol "public: __thisc...
学习VC++时经常会遇到链接错误LNK2001,该错误非常讨厌,因为对于 编程者来说,最好改的错误莫过于编译错误,而一般说来发生连接错误时, 编译都已通过.产生连接错误的原因非常多 ...
- MASMPlus编译出错:error LNK2001: unresolved external symbol _WinMainCRTStartup
初学汇编,感觉很多不懂.不过那也是,如果懂了的话就不用学了,从无到有学习一门编程语言果然不是那么容易的一件事. 学习汇编总得要有一款汇编软件才行,没理由只是使用Windows自带的DEBUG.于是上了 ...
- error LNK2001: unresolved external symbol _main
想运行一个网上下载的opengl离屏渲染(渲染到纹理FBO)的程序,然后一直报错 error LNK2001: unresolved external symbol _main 解决了一下午终于弄明白 ...
- VC6.0 error LNK2001: unresolved external symbol __imp__ntohl@4
--------------------Configuration: oxToint1 - Win32 Debug-------------------- Linking... main.obj : ...
- error LNK2001: unresolved external symbol @__security_check_cookie
Q:VS2005编译的静态库, 在vc++6.0中连接出现错误 error LNK2001: unresolved external symbol @__security_check_cookie@l ...
随机推荐
- PHP.18-图片等比例缩放
图片等比例缩放 自定义函数ImageUpdateSize($pricname, $maxx, $maxy, $pre) 1.$pricname:被缩放的图片源(路径):2.$maxx,$maxy:缩放 ...
- 1 web应用
web应用 Web应用程序是一种可以通过Web访问的应用程序,程序的最大好处是用户很容易访问应用程序,用户只需要有浏览器即可,不需要再安装其他软件.应用程序有两种模式C/S.B/S.C/S是客户端/服 ...
- 15.2,redis发布订阅
发布publish 订阅subscribe Redis 通过 PUBLISH . SUBSCRIBE 等命令实现了订阅与发布模式. 举例1: qq群的公告,单个发布者,多个收听者 发布/订阅 实验 发 ...
- WPF制作的小时钟
原文:WPF制作的小时钟 周末无事, 看到WEB QQ上的小时钟挺可爱的, 于是寻思着用WPF模仿着做一个. 先看下WEB QQ的图: 打开VS, 开始动工. 建立好项目后, 面对一个空荡荡的页面, ...
- 用swoole实现nginx日志解析
1.原技术路线解析 在nging配置中将日志信息交给syslog处理,rsyslog配置中将数据传递给了514端口解析,然后将解析好的数据传入elasticsearch中. nginx配置 serve ...
- 更新域名解析以后,IP在cmd中ping不正确,清理DNS缓存
1清除ARP缓存,cmd下使用命令arp -d*代替执行. 2清除NETBT,cmd下使用命令nbtstat -R代替执行. 再清除DNS缓存,cmd下使用命令ipconfig /flushdns代替 ...
- [转]赵桐正thinkphp教程笔记
原文:赵桐正thinkphp教程笔记 ,有修改 常用配置 常用配置config.php: <?php return array( //'配置项'=>'配置值' 'URL_PATHINFO_ ...
- Kotlin的数据类:节省很多行代码(KAD 10)
作者:Antonio Leiva 时间:Jan 25, 2017 原文链接:https://antonioleiva.com/data-classes-kotlin/ 在前面的文章中,我们已经见到了类 ...
- linux path环境变量基础
系统环境变量与个人环境变量的配置文件 系统级别的配置文件: /etc/profile :这个文件预设了几个重要的变量,例如PATH, USER, LOGNAME, MAIL, INPUTRC, HO ...
- Python全栈工程师(exercises)
# # 练习: # # 1. 用map函数求: # # 1**3 + 2**3 + 3 ** 3 + .... 9**3 的和 def add_(x): return x ** 3 print(sum ...