cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: Patches to winbuild for support of c-ares and OpenSSL debug

From: Steve Holme <steve_holme_at_hotmail.com>
Date: Tue, 30 Dec 2014 20:14:25 +0000

On Tue, 30 Dec 2014, Sam wrote:

> > What version of OpenSSL are you using and what commands
> > did you use to build OpenSSL?
>
> I am using OpenSSL 1.01j. I actually did not build it, but rather took
> the lazy shortcut and downloaded binaries from
> http://www.npcglib.org/~stathis/blog/precompiled-openssl/
>
> I've just noticed, reading through the notes there, that the fellow
> doing the building states: "The main difference from the official release
> is that I patch the sources to allow compiling libraries with filenames that
> reflect the compile configuration, which makes it easier to use later."
>
> I would read that to mean that his library names might be non-standard,
> so perhaps this patch is not suitable for general use.

Ah Yes...

Unfortunately the OpenSSL build system isn't great for side-by-side builds under Windows either debug and release or different versions of Visual Studio etc...

> Though there still exists the issue on Windows that you must build a project
> with consistent linkage against the same versions of the CRT, or you will get
> errors/warnings. That is what led me to set up linking against the debug
> versions of OpenSSL in the first place.

Kind of...

If you are building a debug version of libcurl, you can link against the release version of OpenSSL. The only thing you won't be able to do is debug the OpenSSL functions.

I don't think you can mix /MD and /MT builds - but I only use the "out of the box" version of OpenSSL and assume it uses /MD (dynamic CRT) even for the static builds as I don't run into any issues with our Visual Studio project file based builds where we only support the dynamic CRT at present (/MD and /MDd). Note: In these project files we support the following configurations which may be of interest to you rather than using the makefiles:

* A static version of libcurl that links against the static version of OpenSSL
* A static version of libcurl that links against the DLL version of OpenSSL
* A DLL version of libcurl that links against the DLL version of OpenSSL

If memory serves me correctly, you couldn't mix the threading models, but I've not used the single threaded libraries for years - are they still available?

Kind Regards

Steve

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2014-12-30