[ruby/resolv] Build the extension library only when CRuby (Fix

https://github.com/ruby/resolv/pull/69)

On JRuby no C compiler is available and this call results in a runtime
error.

https://github.com/ruby/resolv/commit/33105bc504
This commit is contained in:
Nobuyoshi Nakada 2024-12-10 15:50:55 +09:00 committed by git
parent fea83a4b80
commit af9a904f38

View File

@ -1,5 +1,5 @@
require 'mkmf'
if have_library('iphlpapi', 'GetNetworkParams')
if RUBY_ENGINE == "ruby" and have_library('iphlpapi', 'GetNetworkParams')
create_makefile('win32/resolv')
else
File.write('Makefile', "all clean install:\n\t@echo Done: $(@)\n")