diff --git a/0001-Remove-sub-classing-from-OO.o-mime-types.patch b/0001-Remove-sub-classing-from-OO.o-mime-types.patch deleted file mode 100644 index c811f1099698cf90da0f988cb1a56289ffc544af..0000000000000000000000000000000000000000 --- a/0001-Remove-sub-classing-from-OO.o-mime-types.patch +++ /dev/null @@ -1,265 +0,0 @@ -From dc15dd50b198b0b2a135abd16151206dd9acca75 Mon Sep 17 00:00:00 2001 -From: Bastien Nocera -Date: Thu, 25 Aug 2011 10:54:47 +0100 -Subject: [PATCH] Remove sub-classing from OO.o mime-types - -https://bugs.freedesktop.org/show_bug.cgi?id=40354 ---- - data/freedesktop.org.xml.in | 31 ------------------------------- - 1 file changed, 31 deletions(-) - -diff --git a/data/freedesktop.org.xml.in b/data/freedesktop.org.xml.in -index 1c17b8d..ad464e1 100644 ---- a/data/freedesktop.org.xml.in -+++ b/data/freedesktop.org.xml.in -@@ -877,7 +877,6 @@ command to generate the output files. - - - OpenOffice Calc spreadsheet -- - - - -@@ -890,7 +889,6 @@ command to generate the output files. - - - OpenOffice Calc template -- - - - -@@ -903,7 +901,6 @@ command to generate the output files. - - - OpenOffice Draw drawing -- - - - -@@ -916,7 +913,6 @@ command to generate the output files. - - - OpenOffice Draw template -- - - - -@@ -929,7 +925,6 @@ command to generate the output files. - - - OpenOffice Impress presentation -- - - - -@@ -942,7 +937,6 @@ command to generate the output files. - - - OpenOffice Impress template -- - - - -@@ -955,7 +949,6 @@ command to generate the output files. - - - OpenOffice Math formula -- - - - -@@ -968,7 +961,6 @@ command to generate the output files. - - - OpenOffice Writer document -- - - - -@@ -981,7 +973,6 @@ command to generate the output files. - - - OpenOffice Writer global document -- - - - -@@ -994,7 +985,6 @@ command to generate the output files. - - - OpenOffice Writer template -- - - - -@@ -1009,7 +999,6 @@ command to generate the output files. - ODT document - ODT - OpenDocument Text -- - - - -@@ -1024,7 +1013,6 @@ command to generate the output files. - ODT document (Flat XML) - FODT - OpenDocument Text (Flat XML) -- - - - -@@ -1032,7 +1020,6 @@ command to generate the output files. - ODT template - ODT - OpenDocument Text -- - - - -@@ -1047,7 +1034,6 @@ command to generate the output files. - OTH template - OTH - OpenDocument HTML -- - - - -@@ -1062,7 +1048,6 @@ command to generate the output files. - ODM document - ODM - OpenDocument Master -- - - - -@@ -1077,7 +1062,6 @@ command to generate the output files. - ODG drawing - ODG - OpenDocument Drawing -- - - - -@@ -1092,7 +1076,6 @@ command to generate the output files. - ODG drawing (Flat XML) - FODG - OpenDocument Drawing (Flat XML) -- - - - -@@ -1100,7 +1083,6 @@ command to generate the output files. - ODG template - ODG - OpenDocument Drawing -- - - - -@@ -1115,7 +1097,6 @@ command to generate the output files. - ODP presentation - ODP - OpenDocument Presentation -- - - - -@@ -1130,7 +1111,6 @@ command to generate the output files. - ODP presentation (Flat XML) - FODP - OpenDocument Presentation (Flat XML) -- - - - -@@ -1138,7 +1118,6 @@ command to generate the output files. - ODP template - ODP - OpenDocument Presentation -- - - - -@@ -1153,7 +1132,6 @@ command to generate the output files. - ODS spreadsheet - ODS - OpenDocument Spreadsheet -- - - - -@@ -1168,7 +1146,6 @@ command to generate the output files. - ODS spreadsheet (Flat XML) - FODS - OpenDocument Spreadsheet (Flat XML) -- - - - -@@ -1176,7 +1153,6 @@ command to generate the output files. - ODS template - ODS - OpenDocument Spreadsheet -- - - - -@@ -1191,7 +1167,6 @@ command to generate the output files. - ODC chart - ODC - OpenDocument Chart -- - - - -@@ -1206,7 +1181,6 @@ command to generate the output files. - ODC template - ODC - OpenDocument Chart -- - - - -@@ -1221,7 +1195,6 @@ command to generate the output files. - ODF formula - ODF - OpenDocument Formula -- - - - -@@ -1236,7 +1209,6 @@ command to generate the output files. - ODF template - ODF - OpenDocument Formula -- - - - -@@ -1251,7 +1223,6 @@ command to generate the output files. - ODB database - ODB - OpenDocument Database -- - - - -@@ -1267,7 +1238,6 @@ command to generate the output files. - ODI image - ODI - OpenDocument Image -- - - - -@@ -1280,7 +1250,6 @@ command to generate the output files. - - - OpenOffice.org extension -- - - - --- -2.26.2 - diff --git a/backport-migrate-from-custom-itstool-to-builtin-msgfmt-for-creating-translated-XML.patch b/backport-migrate-from-custom-itstool-to-builtin-msgfmt-for-creating-translated-XML.patch deleted file mode 100644 index 7fde718d23cd66232075466a958d06b16005e9d5..0000000000000000000000000000000000000000 --- a/backport-migrate-from-custom-itstool-to-builtin-msgfmt-for-creating-translated-XML.patch +++ /dev/null @@ -1,102 +0,0 @@ -From 5a406b06792e26a83c7346b3c2443c0bd8d4cdb2 Mon Sep 17 00:00:00 2001 -From: Eli Schwartz -Date: Mon, 8 Nov 2021 18:22:47 -0500 -Subject: [PATCH] migrate from custom itstool to builtin msgfmt for creating - translated XML - -gettext upstream has supported this for a very long time (since 0.19.7 -via commit b3c2a5a242c36fbbaa0c5b17f975d6c638598a23, released in 2015), -and itstool is (mostly) a legacy of the time before gettext had proper -support for these sorts of use cases. - -This is similar to the state of intltool, which is described at -https://wiki.gnome.org/MigratingFromIntltoolToGettext - -During the port from autotools to meson, the legacy use of itstool was -faithfully translated to meson in the only way possible: by jumping -through hoops to run ninja inside ninja in order to generate the .mo -files for itstool, because meson's i18n module used a flawed design and -there was no "real" target to create those files, only a .PHONY -run_target which other rules cannot depend on. - -Although meson 0.60.0 added support for real targets for the built .mo -files, this changed the rules for output filenames, breaking the script. - -But msgfmt does not care, and anyways comes with builtin meson functions -for convenient use with XML files. So let's take this opportunity to -drop legacy dependencies and use the modern, builtin tooling, which -fixes this bug as a side effect. - -Fixes #170 - -Reference:https://gitlab.freedesktop.org/xdg/shared-mime-info/-/commit/5a406b06792e26a83c7346b3c2443c0bd8d4cdb2 - ---- - data/freedesktop_generate.sh | 12 ------------ - data/meson.build | 17 ++++++----------- - meson.build | 1 - - 3 files changed, 6 insertions(+), 24 deletions(-) - delete mode 100755 data/freedesktop_generate.sh - -diff --git a/data/freedesktop_generate.sh b/data/freedesktop_generate.sh -deleted file mode 100755 -index ff13e75..0000000 ---- a/data/freedesktop_generate.sh -+++ /dev/null -@@ -1,12 +0,0 @@ --#!/bin/sh -e -- --src_root="$1" --build_root="$2" -- --ninja -C "${build_root}" shared-mime-info-gmo -- --itstool \ -- --its "${src_root}/data/its/shared-mime-info.its" \ -- --join "${src_root}/data/freedesktop.org.xml.in" \ -- -o "${build_root}/data/freedesktop.org.xml" \ -- "${build_root}/po/"*".gmo" -diff --git a/data/meson.build b/data/meson.build -index 263567d..69ac56b 100644 ---- a/data/meson.build -+++ b/data/meson.build -@@ -1,18 +1,13 @@ - - install_man('update-mime-database.1') - --freedesktop_org_xml = custom_target('freedesktop.org.xml', -- input : files( -- 'freedesktop.org.xml.in', -- 'its/shared-mime-info.its', -- 'its/shared-mime-info.loc', -- ), -+freedesktop_org_xml = i18n.merge_file( -+ input: 'freedesktop.org.xml.in', - output: 'freedesktop.org.xml', -- command: [ -- find_program('freedesktop_generate.sh'), -- meson.source_root(), -- meson.build_root() -- ], -+ data_dirs: '.', -+ po_dir: '../po', -+ type: 'xml', -+ - install: true, - install_dir: get_option('datadir') / 'mime' / 'packages', - ) -diff --git a/meson.build b/meson.build -index 9a28573..b696baf 100644 ---- a/meson.build -+++ b/meson.build -@@ -20,7 +20,6 @@ config.set_quoted('VERSION', meson.project_version()) - ############################################################################### - # Find tools - --itstool = find_program('itstool') - xmllint = find_program('xmllint') - xmlto = find_program('xmlto') - --- -2.33.0 - diff --git a/shared-mime-info-2.1.tar.xz b/shared-mime-info-2.2.tar.gz similarity index 39% rename from shared-mime-info-2.1.tar.xz rename to shared-mime-info-2.2.tar.gz index 2e7b93d45e40c5a4238a3da2ed0d8d243bfd30d6..4abe906a3f2b3832c781e2eb8ec8a12abf2ae40e 100644 Binary files a/shared-mime-info-2.1.tar.xz and b/shared-mime-info-2.2.tar.gz differ diff --git a/shared-mime-info.spec b/shared-mime-info.spec index 5f92eb99b91402e554c26b4e4a656f27e3c41a3a..7b5e4c0409436e0965c07fc38ecf40fc7e38843e 100644 --- a/shared-mime-info.spec +++ b/shared-mime-info.spec @@ -1,16 +1,13 @@ Name: shared-mime-info -Version: 2.1 -Release: 2 +Version: 2.2 +Release: 1 Summary: Shared MIME information database License: GPLv2+ URL: https://freedesktop.org/wiki/Software/shared-mime-info/ -Source0: https://gitlab.freedesktop.org/xdg/shared-mime-info/uploads/0ee50652091363ab0d17e335e5e74fbe/shared-mime-info-2.1.tar.xz +Source0: https://gitlab.freedesktop.org/xdg/shared-mime-info/-/archive/2.2/shared-mime-info-2.2.tar.gz Source1: mimeapps.list -Patch0: 0001-Remove-sub-classing-from-OO.o-mime-types.patch -Patch1: backport-migrate-from-custom-itstool-to-builtin-msgfmt-for-creating-translated-XML.patch - BuildRequires: gcc libxml2-devel glib2-devel gettext intltool perl-XML-Parser meson itstool xmlto %global __requires_exclude ^/usr/bin/pkg-config$ @@ -75,6 +72,9 @@ update-mime-database -n %{_datadir}/mime &> /dev/null ||: %{_mandir}/man1/*.gz %changelog +* Sun Sep 11 2022 tianlijing - 2.2-1 +- update to 2.2 + * Mon Jun 20 2022 hanhui - 2.1-2 - migrate from custom itstool to builtin msgfmt for creating translated XML