Skip to content

SMUCSE2341/filesystemAndJSON

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example RapidJSON and Filesystem

The program expects one command line arg: a path to a folder that contains files.

A few things to notice:

  • the cMakeLists.txt file includes a few new statements:

    • file (COPY ...) - this copies the rapidjson folder from the src directory into the build directory.
    • include_directories(rapidjson) - this makes the files in the rapidjson directory act like files on the system include path. This means you can include them with <> and not "".
    • set (CMAKE_CXX_STANDARD_LIBRARIES -lstdc++fs) - this tells the linker to link against the file system library.
  • The main.cpp includes #include <experimental/filesystem>. In C++ 14, the filesystem lib is part of an experimental set of features. It isn't taken out of experimental until C++ 17. But the version of gcc that we are using isn't fully C++17 compliant.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published