Starting from scratch
Last updated
Was this helpful?
Last updated
Was this helpful?
The Vertices SDK is built to be included in any project as an external component.
The best way to achieve this is probably to make use of .
So let's say we have a clean repository with empty directories:
external
: I like to have a directory keeping external libs
components
: provided by the SDK you are building on
myproject
: the source code your team is writing
utils
: some scripts and tools that are useful
build
: generated build files
The structure is alive. Let's get the SDK.
Let's create a main.c
file with the minimum content:
We can now init our project with two CMake files that will be used to build the entire project:
Here is the minimum content of the root CMakeLists.txt
:
Now we can add our main.c
file into myproject/CMakeLists.txt
:
Before we can start including headers from the Vertices SDK, we need to add the library into myproject
:
At the end of myproject/CMakeLists.txt
, append that line:
Now you can include the Vertices header in the main file:
There are still some missing parts that will be covered in the next chapters.