Skip to content

Commit

Permalink
Windows: Add CRYPT32.LIB to the libraries to link you app with
Browse files Browse the repository at this point in the history
Reviewed-by: Matt Caswell <[email protected]>
(Merged from openssl#1063)
  • Loading branch information
levitte committed May 16, 2016
1 parent 6385ffd commit 531e9dc
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions NOTES.WIN
Original file line number Diff line number Diff line change
Expand Up @@ -105,18 +105,18 @@
This section applies to non-Cygwin builds.

If you link with static OpenSSL libraries then you're expected to
additionally link your application with WS2_32.LIB, ADVAPI32.LIB,
GDI32.LIB and USER32.LIB. Those developing non-interactive service
applications might feel concerned about linking with the latter two,
as they are justly associated with interactive desktop, which is not
available to service processes. The toolkit is designed to detect in
which context it's currently executed, GUI, console app or service,
and act accordingly, namely whether or not to actually make GUI calls.
Additionally those who wish to /DELAYLOAD:GDI32.DLL and /DELAYLOAD:USER32.DLL
and actually keep them off service process should consider
implementing and exporting from .exe image in question own
_OPENSSL_isservice not relying on USER32.DLL.
E.g., on Windows Vista and later you could:
additionally link your application with WS2_32.LIB, GDI32.LIB,
ADVAPI32.LIB, CRYPT32.LIB and USER32.LIB. Those developing
non-interactive service applications might feel concerned about
linking with GDI32.LIB and USER32.LIB, as they are justly associated
with interactive desktop, which is not available to service
processes. The toolkit is designed to detect in which context it's
currently executed, GUI, console app or service, and act accordingly,
namely whether or not to actually make GUI calls. Additionally those
who wish to /DELAYLOAD:GDI32.DLL and /DELAYLOAD:USER32.DLL and
actually keep them off service process should consider implementing
and exporting from .exe image in question own _OPENSSL_isservice not
relying on USER32.DLL. E.g., on Windows Vista and later you could:

__declspec(dllexport) __cdecl BOOL _OPENSSL_isservice(void)
{ DWORD sess;
Expand Down

0 comments on commit 531e9dc

Please sign in to comment.