Skip to content

Commit

Permalink
Check for libcrypto before libssl on mingw
Browse files Browse the repository at this point in the history
On mingw (rubyinstaller) libssl depends on libcrypto, so libcrypto needs
to be checked before libssl for correct link order.

Signed-off-by: Alexey Borzenkov <snaury@gmail.com>
  • Loading branch information
snaury committed Aug 14, 2009
1 parent 56513c3 commit 0382057
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ext/extconf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -111,14 +111,15 @@ def manual_ssl_config
# openbsd and linux:
:crypto_hack => [%w[crypto ssl crypto], %w[openssl/ssl.h openssl/err.h]],
:mswin => [%w[ssleay32 libeay32], %w[openssl/ssl.h openssl/err.h]],
:mingw => [%w[crypto ssl], %w[openssl/ssl.h openssl/err.h]],
}

dc_flags = ['ssl']
dc_flags += ["#{ENV['OPENSSL']}/include", ENV['OPENSSL']] if /linux/ =~ RUBY_PLATFORM

libs, heads = case RUBY_PLATFORM
when /mswin/ ; ssl_libs_heads_args[:mswin]
when /mingw/ ; ssl_libs_heads_args[:unix]
when /mingw/ ; ssl_libs_heads_args[:mingw]
when /darwin/ ; ssl_libs_heads_args[:darwin]
when /openbsd/ ; ssl_libs_heads_args[:crypto_hack]
when /linux/ ; ssl_libs_heads_args[:crypto_hack]
Expand Down

0 comments on commit 0382057

Please sign in to comment.