[Extensions] Build glib message pump on Ozone

Squash this patch with the patch with the same name on the next rebase.

Follow-up patch fixing linking errors when using glib on Ozone and not
building component=shared_library.
Merge pull request #170 from tmpsantos/glib_mainloop2

[Extensions] Build glib message pump on Ozone