]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
Add docs for creating a static build (#10268) (#10630)
authorBenson Wong <redacted>
Wed, 4 Dec 2024 00:40:36 +0000 (16:40 -0800)
committerGitHub <redacted>
Wed, 4 Dec 2024 00:40:36 +0000 (01:40 +0100)
* Add notes for a static build

* Update docs/build.md

---------

Co-authored-by: Diego Devesa <redacted>
docs/build.md

index 97e340ab62acc89d68e76a3eaa62b90a0c69fa1b..a4964cbd1490912527649bb883f73ae7dd144a37 100644 (file)
@@ -39,6 +39,11 @@ cmake --build build --config Release
        ```
 
     For more details and a list of supported generators, see the [CMake documentation](https://cmake.org/cmake/help/latest/manual/cmake-generators.7.html).
+- For static builds, add `-DBUILD_SHARED_LIBS=OFF`:
+  ```
+  cmake -B build -DBUILD_SHARED_LIBS=OFF
+  cmake --build build --config Release
+  ```
 
 - Building for Windows (x86, x64 and arm64) with MSVC or clang as compilers:
     - 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,...):