As per [reddit suggestion](https://www.reddit.com/r/cpp/comments/4gkwre/introducing_robot_a_c_library_for_writing_system/d2iolbw), look into using `sudo update-alternatives` instead.