Use char in favor of gchar.
NSString as the native string type for Objective-C.
Use khash for the fields hash.
Don't use glib's random functions.
Get rid of unicode GLib dependency.

This makes us independent of GLib on Objective-C.
Use StringBuilder for str.