From d9d94a9969785abbb3e04b2b9f75f1049c7b8936 Mon Sep 17 00:00:00 2001 From: Elliott Jin Date: Fri, 25 Mar 2022 07:09:36 -0700 Subject: [PATCH 1/2] doc: mention optional modules in README --- README.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e347889c84..f5db915e83 100644 --- a/README.md +++ b/README.md @@ -68,12 +68,15 @@ libsecp256k1 is built using autotools: $ make check # run the test suite $ sudo make install # optional +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. + Usage examples ----------- Usage examples can be found in the [examples](examples) directory. To compile them you need to configure with `--enable-examples`. * [ECDSA example](examples/ecdsa.c) - * [Schnorr Signatures example](examples/schnorr.c) - * [Deriving a shared secret(ECDH) example](examples/ecdh.c) + * [Schnorr signatures example](examples/schnorr.c) + * [Deriving a shared secret (ECDH) example](examples/ecdh.c) + To compile the Schnorr signature and ECDH examples, you also need to configure with `--enable-module-schnorrsig` and `--enable-module-ecdh`. Test coverage ----------- From 55512d30b7921bc46247a78be1da98108f243c1c Mon Sep 17 00:00:00 2001 From: Elliott Jin Date: Fri, 25 Mar 2022 07:13:08 -0700 Subject: [PATCH 2/2] doc: clean up module help text in configure.ac --- configure.ac | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index a7460bca9a..2db59a8ff3 100644 --- a/configure.ac +++ b/configure.ac @@ -141,7 +141,7 @@ AC_ARG_ENABLE(examples, [SECP_SET_DEFAULT([enable_examples], [no], [yes])]) AC_ARG_ENABLE(module_ecdh, - AS_HELP_STRING([--enable-module-ecdh],[enable ECDH shared secret computation]), [], + AS_HELP_STRING([--enable-module-ecdh],[enable ECDH module [default=no]]), [], [SECP_SET_DEFAULT([enable_module_ecdh], [no], [yes])]) AC_ARG_ENABLE(module_recovery, @@ -149,11 +149,11 @@ AC_ARG_ENABLE(module_recovery, [SECP_SET_DEFAULT([enable_module_recovery], [no], [yes])]) AC_ARG_ENABLE(module_extrakeys, - AS_HELP_STRING([--enable-module-extrakeys],[enable extrakeys module]), [], + AS_HELP_STRING([--enable-module-extrakeys],[enable extrakeys module [default=no]]), [], [SECP_SET_DEFAULT([enable_module_extrakeys], [no], [yes])]) AC_ARG_ENABLE(module_schnorrsig, - AS_HELP_STRING([--enable-module-schnorrsig],[enable schnorrsig module]), [], + AS_HELP_STRING([--enable-module-schnorrsig],[enable schnorrsig module [default=no]]), [], [SECP_SET_DEFAULT([enable_module_schnorrsig], [no], [yes])]) AC_ARG_ENABLE(external_default_callbacks,