From de8970016e2a6179668742099ae8a3e434764e6a1b23cd966049c2f40f90cadf Mon Sep 17 00:00:00 2001 From: Christophe Marin Date: Sun, 18 Feb 2024 12:45:19 +0000 Subject: [PATCH 1/3] - Add upstream change to fix potential URL validity check errors: * 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch OBS-URL: https://build.opensuse.org/package/show/KDE:Frameworks5/AppStream?expand=0&rev=114 --- AppStream.changes | 6 ++++++ AppStream.spec | 2 ++ 2 files changed, 8 insertions(+) diff --git a/AppStream.changes b/AppStream.changes index 578b4fe..4a149aa 100644 --- a/AppStream.changes +++ b/AppStream.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sun Feb 18 12:44:31 UTC 2024 - Christophe Marin + +- Add upstream change to fix potential URL validity check errors: + * 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch + ------------------------------------------------------------------- Thu Feb 1 09:04:42 UTC 2024 - Christophe Marin diff --git a/AppStream.spec b/AppStream.spec index b11426b..bb414b5 100644 --- a/AppStream.spec +++ b/AppStream.spec @@ -45,6 +45,8 @@ Source1: http://www.freedesktop.org/software/appstream/releases/%{rname}- Source2: AppStream.keyring # PATCH-FIX-OPENSUSE Patch0: support-meson0.59.patch +# PATCH-FIX-UPSTREAM -- Fixes tests on KDE CI +Patch1: 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch BuildRequires: cairo-devel BuildRequires: docbook-xsl-stylesheets %if %{with gcc13} From 4562bf26dd19f2b77ce95cd56c7832e24f6c78213a1da872159518d3bc8969c9 Mon Sep 17 00:00:00 2001 From: Christophe Marin Date: Sun, 18 Feb 2024 12:49:45 +0000 Subject: [PATCH 2/3] OBS-URL: https://build.opensuse.org/package/show/KDE:Frameworks5/AppStream?expand=0&rev=115 --- ...y-abort-URL-validity-check-during-se.patch | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch diff --git a/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch b/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch new file mode 100644 index 0000000..548f49e --- /dev/null +++ b/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch @@ -0,0 +1,55 @@ +From d3085b7d1492766f5d7bb5de210c2b11c2e1ead9 Mon Sep 17 00:00:00 2001 +From: Matthias Klumpp +Date: Sun, 18 Feb 2024 06:50:02 +0100 +Subject: [PATCH] Don't prematurely abort URL validity check during semi-large + redirects + +During some redirects we were already downloading enough data to warrant +aborting the download, leaving us with 302 as the last status code, +failing the reachable-URL test. + +With this change, we will only start to count downloadable bytes once we +left the redirects, so we will only count downloaded data at our final +destination. + +Resolves: #597 +--- + src/as-curl.c | 12 ++++++++++-- + 1 file changed, 10 insertions(+), 2 deletions(-) + +diff --git a/src/as-curl.c b/src/as-curl.c +index 30e492a0..b860b36a 100644 +--- a/src/as-curl.c ++++ b/src/as-curl.c +@@ -110,6 +110,7 @@ as_curl_download_write_bytearray_cb (char *ptr, size_t size, size_t nmemb, void + GByteArray *buf = (GByteArray *) udata; + gsize realsize = size * nmemb; + g_byte_array_append (buf, (const guint8 *) ptr, realsize); ++ + return realsize; + } + +@@ -368,11 +369,18 @@ as_curl_progress_check_url_cb (void *clientp, + curl_off_t ulnow) + { + AsCurlPrivate *priv = GET_PRIVATE ((AsCurl *) clientp); ++ glong status_code; ++ ++ /* always continue if we are still being redirected */ ++ curl_easy_getinfo (priv->curl, CURLINFO_RESPONSE_CODE, &status_code); ++ if (status_code == 302) ++ return 0; ++ + priv->bytes_downloaded = dlnow; + +- /* stop after 2kb have been successfully downloaded - it turns out a lot ++ /* stop after 1kb has been successfully downloaded - it turns out a lot + * of downloads fail later, so just checking for the first byte is not enough */ +- if (dlnow >= 2048) ++ if (dlnow >= 1024) + return 1; + return 0; + } +-- +2.43.0 + From c7a34c051da3ad4321b1f7195ce8c4de2e208c34ad513747471da601e166a65c Mon Sep 17 00:00:00 2001 From: Christophe Marin Date: Fri, 1 Mar 2024 18:54:53 +0000 Subject: [PATCH 3/3] Accepting request 1153846 from home:krop:branches:KDE:Frameworks5 Update to 1.0.2 OBS-URL: https://build.opensuse.org/request/show/1153846 OBS-URL: https://build.opensuse.org/package/show/KDE:Frameworks5/AppStream?expand=0&rev=116 --- ...y-abort-URL-validity-check-during-se.patch | 55 ------------------- AppStream-1.0.1.tar.xz | 3 - AppStream-1.0.1.tar.xz.asc | 16 ------ AppStream-1.0.2.tar.xz | 3 + AppStream-1.0.2.tar.xz.asc | 16 ++++++ AppStream.changes | 45 +++++++++++++++ AppStream.spec | 8 +-- 7 files changed, 67 insertions(+), 79 deletions(-) delete mode 100644 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch delete mode 100644 AppStream-1.0.1.tar.xz delete mode 100644 AppStream-1.0.1.tar.xz.asc create mode 100644 AppStream-1.0.2.tar.xz create mode 100644 AppStream-1.0.2.tar.xz.asc diff --git a/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch b/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch deleted file mode 100644 index 548f49e..0000000 --- a/0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch +++ /dev/null @@ -1,55 +0,0 @@ -From d3085b7d1492766f5d7bb5de210c2b11c2e1ead9 Mon Sep 17 00:00:00 2001 -From: Matthias Klumpp -Date: Sun, 18 Feb 2024 06:50:02 +0100 -Subject: [PATCH] Don't prematurely abort URL validity check during semi-large - redirects - -During some redirects we were already downloading enough data to warrant -aborting the download, leaving us with 302 as the last status code, -failing the reachable-URL test. - -With this change, we will only start to count downloadable bytes once we -left the redirects, so we will only count downloaded data at our final -destination. - -Resolves: #597 ---- - src/as-curl.c | 12 ++++++++++-- - 1 file changed, 10 insertions(+), 2 deletions(-) - -diff --git a/src/as-curl.c b/src/as-curl.c -index 30e492a0..b860b36a 100644 ---- a/src/as-curl.c -+++ b/src/as-curl.c -@@ -110,6 +110,7 @@ as_curl_download_write_bytearray_cb (char *ptr, size_t size, size_t nmemb, void - GByteArray *buf = (GByteArray *) udata; - gsize realsize = size * nmemb; - g_byte_array_append (buf, (const guint8 *) ptr, realsize); -+ - return realsize; - } - -@@ -368,11 +369,18 @@ as_curl_progress_check_url_cb (void *clientp, - curl_off_t ulnow) - { - AsCurlPrivate *priv = GET_PRIVATE ((AsCurl *) clientp); -+ glong status_code; -+ -+ /* always continue if we are still being redirected */ -+ curl_easy_getinfo (priv->curl, CURLINFO_RESPONSE_CODE, &status_code); -+ if (status_code == 302) -+ return 0; -+ - priv->bytes_downloaded = dlnow; - -- /* stop after 2kb have been successfully downloaded - it turns out a lot -+ /* stop after 1kb has been successfully downloaded - it turns out a lot - * of downloads fail later, so just checking for the first byte is not enough */ -- if (dlnow >= 2048) -+ if (dlnow >= 1024) - return 1; - return 0; - } --- -2.43.0 - diff --git a/AppStream-1.0.1.tar.xz b/AppStream-1.0.1.tar.xz deleted file mode 100644 index cfa0ea3..0000000 --- a/AppStream-1.0.1.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:fa4d5994e5c6f22e9b66cb0b52e8b5f5d96e7353ea5528b56436e0150829203b -size 2686244 diff --git a/AppStream-1.0.1.tar.xz.asc b/AppStream-1.0.1.tar.xz.asc deleted file mode 100644 index 9b6b071..0000000 --- a/AppStream-1.0.1.tar.xz.asc +++ /dev/null @@ -1,16 +0,0 @@ ------BEGIN PGP SIGNATURE----- - -iQIzBAABCAAdFiEE0zo/DKFrCsxRpgc4SUyKX79N7OsFAmV93JEACgkQSUyKX79N -7OtiSRAAlWPrsQLdYvwPA9I1NPTlpKYM4JiGyB9U78E/lzGcrCz/VbMrIQr0Okkb -nzHGt0KmtaNu99h0Awd8mHsRz4bNI44x66p4HFQUN/XouE9CJOJZb426at/NopfZ -sJn4+Bq1lKZuNT5lgSQjQFsBFSBroAqzXBiRhKrhy/Cdo39nPtTN7L1fkLLMhsce -IOCGRQGcLwYWBYJ9FL+fy894+tNG1lm3x2B0sbbeBf30MRfKvHTu364mlcs9bnp0 -k8kC266Sjz5k5bqJRUL38zncHisN9HUXZj9G/t0n1ee59IkAepIeLETxU6vHW1YE -FY9iLD3+U4YYhWTrmhH4t/TysixN1CLQyDIsuRjqnYPGd08rujE8L7o0N2/LzTE8 -TleNIs14dljWrHeSylEi7I4MFiK0A3eDt23xqsmGl2qQ8W8VxItKv1uN9JKLOmJ3 -mAv4mDmQtaTM/8UlgSUTtZChUfydYnAJSKKmyRBEmqKPBZK6XHGrId5Uy8KjyOjM -9g/4HUqLBTSmdErxeOAy8VhVkwApuPjFq0o1/+/doGoEFHITx+pqzTrKHXilJyOQ -mySumufZ+jpBXmVDhcMR43pgy7ejobaqK1wAOvx3/VDTmIt2ax9XUpKwTAqAAdSN -UbT34aXemxKzcWTXNHXrY+OK4w6KjPSvacr63wypYJRlnNobpZ0= -=/u+K ------END PGP SIGNATURE----- diff --git a/AppStream-1.0.2.tar.xz b/AppStream-1.0.2.tar.xz new file mode 100644 index 0000000..265c406 --- /dev/null +++ b/AppStream-1.0.2.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a5148ca97dcbf5eb6e9c380278bb0d20938569292ea8652df1b3cac8bd2736b +size 2629708 diff --git a/AppStream-1.0.2.tar.xz.asc b/AppStream-1.0.2.tar.xz.asc new file mode 100644 index 0000000..c095ff9 --- /dev/null +++ b/AppStream-1.0.2.tar.xz.asc @@ -0,0 +1,16 @@ +-----BEGIN PGP SIGNATURE----- + +iQIzBAABCAAdFiEE0zo/DKFrCsxRpgc4SUyKX79N7OsFAmXaXjcACgkQSUyKX79N +7OtMTxAApwK7doT0+jup4Wv9981wcb2Hm8N7f7GpLBxMb9xz4mf6WfGtJbUPT8IH +GcPKfaC3jSK4vpo6E9JUWctzq3LOlswMEqXoEamfg0+nT2+fqvBad5Y9eUvfHE2v +xGP7OtyvOqXDOfnwCOz4NziKA8XHcwySrePrjVFxAMVHSkNXv+Mo8yUt4lEawGXB +gxaZKsOalsbOpDA3pjDH+stTUtvoXjdQbHVuPJFHzXMLm2JHD7B9/DjSQVGeBm/R +SoAw10awc8GXONaeRazcUxWfUO2G/oRR/7vO2AMTfF/RCcBMl1C9qilZiQU3DVnS +guILHkbf3l1ycj5Kc0PMfO6K1G/s0PVd25ksq4pVhR1rssSKP5ydyLRCd+y2Xi70 +0MsrduTgsf5R880BPjrpJxPsOjrlpQ2kyczC+6cNcXBeRrWkzYBmfZL+tNGdMes/ +H/uwH1VoTq5oDGYW+Ma2rAIqnzmT/J7osluOngvEaGK1ZhRTNb/+n+f8yO8hid0n +GI4YyvkyiPvBnsOCJamMljluwmhbjfXM9G5rd1viAIiB6nsoT5b11fYkSFSJZFoE +YldYNafNpuC2rzesRxiZbG5fWqMT2jt/JNIRcyg5KPr4ZMAmfojPPf/Tp7/EUvc7 +qgWzDVhoBk2vPnKFIktFqdIXtrjvAfmSKPO9xnYkMwZUwhrEAWM= +=3R9f +-----END PGP SIGNATURE----- diff --git a/AppStream.changes b/AppStream.changes index 4a149aa..7a9099d 100644 --- a/AppStream.changes +++ b/AppStream.changes @@ -1,3 +1,48 @@ +------------------------------------------------------------------- +Fri Mar 1 09:46:46 UTC 2024 - Christophe Marin + +- Update to 1.0.2 + Features: + * qt: Allow building for multiple Qt major versions at once + * Improve low-quality category check and extend its blacklist + * validator: Add some limited developer-ID validation + * validator: Emit an overridable warning if homepage URL was omitted + * compose: Allow rendering vector graphics to HiDPI bitmaps unconditionally + * compose: Allow setting a custom icon-policy on the command-line + Specification: + * docs: Mention that tag can be translated + * docs: Generate validation issue tag documentation from code + * docs: Add information on how to exclude elements from translation + * spec: Recommend using rDNS strings or Fediverse handles as developer-ID + * spec: Make launchable requirement for desktop-apps more strict + Bugfixes: + * qt: Component::customValue should be const + * validator: Remove mention of shorthands from relation-display-length-value-invalid + * sysinfo: Swap arguments of g_pattern_match_simple + * qt: Add missing screenshot sorting function + * qt: pool: Add missing Q_EMIT keyword + * validator: Improve error message if no valid categories were found + * validator: Make some length limitations more strict + * validator: Only emit developer-name-tag-deprecated once + * validator: Ensure filename is properly included in location info again + * validator: Improve error reporting on images with missing/bad locales + * compose: Don't accidentally set icon scale to 0 in some cases + * compose: Add heuristics to show out-of-scope errors if filters were set + * Don't prematurely abort URL validity check during semi-large redirects + * docs: Update supported hashsums to reflect reality + * docs: Describe version comparison letters special case + * docs: Clarify release descriptions *must not* contain embedded URL + * docs: Explicitly mention /var/cache/swcatalog is a valid + catalog data location + * tests: Fix tests with old & new FontConfig + * its: Allow untranslatable developer/name and agreement sections + Miscellaneous: + * compose: Clarify that "no valid category" can mean bad ones + were ignored + * news-convert: Don't strip out the last text in brackets +- Drop patch, merged upstream: + * # 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch + ------------------------------------------------------------------- Sun Feb 18 12:44:31 UTC 2024 - Christophe Marin diff --git a/AppStream.spec b/AppStream.spec index bb414b5..c34585c 100644 --- a/AppStream.spec +++ b/AppStream.spec @@ -35,7 +35,7 @@ %define libAppStreamQt_sover 3 %define libappstream_compose_sover 0 Name: AppStream%{?pkg_suffix} -Version: 1.0.1 +Version: 1.0.2 Release: 0 Summary: Tools and libraries to work with AppStream metadata License: LGPL-2.1-or-later @@ -45,8 +45,6 @@ Source1: http://www.freedesktop.org/software/appstream/releases/%{rname}- Source2: AppStream.keyring # PATCH-FIX-OPENSUSE Patch0: support-meson0.59.patch -# PATCH-FIX-UPSTREAM -- Fixes tests on KDE CI -Patch1: 0001-Don-t-prematurely-abort-URL-validity-check-during-se.patch BuildRequires: cairo-devel BuildRequires: docbook-xsl-stylesheets %if %{with gcc13} @@ -217,9 +215,9 @@ GObject introspection bindings for interfaces provided by AppStream. %endif %if 0%{?qt6} -%define options -Dqt=true -Dvapi=false -Dcompose=false -Dgir=false +%define options -Dqt=true -Dqt-versions=6 -Dvapi=false -Dcompose=false -Dgir=false %else -%define options -Dqt5=true -Dcompose=true -Dvapi=%{build_vapi} +%define options -Dqt=true -Dqt-versions=5 -Dcompose=true -Dvapi=%{build_vapi} %endif %if %{with gcc13}