From 1c7fe694fa657ed877f1be682b3b9c60658ee9ed Mon Sep 17 00:00:00 2001 From: Will Thompson Date: Fri, 22 Jul 2022 11:03:07 +0100 Subject: [PATCH 1/4] Don't depend on gtk+-3.0 if xmllint is found When validating the .ui files, we need to determine the path to GTK 4's relaxng schema. Previously this was erroneously looked up in the prefix of GTK 3, which malcontent otherwise doesn't depend on. Define the GTK dependency once, and use that variable everywhere. --- libmalcontent-ui/meson.build | 4 ++-- malcontent-control/meson.build | 4 ++-- meson.build | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/libmalcontent-ui/meson.build b/libmalcontent-ui/meson.build index 6c85393..b19405b 100644 --- a/libmalcontent-ui/meson.build +++ b/libmalcontent-ui/meson.build @@ -28,7 +28,7 @@ libmalcontent_ui_public_deps = [ dependency('gio-2.0', version: '>= 2.44'), dependency('glib-2.0', version: '>= 2.54.2'), dependency('gobject-2.0', version: '>= 2.54'), - dependency('gtk4', version: '>= 4.6'), + gtk_dep, libadwaita_dep, libmalcontent_dep, ] @@ -82,7 +82,7 @@ libmalcontent_ui_gir = gnome.generate_gir(libmalcontent_ui, xmllint = find_program('xmllint', required: false) if xmllint.found() - gtk_prefix = dependency('gtk+-3.0').get_variable(pkgconfig: 'prefix') + gtk_prefix = gtk_dep.get_variable(pkgconfig: 'prefix') test( 'validate-ui', xmllint, args: [ diff --git a/malcontent-control/meson.build b/malcontent-control/meson.build index 515b56b..d7a9071 100644 --- a/malcontent-control/meson.build +++ b/malcontent-control/meson.build @@ -27,7 +27,7 @@ malcontent_control = executable('malcontent-control', dependency('gio-2.0', version: '>= 2.44'), dependency('glib-2.0', version: '>= 2.54.2'), dependency('gobject-2.0', version: '>= 2.54'), - dependency('gtk4', version: '>= 4.6'), + gtk_dep, dependency('polkit-gobject-1'), libadwaita_dep, libmalcontent_dep, @@ -79,7 +79,7 @@ endif xmllint = find_program('xmllint', required: false) if xmllint.found() - gtk_prefix = dependency('gtk+-3.0').get_variable(pkgconfig: 'prefix') + gtk_prefix = gtk_dep.get_variable(pkgconfig: 'prefix') test( 'validate-ui', xmllint, args: [ diff --git a/meson.build b/meson.build index c90c4c5..e83f2e9 100644 --- a/meson.build +++ b/meson.build @@ -134,6 +134,7 @@ else 'Malcontent-' + libmalcontent_api_version + '.typelib'] endif if get_option('ui').enabled() + gtk_dep = dependency('gtk4', version: '>= 4.6') libadwaita_dep = dependency( 'libadwaita-1', version: '>= 1.1', From 922ae096be9852f25bee168915ca8755b67aecd1 Mon Sep 17 00:00:00 2001 From: Will Thompson Date: Fri, 22 Jul 2022 11:12:47 +0100 Subject: [PATCH 2/4] libmalcontent-ui: Fix includes for GIR The libmalcontent-ui API exposes types from GTK 4 (not 3) and libadwaita. --- libmalcontent-ui/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libmalcontent-ui/meson.build b/libmalcontent-ui/meson.build index b19405b..2f77f4d 100644 --- a/libmalcontent-ui/meson.build +++ b/libmalcontent-ui/meson.build @@ -75,7 +75,7 @@ libmalcontent_ui_gir = gnome.generate_gir(libmalcontent_ui, symbol_prefix: 'mct_', identifier_prefix: 'Mct', export_packages: 'libmalcontent-ui', - includes: ['AccountsService-1.0', 'Gio-2.0', 'GObject-2.0', 'Gtk-3.0', libmalcontent_gir[0]], + includes: ['AccountsService-1.0', 'Gio-2.0', 'GObject-2.0', 'Gtk-4.0', 'Adw-1', libmalcontent_gir[0]], install: true, dependencies: libmalcontent_ui_dep, ) From ffba5dab437923978d853030d7326a8212f6c1ad Mon Sep 17 00:00:00 2001 From: Will Thompson Date: Fri, 22 Jul 2022 11:13:33 +0100 Subject: [PATCH 3/4] libmalcontent-ui: Bump API version An app which currently depends on malcontent-ui-0.pc or MalcontentUi-0.gir will fail to compile or run, respectively, aganist the GTK 4-ified version. Bump the API version, which is used in both those names. This will also (I think) allow the two versions of libmalcontent-ui to be parallel-installed. --- libmalcontent-ui/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libmalcontent-ui/meson.build b/libmalcontent-ui/meson.build index 2f77f4d..533aa71 100644 --- a/libmalcontent-ui/meson.build +++ b/libmalcontent-ui/meson.build @@ -1,4 +1,4 @@ -libmalcontent_ui_api_version = '0' +libmalcontent_ui_api_version = '1' libmalcontent_ui_api_name = 'malcontent-ui-' + libmalcontent_ui_api_version if not cc.has_function('atexit') From 8eba2f2ef343c2742df2715b3c82ea4ab4a2ca0a Mon Sep 17 00:00:00 2001 From: Will Thompson Date: Fri, 22 Jul 2022 11:26:28 +0100 Subject: [PATCH 4/4] Prepare for 0.11.0 release --- NEWS | 16 ++++++++++++++++ meson.build | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 05944a8..93bd706 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,19 @@ +Overview of changes in malcontent 0.11.0 +======================================== + +* libmalcontent-ui, and the malcontent-control application, now use + libappstream rather than appstream-glib. (#51) + +* libmalcontent-ui, and the malcontent-control application, now use GTK 4 and + libadwaita rather than GTK+ 3. (!141) + +* As a result of these changes, the pkg-config name has been bumped to + libmalcontent-ui-1, and the gobject-introspection name to MalcontentUi-1. + +* Translation updates: + - Italian + - Russian + Overview of changes in malcontent 0.10.5 ======================================== diff --git a/meson.build b/meson.build index e83f2e9..9cd327d 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project('malcontent', 'c', - version : '0.10.5', + version : '0.11.0', meson_version : '>= 0.57.0', license: ['LGPL-2.1-or-later', 'GPL-2.0-or-later'], default_options : [