Some compilers somehow do not have `inline` defined, so include glib.h to ensure that keyword is defined.`
We can re-use the code inside gcr, as we know that it's working, tested, and license compatible.