Subject: bug#25061: consider adding %COMPAT to default gnutls priority string

From: Eli Zaretskii <[email-masked]>
Date: Wed, 20 Dec 2017 18:19:10 +0200

> From: Andy Moreton <[email-masked]>
> Date: Wed, 20 Dec 2017 12:54:45 +0000
> 
> diff --git a/src/gnutls.c b/src/gnutls.c
> index 8db201ae83..f2b078d964 100644
> --- a/src/gnutls.c
> +++ b/src/gnutls.c
> @@ -238,6 +238,7 @@ DEF_DLL_FN (int, gnutls_hash, (gnutls_hash_hd_t, const void *, size_t));
>  DEF_DLL_FN (void, gnutls_hash_deinit, (gnutls_hash_hd_t, void *));
>  DEF_DLL_FN (void, gnutls_hash_output, (gnutls_hash_hd_t, void *));
>  #  endif        /* HAVE_GNUTLS3 */
> +DEF_DLL_FN (const char *, gnutls_ext_get_name, (unsigned int));
> 
> 
>  static bool
> @@ -357,6 +358,7 @@ init_gnutls_functions (void)
>    LOAD_DLL_FN (library, gnutls_hash_deinit);
>    LOAD_DLL_FN (library, gnutls_hash_output);
>  #  endif        /* HAVE_GNUTLS3 */
> +  LOAD_DLL_FN (library, gnutls_ext_get_name);
> 
>    max_log_level = global_gnutls_log_level;
> 
> @@ -470,6 +472,8 @@ init_gnutls_functions (void)
>  #  define gnutls_hash_deinit fn_gnutls_hash_deinit
>  #  define gnutls_hash_output fn_gnutls_hash_output
>  #  endif        /* HAVE_GNUTLS3 */
> +#  define gnutls_ext_get_name fn_gnutls_ext_get_name

Thanks, but this means Emacs will now refuse to load GnuTLS on systems
that have version 3.4 or older of the library, right?  If so, I think
the loading and the use of the function should be conditioned by an
appropriate preprocessor directive to compile that code only for
3.5.X.