Make it work with ruby bindings