Creating cURL & libcurl with Visual Studio 2010

Using question # 197444, I was able to create cURL and libcurl from a source on Windows from the Visual Studio 2010 IDE, OpenSSL 1.0.0, and zlib 1.2.5. The problem that I see is that at the moment, if I run the resulting curl.exe with the -V argument, then the version it reports is

 curl 7.20.1 (i386-pc-win32) libcurl/7.20.1 OpenSSL/0.9.8d zlib/1.2.3 Protocols: dict file ftp ftps http https imap imaps ldap pop3 pop3s rtsp smtp smtps telnet tftp Features: AsynchDNS Largefile NTLM SSL libz 

Please note that the versions reported for both OpenSSL and zlib do not match what I actually used. Any idea on how to fix this?

ps Is there a clear list of additional components that can be compiled into libcurl and what options / preprocessor directive to use? (e.g. SSPI, libidn, ...?)

+4
source share
2 answers

I quickly looked into the curl source code and got these version numbers dynamically from the DLL, and not from any static sources. Thus, these are versions of libraries that are actually loaded into the curl process, not the versions of libraries that were used to create the curl source. You probably have older versions of these libraries on your system that are loaded by the curl process.

+2
source

I am creating cURL and libcurl from the command line with this batch file

 @echo off rem assumes OpenSSL at ../../openssl-1.0.0a rem assumes zlib at ./../zlib-1.2.5 and built with static runtime libraries (/MT) echo "Add '#define HAVE_LDAP_SSL 1' to lib\config-win32.h" notepad lib\config-win32.h pause cd lib nmake -f Makefile.vc9 clean nmake -f Makefile.vc9 OPENSSL_PATH=../../openssl-1.0.0a ZLIB_PATH=../../zlib-1.2.5 RTLIBCFG=static CFG=release-ssl-zlib cd .. cd src nmake -f Makefile.vc9 clean nmake -f Makefile.vc9 OPENSSL_PATH=../../openssl-1.0.0a ZLIB_PATH=../../zlib-1.2.5 RTLIBCFG=static CFG=release-ssl-zlib 

And this is what I get as version

 curl 7.21.0 (i386-pc-win32) libcurl/7.21.0 OpenSSL/1.0.0a zlib/1.2.5 Protocols: dict file ftp ftps http https imap imaps ldap ldaps pop3 pop3s rtsp scp sftp smtp smtps telnet tftp Features: AsynchDNS Largefile NTLM SSL libz 
+1
source

Source: https://habr.com/ru/post/1310546/


All Articles