single-thread class init

See:

  https://github.com/jcupitt/libvips/issues/64

We were seeing races in class init on very-many-core machines. GObject
is supposed to single-thread class init, I think, so this shouldn't
happen. Perhaps class init via g_type_class_ref() is not
single-threaded.