Add GTK test client, rework API with callbacks, make library