ubus: make libubus ready for linking into C++