added README to examples and improved database version check when used from Sourcetrail

This commit is contained in:
Eberhard Graether
2018-12-18 10:48:43 +01:00
parent f4cf5f171a
commit aa85d20e73
13 changed files with 190 additions and 140 deletions
+24
View File
@@ -0,0 +1,24 @@
## C++ API Example
### Requirements
* CMake
* C++ Compiler
### Building
* Run cmake with `BUILD_EXAMPLES=ON`
* Build target `cpp_api_example`
### Running from Command Line
Invoke binary located in the build directory:
```
$ cpp_api_example path/to/database_file.srctrldb path/to/examples/cpp_api_example/data/example.cpp
```
### Running with Sourcetrail
Open `cpp_api_example.srctrlprj` located in the build directory with Sourcetrail and index the project.