0

So I tried creating my first GTK 4 program using example-0.c using https://docs.gtk.org/gtk4/getting_started.html#basics guide, but I got the later-described error regarding G_APPLICATION_DEFAULT_FLAGS.

So I'm assuming my GLib version is older than 2.74. I used the command:

pkg-config --modversion glib-2.0

and got

2.72.4

The problem is that when I tried upgrading the package, nothing changed. I remember trying to upgrade libglib before (I forgot the commands I used), but it said that it already has the newest version, which is false because, according to https://docs.gtk.org/glib/, the newest version is 2.76.

Why does it think that the current version is the latest one; how to fix that and upgrade GLib?

Gimper
  • 31
  • 5
  • 2
    *"Why does it think that the current version is the latest one"* - it is the latest one for your version of Ubuntu. See also [Why don't the Ubuntu repositories have the latest versions of software?](https://askubuntu.com/questions/151283/why-dont-the-ubuntu-repositories-have-the-latest-versions-of-software) – steeldriver May 30 '23 at 20:53
  • Got it, thanks. – Gimper May 30 '23 at 21:04

1 Answers1

0

I used @steeldriver 's suggestion and upgraded my Ubuntu (22.04 LTS) to 22.10.

The library is now 2.74.3 and the error is no more.

Gimper
  • 31
  • 5