Conditionally call g_type_class_add_private()

Otherwise we end up calling it twice with GLib ≥ 2.38.

Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
Merge pull request #2 from ebassi/master

Conditionally call g_type_class_add_private()