@@ -141,6 +141,11 @@ AC_ARG_ENABLE(module_extrakeys,
141141 [ enable_module_extrakeys=$enableval] ,
142142 [ enable_module_extrakeys=no] )
143143
144+ AC_ARG_ENABLE ( module_schnorrsig ,
145+ AS_HELP_STRING ( [ --enable-module-schnorrsig] ,[ enable schnorrsig module (experimental)] ) ,
146+ [ enable_module_schnorrsig=$enableval] ,
147+ [ enable_module_schnorrsig=no] )
148+
144149AC_ARG_ENABLE ( external_default_callbacks ,
145150 AS_HELP_STRING ( [ --enable-external-default-callbacks] ,[ enable external default callback functions [ default=no] ] ) ,
146151 [ use_external_default_callbacks=$enableval] ,
@@ -426,6 +431,13 @@ if test x"$enable_module_recovery" = x"yes"; then
426431 AC_DEFINE ( ENABLE_MODULE_RECOVERY , 1 , [ Define this symbol to enable the ECDSA pubkey recovery module] )
427432fi
428433
434+ if test x"$enable_module_schnorrsig" = x"yes"; then
435+ AC_DEFINE ( ENABLE_MODULE_SCHNORRSIG , 1 , [ Define this symbol to enable the schnorrsig module] )
436+ enable_module_extrakeys=yes
437+ fi
438+
439+ # Test if extrakeys is set after the schnorrsig module to allow the schnorrsig
440+ # module to set enable_module_extrakeys=yes
429441if test x"$enable_module_extrakeys" = x"yes"; then
430442 AC_DEFINE ( ENABLE_MODULE_EXTRAKEYS , 1 , [ Define this symbol to enable the extrakeys module] )
431443fi
@@ -444,6 +456,7 @@ if test x"$enable_experimental" = x"yes"; then
444456 AC_MSG_NOTICE ( [ Experimental features do not have stable APIs or properties, and may not be safe for production use.] )
445457 AC_MSG_NOTICE ( [ Building ECDH module: $enable_module_ecdh] )
446458 AC_MSG_NOTICE ( [ Building extrakeys module: $enable_module_extrakeys] )
459+ AC_MSG_NOTICE ( [ Building schnorrsig module: $enable_module_schnorrsig] )
447460 AC_MSG_NOTICE ( [ ******] )
448461else
449462 if test x"$enable_module_ecdh" = x"yes"; then
452465 if test x"$enable_module_extrakeys" = x"yes"; then
453466 AC_MSG_ERROR ( [ extrakeys module is experimental. Use --enable-experimental to allow.] )
454467 fi
468+ if test x"$enable_module_schnorrsig" = x"yes"; then
469+ AC_MSG_ERROR ( [ schnorrsig module is experimental. Use --enable-experimental to allow.] )
470+ fi
455471 if test x"$set_asm" = x"arm"; then
456472 AC_MSG_ERROR ( [ ARM assembly optimization is experimental. Use --enable-experimental to allow.] )
457473 fi
@@ -469,8 +485,9 @@ AM_CONDITIONAL([USE_EXHAUSTIVE_TESTS], [test x"$use_exhaustive_tests" != x"no"])
469485AM_CONDITIONAL([ USE_BENCHMARK] , [ test x"$use_benchmark" = x"yes"] )
470486AM_CONDITIONAL([ USE_ECMULT_STATIC_PRECOMPUTATION] , [ test x"$set_precomp" = x"yes"] )
471487AM_CONDITIONAL([ ENABLE_MODULE_ECDH] , [ test x"$enable_module_ecdh" = x"yes"] )
472- AM_CONDITIONAL([ ENABLE_MODULE_EXTRAKEYS] , [ test x"$enable_module_extrakeys" = x"yes"] )
473488AM_CONDITIONAL([ ENABLE_MODULE_RECOVERY] , [ test x"$enable_module_recovery" = x"yes"] )
489+ AM_CONDITIONAL([ ENABLE_MODULE_EXTRAKEYS] , [ test x"$enable_module_extrakeys" = x"yes"] )
490+ AM_CONDITIONAL([ ENABLE_MODULE_SCHNORRSIG] , [ test x"$enable_module_schnorrsig" = x"yes"] )
474491AM_CONDITIONAL([ USE_EXTERNAL_ASM] , [ test x"$use_external_asm" = x"yes"] )
475492AM_CONDITIONAL([ USE_ASM_ARM] , [ test x"$set_asm" = x"arm"] )
476493
@@ -491,6 +508,7 @@ echo " with coverage = $enable_coverage"
491508echo " module ecdh = $enable_module_ecdh"
492509echo " module recovery = $enable_module_recovery"
493510echo " module extrakeys = $enable_module_extrakeys"
511+ echo " module schnorrsig = $enable_module_schnorrsig"
494512echo
495513echo " asm = $set_asm"
496514echo " bignum = $set_bignum"
0 commit comments