Install libssl-dev because ruby needs it
Bugfix: unset, not undef
Sort apt-get and add more build dependencies