Building EventMachine with SSL on Windows

Krzysztof Chodak edited this page Dec 23, 2016 · 16 revisions

To compile EM with SSL on Windows one needs to have OpenSSL libraries and headers from

Make sure you download bigger package described as "Recommended for software developers by the creators of OpenSSL" - it should contain lib/MinGW and include/openssl subdirectories

Download and install it to preferred directory for example C:\OpenSSL

To compile the gem from source with SSL use following command:

rake compile -- --with-ssl-dir=c:/OpenSSL

To compile it with SSL using bundler issue following command before installing the bundle:

bundle config build.eventmachine --with-ssl-dir=c:/OpenSSL

The above works fine from 1.0.8

PS. I am not totally sure why but bundle config does not always work as expected and I am forced to manually uninstall gem and install it again with proper flag as below:

gem install eventmachine -- --with-ssl-dir=c:/OpenSSL

PS2. As per

gem install eventmachine --platform ruby -- --with-ssl-dir=c:/OpenSSL

to force local compilation and not to download precompiled gem without SSL