Skip to content

Commit da6aac9

Browse files
mostlygeekslaren
andauthored
Add docs for creating a static build (#10268) (#10630)
* Add notes for a static build * Update docs/build.md --------- Co-authored-by: Diego Devesa <[email protected]>
1 parent 01e6d9b commit da6aac9

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

docs/build.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ cmake --build build --config Release
3939
```
4040

4141
For more details and a list of supported generators, see the [CMake documentation](https://cmake.org/cmake/help/latest/manual/cmake-generators.7.html).
42+
- For static builds, add `-DBUILD_SHARED_LIBS=OFF`:
43+
```
44+
cmake -B build -DBUILD_SHARED_LIBS=OFF
45+
cmake --build build --config Release
46+
```
4247
4348
- Building for Windows (x86, x64 and arm64) with MSVC or clang as compilers:
4449
- Install Visual Studio 2022, e.g. via the [Community Edition](https://visualstudio.microsoft.com/de/vs/community/). In the installer, select at least the following options (this also automatically installs the required additional tools like CMake,...):

0 commit comments

Comments
 (0)