You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+37
Original file line number
Diff line number
Diff line change
@@ -29,6 +29,43 @@ Building with Autotools
29
29
30
30
To compile optional modules (such as Schnorr signatures), you need to run `./configure` with additional flags (such as `--enable-module-schnorrsig`). Run `./configure --help` to see the full list of available flags. For experimental modules, you will also need `--enable-experimental` as well as a flag for each individual module, e.g. `--enable-module-musig`.
31
31
32
+
Building with CMake (experimental)
33
+
----------------------------------
34
+
35
+
To maintain a pristine source tree, CMake encourages to perform an out-of-source build by using a separate dedicated build tree.
To compile optional modules (such as Schnorr signatures), you need to run `cmake` with additional flags (such as `-DSECP256K1_ENABLE_MODULE_SCHNORRSIG=ON`). Run `cmake .. -LH` to see the full list of available flags.
46
+
47
+
### Cross compiling
48
+
49
+
To alleviate issues with cross compiling, preconfigured toolchain files are available in the `cmake` directory.
To cross compile for Android with [NDK](https://developer.android.com/ndk/guides/cmake) (using NDK's toolchain file, and assuming the `ANDROID_NDK_ROOT` environment variable has been set):
To build on Windows with Visual Studio, a proper [generator](https://cmake.org/cmake/help/latest/manual/cmake-generators.7.html#visual-studio-generators) must be specified for a new build tree.
61
+
62
+
The following example assumes using of Visual Studio 2022 and CMake v3.21+.
63
+
64
+
In "Developer Command Prompt for VS 2022":
65
+
66
+
>cmake -G "Visual Studio 17 2022" -A x64 -S . -B build
0 commit comments