Subject: | Search of openssl libraries on Windows |
With openssl-1.1.0e, compiled in VC-WIN32 mode, link libraries are installed by default as libcrypto.lib and libssl.lib. In addition the code checking for Windows libraries has a bug (missing $).
Patch in attachement.
Subject: | SSLeay.pm.diff |
diff -Naur Net-SSLeay-1.81.old/inc/Module/Install/PRIVATE/Net/SSLeay.pm Net-SSLeay-1.81.new/inc/Module/Install/PRIVATE/Net/SSLeay.pm
--- Net-SSLeay-1.81.old/inc/Module/Install/PRIVATE/Net/SSLeay.pm 2017-01-08 04:34:51.000000000 +0100
+++ Net-SSLeay-1.81.new/inc/Module/Install/PRIVATE/Net/SSLeay.pm 2017-04-12 13:09:27.207003700 +0200
@@ -92,11 +92,11 @@
my @pairs = ();
# Library names depend on the compiler
@pairs = (['eay32','ssl32'],['crypto.dll','ssl.dll'],['crypto','ssl']) if $Config{cc} =~ /gcc/;
- @pairs = (['libeay32','ssleay32'],['libeay32MD','ssleay32MD'],['libeay32MT','ssleay32MT']) if $Config{cc} =~ /cl/;
+ @pairs = (['libeay32','ssleay32'],['libeay32MD','ssleay32MD'],['libeay32MT','ssleay32MT'],['libcrypto','libssl']) if $Config{cc} =~ /cl/;
for my $dir (@{$opts->{lib_paths}}) {
for my $p (@pairs) {
$found = 1 if ($Config{cc} =~ /gcc/ && -f "$dir/lib$p->[0].a" && -f "$dir/lib$p->[1].a");
- $found = 1 if ($Config{cc} =~ /cl/ && -f "$dir/$p->[0].lib" && -f "$dir/p->[1].lib");
+ $found = 1 if ($Config{cc} =~ /cl/ && -f "$dir/$p->[0].lib" && -f "$dir/$p->[1].lib");
if ($found) {
$opts->{lib_links} = [$p->[0], $p->[1], 'crypt32']; # Some systems need this system lib crypt32 too
$opts->{lib_paths} = [$dir];