. "$GRIMOIRE/FUNCTIONS" &&

config_query_option LDNS_OPTS "Enable ECDSA support?" y \
                              "--enable-ecdsa" \
                              "--disable-ecdsa" &&

config_query_option LDNS_OPTS "Enable SHA256 and SHA512 RRSIG support?" y \
                              "--enable-sha2" \
                              "--disable-sha2" &&

config_query_option LDNS_OPTS "Enable DANE support?" y \
                              "--enable-dane" \
                              "--disable-dane" &&

if spell_ok openssl && is_version_less $(installed_version openssl) 1.0 || spell_ok libressl; then
  message "${MESSAGE_COLOR}WARNING: GOST support requires OpenSSL 1.0, which is not installed. If you need it," &&
  message "select 1.0 below to replace current ${DEFAULT_COLOR}$(installed_version openssl)${MESSAGE_COLOR} version with one from OpenSSL 1.0 branch.${DEFAULT_COLOR}"
fi &&

config_query_list LDNS_OPENSSL "Which OpenSSL branch?" \
                               1.0 \
                               libressl &&

config_query_option LDNS_DRILL "Build and install drill?" n \
                     "--with-drill" "--without-drill" &&

config_query_option LDNS_EXAMPLES "Build and install examples?" n \
                     "--with-examples" "--without-examples"
