本文主要是介绍rapidjson的移植,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
因为rapidjson是只有头文件 使用模板来实现json 所以只需要添加头文件就行 make使用-I/路径指定头文件 解压后编写makefile
下载地址
https://github.com/Tencent/rapidjson
https://github.com/Tencent/rapidjson/releases/tag/v1.1.0
下载了版本
rapidjson-1.1.0.zip
使用方法 解压
RapidJSON is a header-only C++ library. Just copy the include/rapidjson folder to system or project's include path.(仅仅拷贝头文件就可以用,不要过多的编译)
执行命令
unzip rapidjson-1.1.0.zip
root@ubuntu:~/share/gateway/app/openlib/rapidjson-1.1.0# cp include/rapidjson /root/share/nuvoton_cross/host/usr/arm-nuvoton-linux-gnueabi/sysroot/usr/include/ -arf
root@ubuntu:~/share/gateway/app/openlib/rapidjson-1.1.0# cd /root/share/nuvoton_cross/host/usr/arm-nuvoton-linux-gnueabi/sysroot/usr/include
root@ubuntu:~/share/nuvoton_cross/host/usr/arm-nuvoton-linux-gnueabi/sysroot/usr/include#
root@ubuntu:~/share/nuvoton_cross/host/usr/arm-nuvoton-linux-gnueabi/sysroot/usr/include#
root@ubuntu:~/share/nuvoton_cross/host/usr/arm-nuvoton-linux-gnueabi/sysroot/usr/include# tree rapidjson/
rapidjson/
├── allocators.h
├── document.h
├── encodedstream.h
├── encodings.h
├── error
│ ├── en.h
│ └── error.h
├── filereadstream.h
├── filewritestream.h
├── fwd.h
├── internal
│ ├── biginteger.h
│ ├── diyfp.h
│ ├── dtoa.h
│ ├── ieee754.h
│ ├── itoa.h
│ ├── meta.h
│ ├── pow10.h
│ ├── regex.h
│ ├── stack.h
│ ├── strfunc.h
│ ├── strtod.h
│ └── swap.h
├── istreamwrapper.h
├── memorybuffer.h
├── memorystream.h
├── msinttypes
│ ├── inttypes.h
│ └── stdint.h
├── ostreamwrapper.h
├── pointer.h
├── prettywriter.h
├── rapidjson.h
├── reader.h
├── schema.h
├── stream.h
├── stringbuffer.h
└── writer.h
3 directories, 35 files
这篇关于rapidjson的移植的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!