Revert "Revert "Figure out the GTK version instead of using a hardcoded one""
Good for master.
This reverts commit e638663b570fe9a436c49ca965116ada8a15b04e.