[gnutls-devel] GnuTLS | Allow statically linking ncrypt (win32) (!1254)
Development of GNU's TLS library
gnutls-devel at lists.gnutls.org
Sun May 24 21:27:37 CEST 2020
Dmitry Baryshkov started a new discussion on configure.ac: https://gitlab.com/gnutls/gnutls/-/merge_requests/1254#note_348028407
> *mingw32* | *mingw64*)
> have_win=yes
> AC_DEFINE([_UNICODE], [1], [Defined to 1 for Unicode (wide chars) APIs])
> + AC_PREPROC_IFELSE([AC_LANG_PROGRAM(
> + [[#include <windows.h>
> + #if defined(_WIN32_WINNT) && _WIN32_WINNT >= 0x0600
> + # error Vista APIs allowed statically
> + #endif
> + ]],[[;]])],[have_vista_dynamic=yes],[have_vista_dynamic=no])
> + AC_ARG_ENABLE(dyn_ncrypt,
> + AS_HELP_STRING([--enable-dyn-ncrypt], [use ncrypt dynamically]),
If I understand you correctly, one must use `DYN_NCRYPT` for WinXP/Win7, but can always use static linking when building for Vista+.
I'd suggest to drop this `AC_ARG_ENABLE` altogether. You can select whether to define `DYN_NCRYPT` depending on the `_WIN32_WINNT`.
Also could you please add a separate testcase to .gitlab-ci.yml till MinGW switches to Vista+ by default?
And last but not least it might be sensible to move `FreeLibrary` calls also under `#ifndef DYN_NCRYPT` calls.
--
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1254#note_348028407
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20200524/3c808326/attachment.html>
More information about the Gnutls-devel
mailing list