简体   繁体   English

命名空间'std'中没有名为'vsnprintf'的成员; 你是说'vsprintf'吗?

[英]No member named 'vsnprintf' in namespace 'std'; did you mean 'vsprintf'?

I am trying to compile boost under iOS, but every time I try to launch my project errors occurs like this: 我正在尝试在iOS下编译boost,但每次我尝试启动我的项目错误都会发生如下:

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk/usr/include/c++/4.2.1/bits/c++locale.h:79:28: No member named 'vsnprintf' in namespace 'std'; did you mean 'vsprintf'?
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk/usr/include/c++/4.2.1/bits/c++locale.h:79:60: Too many arguments to function call, expected 3, have 4

I think that the main reason is compiler, I try to change some settings and play with compiler but every time new errors occurs, so here are my current settings for compiler, 我认为主要原因是编译器,我尝试更改一些设置并使用编译器但每次出现新错误时,所以这里是我当前的编译器设置,

  1. C Language Dialector - C99[-std=c99] C语言指南 - C99 [-std = c99]
  2. C++ Language Dialector - C++98[-std=C++98] C ++语言指南 - C ++ 98 [-std = C ++ 98]
  3. C++ Standard library - libstdc++ C ++标准库 - libstdc ++

Boost version is 1.44.0, XCode version is 4.5 Boost版本为1.44.0,XCode版本为4.5

Anybody knows how I must configurate my project to compile boost under iOS ? 有谁知道我必须如何配置我的项目来编译iOS下的提升?

根据vsnprintf()这个参考页面,它是在C ++ 11中引入的,所以代替-std=C++98 try -std=C++0x (但是,编译器可能不支持C +中引入的所有功能) +11)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 错误:命名空间“std”中没有名为“enable_if_t”的模板; 您指的是 'enable_if' 吗? - error: no template named 'enable_if_t' in namespace 'std'; did you mean 'enable_if'? STL映射错误:命名空间'std'中没有名为'map'的模板; 你是说'max'吗? - STL map error: no template named 'map' in namespace 'std'; did you mean 'max'? 错误:命名空间“std”中没有名为“is_same_v”的模板; 您指的是 'is_same' 吗? - error: no template named 'is_same_v' in namespace 'std'; did you mean 'is_same'? 错误:“排序”不是“std::ranges”的成员; 你的意思是'std :: sort'吗? - error: 'sort' is not a member of 'std::ranges'; did you mean 'std::sort'? 在名称空间std中没有名为stoi的成员 - No Member named stoi in namespace std 命名空间“std”中没有名为“begin”的成员 - No member named 'begin' in namespace 'std' 命名空间'std'中没有名为'size'的成员 - No member named 'size' in namespace 'std' 名称空间“ std”中没有名为“ forward”的成员 - No member named 'forward' in namespace 'std' 错误:名称空间“ std”中没有名为“ stod”的成员 - Error: no member named 'stod' in namespace 'std' std错误名称空间中没有名为“ bind”的成员 - No member named 'bind" in the namespace of std error
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM