gmain: Officially deprecate g_main_context_wait()

It’s been de-facto deprecated for a long time, due to emitting a
critical warning when used in a non-internal context. Make that official
in the documentation and with a deprecation annotation.

Split the implementation into an internal helper and an external
wrapper, so the two remaining internal uses don’t emit deprecation
warnings.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

GNOME/glib#903
7 jobs for 903-deprecate-main-context-wait in 16 minutes and 31 seconds (queued for 9 minutes)
Status Job ID Name Coverage
  Build
passed #53705
cross-android_api21_arm64

00:01:36

passed #53706
cross-mingw64

00:02:01

passed #53720
fedora-x86_64

00:03:24

passed #53707
win32
msys2-mingw32

00:08:16

passed #53708
win32
vs2017-x64

00:05:57

failed #53704
fedora-x86_64

00:06:25

 
  Coverage
passed #53709
coverage

00:01:12

77.0%