c++ - 如何在C++文件中声明标识符JSON?

标签 c++ json macos compiler-errors terminal

我有一个可以在Windows上正确编译的c++项目。
现在,我尝试在Mac上运行它。

我将所有路径更改为Mac路径。
在“make”命令后,我得到此错误信息:

error: use of undeclared identifier 'Json'
Json::Reader reader;

当然,我包含了包含#include <json.h>的头文件

我错过了任何必要的元素吗?

感谢您的任何想法!

最佳答案

json_lib链接错误

重新安装,问题得到解决。

关于c++ - 如何在C++文件中声明标识符JSON?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26753368/

相关文章:

java - 无法在 Mac OS X Mavericks 中正确安装 Eclipse

c++ - 关于float转int

c++ - `substr` 是否使用相同的底层内存?

c++ - 为什么不#include <bits/stdc++。h>?

json - 没有使用 swiftyjson 和 alamofire 在 swift 4 中获取模型类数组值

macos - OSX 上的 sed 中有多个 '-e'

c++ - 在 C++ 中清除空输入缓冲区的安全操作

json - 获取 JSON 返回错误 Uncaught (in promise) SyntaxError : Unexpected token < in JSON at position 0 and status code 304: Not Modified

json - 如何仅使用 mongo-java-driver 执行 MongoDB native 查询(JSON)?

c - 在 OS X 中获取 CPU 时间