swprintf 和 vswprintf 未声明?
我尝试使用 MinGW 在 Windows 上编译 Botan,但在编译过程中收到以下错误:
c:\qt\2010.04\mingw\bin\../lib/gcc/mingw32/4.4.0/include/c++/cwchar:159: error:
'::swprintf' has not been declared
c:\qt\2010.04\mingw\bin\../lib/gcc/mingw32/4.4.0/include/c++/cwchar:166: error:
'::vswprintf' has not been declared
Why are swprintf and vswprintf not statements, and how can I fix this?
I am trying to compile Botan on Windows with MinGW, and am receiving the following error during compilation:
c:\qt\2010.04\mingw\bin\../lib/gcc/mingw32/4.4.0/include/c++/cwchar:159: error:
'::swprintf' has not been declared
c:\qt\2010.04\mingw\bin\../lib/gcc/mingw32/4.4.0/include/c++/cwchar:166: error:
'::vswprintf' has not been declared
Why are swprintf and vswprintf not declared, and how can I fix this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
放入
尝试在包含 stdio.h 之前
Try putting in
before including stdio.h
使用 MinGW (Qt 2010.05) 编译 Grantlee 时遇到同样的问题。
我如何编译它:
注释掉以下几行(大约第 160 行)< /p>
使用::swprintf;
using ::vswprintf;
使用
had the same problem compiling Grantlee using MinGW (Qt 2010.05).
How I got it to compile:
comment the following lines out (around line 160)
using ::swprintf;
using ::vswprintf;
运行时请确保未设置 -ansi 标志。如果正在使用此标志,请将其删除,问题将得到解决。
When running make ensure that -ansi flag is not set. If this flag is being used then remove it and the problem will be solved.