nncarlson / yajl-fort

YAJL-Fort: A modern Fortran interface to the YAJL library
MIT License
9 stars 1 forks source link
fortran json yajl

YAJL-Fort: A Modern Fortran Interface to YAJL

The YAJL-Fort package provides a modern object-oriented Fortran interface to the YAJL C library, which is an event-driven parser for JSON data streams. JSON is an open standard data interchange format. It is lightweight, easy for humans to read and write, and language independent.

Note that unlike most other JSON libraries, YAJL does not provide or impose an in-memory data structure representation of the JSON data. That is left to higher-level application code through custom parsing event callback functions.

Also included in YAJL-Fort is a module that defines data structures for representing arbitrary JSON data, and procedures built on the YAJL interface for populating the data structures with JSON data read from a file or string.

Documentation for building and using YAJL-Fort is at ReadTheDocs

Compiler Status

The following compilers are known to work:

The following compilers appear to work now. All tests are passing but the interface has not been extensively exercised in actual applications.

The CMakeLists.txt file has special stanzas for some compilers that set compiler flags and preprocessor macros that are known to be needed. If you are using another compiler it too may need specific compiler flags or macros defined. These can be set on the cmake command line with CMAKE_Fortran_FLAGS or a stanza can be added to the CMakeLists.txt file.