Jsoncpp linux platform compilation and arm porting, jsoncpparm
Jsoncpp
Soncpp is an implementation of a JSON (http://json.org) reader and writer in C ++. JSON (JavaScript Object Notation) is a lightweight data-interchange format. it is easy for humans to read and write. it is easy for machines to parse and generate.
Download
Http://sourceforge.net/projects/jsoncpp/
Or here: http://download.csdn.net/detail/chinaeran/8631141
Compiling on Linux
ExtractRun the following command:
# First install scons $ sudo apt-get install scons $ scons platform = linux-gcc
Target path:
Dynamic library:./libs/linux-gcc-4.8/libjson_linux-gcc-4.8_libmt.so
Static Library:./libs/linux-gcc-4.8/libjson_linux-gcc-4.8_libmt.a
Arm platform Compilation
Note:Platform does not contain the arm platform, similar to linux-gcc. Therefore, the source code is extracted and compiled independently.
ExtractRun the following command:
$ Mkdir arm_jsoncpp $ cp include/arm_jsoncpp/-r$ cp src/lib_json/* arm_jsoncpp/$ cd arm_jsoncpp/# compile the static library $ arm-linux-gnueabihf-g ++-c *. cpp-I. /include-fPIC $ ar cr libjsoncpp. a *. o # compile the dynamic library $ arm-linux-gnueabihf-g ++-shared-fPIC *. cpp-I. /include-o libjsoncpp. so
Target path:
Dynamic library:./arm_jsoncpp/libjsoncpp. so
Static Library:./arm_jsoncpp/libjsoncpp.