align the various GTK 4 "API versions"
Submitted by Simon McVittie
Link to original bug (#785166)
Description
Before GTK+ 4 gets too widely used to be making incompatible changes, it would be nice if it had a single tree-wide API name/version.
At the moment:
-
configure.ac says the API version is 4.0 and the name of the project is gtk+ (m4_define([gtk_api_version], [4.0]) with a no-longer-true comment saying it is the X.Y in -lgtk-X.Y)
-
the .pc files agree with configure.ac (it is gtk+-4.0.pc)
-
but the name of the shared library says the API version is 4 and the name of the main library is gtk (you link with -lgtk-4 which is $libdir/libgtk-4.so)
-
the header files are installed in $includedir/gtk-4.0 which is a mixture of the two
-
the GObject-Introspection says it's Gtk version 4.0 (and presumably can't use the + anyway)
GTK+ 3 has a similar situation. In Debian we use gtk+3.0 as the source package name but libgtk-3-dev as the development binary package name, and there is no trivial relationship between either of those and the main .pc filename gtk+-3.0.pc that you get by installing that package.
This seems non-ideal. It would be easier for API consumers to correlate .pc filenames, library names, Debian -dev package names, RPM -devel package names, etc. if they all made one consistent choice of 4 vs. 4.0 and gtk+ vs. gtk.
The only purpose in having the ".0" in "gtk+-4.0" would be if GTK 4.0 and 4.2 might be incompatible; but if they were incompatible then I assume we'd want them to be parallel-installable, and that can't happen as long as they both try to install $libdir/libgtk-4.so?
I would personally prefer the colour of the bike shed to be gtk-4, but gtk-4.0 would also be fine - the main thing that I'm asking for is that both ends of the bike shed get painted the same colour :-)
Version: 3.93.x