mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
22df8d61be
Commit d9e107c801 ("mruby-socket: migrate HAL to ports/ directories")
moved the Windows HAL source into mruby-socket/ports/win/ but dropped
the linker.libraries declarations that previously lived in
hal-win-socket/mrbgem.rake. Both mingw and MSVC builds now fail to
link with undefined references to WSAStartup, socket, send, and other
Winsock APIs. Re-declare wsock32 and ws2_32 under a for_windows? guard.
Co-authored-by: Claude <noreply@anthropic.com>
17 lines
498 B
Ruby
17 lines
498 B
Ruby
MRuby::Gem::Specification.new('mruby-socket') do |spec|
|
|
spec.license = 'MIT'
|
|
spec.authors = ['Internet Initiative Japan Inc.', 'mruby developers']
|
|
spec.summary = 'standard socket class'
|
|
|
|
#spec.cc.defines << "HAVE_SA_LEN=0"
|
|
|
|
spec.add_dependency('mruby-io', :core => 'mruby-io')
|
|
spec.add_dependency('mruby-error', :core => 'mruby-error')
|
|
# spec.add_dependency('mruby-mtest')
|
|
|
|
if spec.for_windows?
|
|
spec.linker.libraries << "wsock32"
|
|
spec.linker.libraries << "ws2_32"
|
|
end
|
|
end
|