Fix, clarify build instructions

If we're in a build subdirectory, we need `..` to tell cmake where to
find the source directory.
This commit is contained in:
Roy Stogner 2021-12-01 17:38:23 -06:00
parent cbc025a649
commit 4fd0287f04

View File

@ -38,28 +38,32 @@ Testbed:
Build the library Build the library
----------------- -----------------
With the ninja build system installed:
``` ```
mkdir build && cd build mkdir build && cd build
cmake -GNinja cmake -GNinja ..
cmake --build . cmake --build .
``` ```
Build and run the unit tests Build and run with unit tests
---------------------------- ----------------------------
With the ninja build system:
``` ```
mkdir build && cd build mkdir build && cd build
cmake -GNinja -DP2T_BUILD_TESTS=ON cmake -GNinja -DP2T_BUILD_TESTS=ON ..
cmake --build . cmake --build .
ctest --output-on-failure ctest --output-on-failure
``` ```
Build the testbed Build with the testbed
----------------- -----------------
``` ```
mkdir build && cd build mkdir build && cd build
cmake -GNinja -DP2T_BUILD_TESTBED=ON cmake -GNinja -DP2T_BUILD_TESTBED=ON ..
cmake --build . cmake --build .
``` ```