diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-10 08:01:27 +0200 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-10 08:01:27 +0200 |
commit | 579824011d5e8776e2079d6624a39535517760ff (patch) | |
tree | 7addd40affd1e15b5e6c4ea108847ef6a6eef7ea | |
parent | 44208336d80dd63735215ee2cafb3e73fa03f930 (diff) |
update readmes
-rw-r--r-- | readme.md | 37 | ||||
-rw-r--r-- | src/readme.md | 31 |
2 files changed, 60 insertions, 8 deletions
@@ -8,18 +8,45 @@ This repository contains: |`mwe/`|minimal working examples and proof-of-concepts| |`src/crepe/`|game engine source code| |`src/test/`|unit tests| -|`src/example`|standalone examples using game engine| +|`src/example/`|standalone examples using game engine| ## Compilation This repository uses CMake (the makefile in the root of this repository is for -running auxiliary tasks only). Make sure you have initialized and updated the -submodules before compiling. +running auxiliary tasks only). See [src/readme.md](src/readme.md) for detailed +building instructions. + +## Installing libraries + +The expected library (source) versions are included in this repository as git +submodules. Follow these steps for manually building one of the required +libraries from source: + +1. Ensure the git submodules are initialized: + ``` + $ git submodule update --init --recursive --depth 1 + ``` +2. `cd` into the library source folder: + ``` + $ cd lib/googletest + or + $ cd lib/sdl2 + or + $ cd lib/soloud/contrib + ``` +3. Configure the build, run the build and install: + ``` + $ cmake -B build -G Ninja + $ ninja -C build + # ninja -C build install + ``` ## Documentation -API documentation is done using Doxygen. To generate the docs, run `make -doxygen`. +API documentation is done using Doxygen. To generate the docs, run +``` +$ make doxygen +``` ## Code style diff --git a/src/readme.md b/src/readme.md index 1c5d3a2..a4a71e7 100644 --- a/src/readme.md +++ b/src/readme.md @@ -2,7 +2,32 @@ This folder contains the crêpe engine source files, unit tests, and some toy examples. The only target built by default by the CMakeLists.txt in this folder -is the crêpe shared library object. Unit tests can be built by explicitly -specifying the target `test_main` when running the build command. Each source -file in the example/ folder corresponds to a CMake target as well. +is the crêpe shared library object. + +Examples (using Ninja): + +``` +$ cmake -B build -G Ninja +$ ninja -C build +``` + +Unit tests can be built by explicitly specifying the target `test_main` when +running the build command: + +``` +$ ninja -C build test_main +``` + +Each source file in the example/ folder corresponds to a CMake target as well: + +``` +$ ninja -C build audio_internal components_internal +``` + +For installing crêpe system-wide after building (install must be run with +elevated privileges): + +``` +# ninja -C build install +``` |