Permalink
Browse files

fix 'Init_cool could not be found' issue.

  • Loading branch information...
1 parent b01d416 commit bad0ed767b2e0eb801390dcbdadf517c12132c2e Adios committed May 10, 2011
Showing with 3 additions and 0 deletions.
  1. +3 −0 ext/cool.io/extconf.rb
View
@@ -63,6 +63,9 @@
if RUBY_PLATFORM =~ /mingw|win32/
makefile_contents = File.read 'Makefile'
+ # "Init_cool could not be found" when loading cool.io.so.
+ makefile_contents.gsub! 'DLDFLAGS = ', 'DLDFLAGS = -export-all '
+
makefile_contents.gsub! 'LIBS = $(LIBRUBYARG_SHARED)', 'LIBS = -lws2_32 $(LIBRUBYARG_SHARED)'
File.open('Makefile', 'w') { |f| f.write makefile_contents }
end

0 comments on commit bad0ed7

Please sign in to comment.