I'm working on a feature (https://github.com/jekyll/jekyll/pull/5142
) for the Jekyll static site generator. I'm using EventMachine to run a WebSockets server (em-websockets). Unfortunately, I'm having an issue with eventmachine's native extensions on Windows in the Jekyll CI environment. I'm getting an error, "Encryption not available on this event-machine". I've read https://github.com/eventmachine/eventmachine/wiki/Building-EventMachine
and I believe I'm linking to OpenSSL and getting the native extensions compiled but I am still seeing the same error:
bundle exec gem pristine eventmachine
Restoring gems to pristine condition...
bundle exec gem install eventmachine --platform ruby -- --with-ssl-dir=C:/OpenSSL-%OPENSSL_ARCH%
Temporarily enhancing PATH to include DevKit...
Building native extensions with: '--with-ssl-dir=C:/OpenSSL-Win32'
This could take a while...
Successfully installed eventmachine-220.127.116.11
Parsing documentation for eventmachine-18.104.22.168
Installing ri documentation for eventmachine-22.214.171.124
Done installing documentation for eventmachine after 7 seconds
1 gem installed
ruby 2.3.1p112 (2016-04-26 revision 54768) [i386-mingw32]
Bundler version 1.13.3
+ ruby -S bundle exec rake TESTOPTS=--profile test
C:/Ruby23/bin/ruby.exe -w -I"lib;lib;test" -I"C:/projects/jekyll/vendor/bundle/ruby/2.3.0/gems/rake-11.3.0/lib" "C:/projects/jekyll/vendor/bundle/ruby/2.3.0/gems/rake-11.3.0/lib/rake/rake_test_loader.rb" "test/**/test_*.rb" --profile
terminate called after throwing an instance of 'std::runtime_error'
what(): Encryption not available on this event-machine
Command failed with status (3): [ruby -w -I"lib;lib;test" -I"C:/projects/jekyll/vendor/bundle/ruby/2.3.0/gems/rake-11.3.0/lib" "C:/projects/jekyll/vendor/bundle/ruby/2.3.0/gems/rake-11.3.0/lib/rake/rake_test_loader.rb" "test/**/test_*.rb" --profile]
As you can see, after a `bundle install`, I'm running `bundle pristine` and then `bundle exec gem install` with the appropriate flags as mentioned in the wiki article I linked earlier. Using `bundler config` to add the arguments did not seem to make an difference at all for me. In addition to the log reporting that the native extensions are built, I can also see an `ssl.o` file in the `ext` directory of the evenmachine gem.
If anyone has any additional insight into what "Encryption not available on this event-machine" means or if there's a better way to tell if eventmachine linked successfully to OpenSSL, I'd appreciate some help!