From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 95886138359 for ; Sun, 26 Jul 2020 20:02:56 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id BE788E084A; Sun, 26 Jul 2020 20:02:55 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 97E1EE084A for ; Sun, 26 Jul 2020 20:02:55 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 24BAA34ED7F for ; Sun, 26 Jul 2020 20:02:54 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 9B1372DB for ; Sun, 26 Jul 2020 20:02:48 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1595793758.8c62c63c81a738a960c6d3c5cf66d075296b038c.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/appstream/, dev-libs/appstream/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-libs/appstream/appstream-0.12.11-r1.ebuild dev-libs/appstream/files/appstream-0.12.11-disable-Werror-flags.patch dev-libs/appstream/files/appstream-0.12.11-no-highlight.js.patch dev-libs/appstream/files/appstream-0.12.11-qt-add-missing-provided-kindid-enum.patch X-VCS-Directories: dev-libs/appstream/files/ dev-libs/appstream/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: 8c62c63c81a738a960c6d3c5cf66d075296b038c X-VCS-Branch: master Date: Sun, 26 Jul 2020 20:02:48 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: d0826752-1ddc-419d-94c4-0cec48ce3560 X-Archives-Hash: 0e88494519b6da0a9179630ff9b909c8 commit: 8c62c63c81a738a960c6d3c5cf66d075296b038c Author: Andreas Sturmlechner gentoo org> AuthorDate: Sun Jul 26 20:01:23 2020 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Sun Jul 26 20:02:38 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8c62c63c dev-libs/appstream: Fix build with older GCC Reported-by: Dion Moult thinkmoult.com> Closes: https://bugs.gentoo.org/733774 Package-Manager: Portage-3.0.0, Repoman-2.3.23 Signed-off-by: Andreas Sturmlechner gentoo.org> dev-libs/appstream/appstream-0.12.11-r1.ebuild | 80 ++++++++++++++++++++ .../appstream-0.12.11-disable-Werror-flags.patch | 12 +++ .../files/appstream-0.12.11-no-highlight.js.patch | 86 ++++++++++++++++++++++ ...12.11-qt-add-missing-provided-kindid-enum.patch | 24 ++++++ 4 files changed, 202 insertions(+) diff --git a/dev-libs/appstream/appstream-0.12.11-r1.ebuild b/dev-libs/appstream/appstream-0.12.11-r1.ebuild new file mode 100644 index 00000000000..c2dca084f14 --- /dev/null +++ b/dev-libs/appstream/appstream-0.12.11-r1.ebuild @@ -0,0 +1,80 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit meson xdg-utils + +if [[ ${PV} = *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/ximion/${PN}" +else + SRC_URI="https://www.freedesktop.org/software/appstream/releases/AppStream-${PV}.tar.xz" + KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" + S="${WORKDIR}/AppStream-${PV}" +fi + +DESCRIPTION="Cross-distro effort for providing metadata for software in the Linux ecosystem" +HOMEPAGE="https://www.freedesktop.org/wiki/Distributions/AppStream/" + +LICENSE="LGPL-2.1+ GPL-2+" +# check as_api_level +SLOT="0/4" +IUSE="apt doc +introspection qt5 test" +RESTRICT="!test? ( test )" + +BDEPEND=" + dev-libs/appstream-glib + dev-libs/libxslt + dev-util/itstool + >=sys-devel/gettext-0.19.8 + doc? ( app-text/docbook-xml-dtd:4.5 ) + test? ( dev-qt/linguist-tools:5 ) +" +RDEPEND=" + dev-db/lmdb:= + >=dev-libs/glib-2.58:2 + dev-libs/libxml2:2 + dev-libs/libyaml + dev-libs/snowball-stemmer + >=net-libs/libsoup-2.56:2.4 + introspection? ( >=dev-libs/gobject-introspection-1.56:= ) + qt5? ( dev-qt/qtcore:5 ) +" +DEPEND="${RDEPEND} + test? ( qt5? ( dev-qt/qttest:5 ) ) +" + +PATCHES=( + "${FILESDIR}"/${P}-no-highlight.js.patch + "${FILESDIR}"/${P}-qt-add-missing-provided-kindid-enum.patch + "${FILESDIR}"/${P}-disable-Werror-flags.patch # bug 733774 +) + +src_prepare() { + default + sed -e "/^as_doc_target_dir/s/appstream/${PF}/" -i docs/meson.build || die + if ! use test; then + sed -e "/^subdir.*tests/s/^/#DONT /" -i {,qt/}meson.build || die # bug 675944 + fi + rm docs/html/static/js/HighlightJS.LICENSE \ + docs/html/static/js/highlight.min.js || die # incompatible license +} + +src_configure() { + xdg_environment_reset + + local emesonargs=( + -Dapidocs=false + -Ddocs=false + -Dmaintainer=false + -Dstemming=true + -Dvapi=false + -Dapt-support=$(usex apt true false) + -Dinstall-docs=$(usex doc true false) + -Dgir=$(usex introspection true false) + -Dqt=$(usex qt5 true false) + ) + + meson_src_configure +} diff --git a/dev-libs/appstream/files/appstream-0.12.11-disable-Werror-flags.patch b/dev-libs/appstream/files/appstream-0.12.11-disable-Werror-flags.patch new file mode 100644 index 00000000000..0f887432deb --- /dev/null +++ b/dev-libs/appstream/files/appstream-0.12.11-disable-Werror-flags.patch @@ -0,0 +1,12 @@ +--- a/meson.build 2020-07-26 21:29:04.621544863 +0200 ++++ b/meson.build 2020-07-26 21:34:06.682233266 +0200 +@@ -52,9 +52,6 @@ + add_global_arguments(maintainer_c_args, language: 'cpp') + endif + +-# a few compiler warning flags we always want enabled +-add_global_arguments('-Werror=implicit-function-declaration', '-Wno-unused-parameter', language: 'c') +-add_global_arguments('-Wno-unused-parameter', '-Wno-error=deprecated-copy', language: 'cpp') + add_global_arguments('-DAS_COMPILATION', language : 'c') + + # diff --git a/dev-libs/appstream/files/appstream-0.12.11-no-highlight.js.patch b/dev-libs/appstream/files/appstream-0.12.11-no-highlight.js.patch new file mode 100644 index 00000000000..66b388061a4 --- /dev/null +++ b/dev-libs/appstream/files/appstream-0.12.11-no-highlight.js.patch @@ -0,0 +1,86 @@ +From 5ddf424d9b5713bd71c34b5ab6bbd10ad7b74bbc Mon Sep 17 00:00:00 2001 +From: Matthias Klumpp +Date: Tue, 12 May 2020 20:00:19 +0200 +Subject: [PATCH] Never ship with an embedded convenience copy of Highlight.js + +This should make Debian happy. +--- + docs/doc-build-helper.py | 10 +------- + docs/meson.build | 12 ++++++++++ + docs/style/static/js/HighlightJS.LICENSE | 29 ------------------------ + docs/style/static/js/INFO.md | 8 +++++++ + 4 files changed, 21 insertions(+), 38 deletions(-) + delete mode 100644 docs/style/static/js/HighlightJS.LICENSE + create mode 100644 docs/style/static/js/INFO.md + +diff --git a/docs/doc-build-helper.py b/docs/doc-build-helper.py +index ce46303d..c29cce2d 100755 +--- a/docs/doc-build-helper.py ++++ b/docs/doc-build-helper.py +@@ -29,10 +29,6 @@ + from pathlib import Path + + +-# additional JavaScript from system locations, we use it if available +-EXTRA_JS = [['/usr/share/javascript/highlight.js/highlight.min.js', +- 'highlight.min.js']] +- + # additional CSS from system locations, we use it if available + EXTRA_CSS = [['/usr/share/javascript/highlight.js/styles/routeros.css', + 'highlight.css']] +@@ -64,11 +60,7 @@ def daps_build(src_dir, project_name, daps_exe): + shutil.copy(os.path.join(src_dir, 'images', 'src', 'svg', 'appstream-logo.svg'), + os.path.join(html_out_dir, 'images')) + +- # copy extra JS and CSS if it is available +- for js_fname in EXTRA_JS: +- if os.path.exists(js_fname[0]): +- shutil.copy(js_fname[0], os.path.join(html_out_dir, 'static', +- 'js', js_fname[1])) ++ # copy extra CSS if it is available + for css_fname in EXTRA_CSS: + if os.path.exists(css_fname[0]): + shutil.copy(css_fname[0], os.path.join(html_out_dir, 'static', +diff --git a/docs/meson.build b/docs/meson.build +index 1ae5fc46..d4543fdd 100644 +--- a/docs/meson.build ++++ b/docs/meson.build +@@ -101,6 +101,12 @@ if get_option('docs') + + if get_option('install-docs') + install_subdir('html', install_dir: as_doc_target_dir) ++ ++ meson.add_install_script('sh', '-c', ++ 'if [ -f "@0@" ]; then mkdir -p $DESTDIR/@1@ && ln -sf @0@ $DESTDIR/@1@; fi' ++ .format('/usr/share/javascript/highlight.js/highlight.min.js', ++ join_paths(get_option('prefix'), as_doc_target_dir, 'html', 'static', 'js')) ++ ) + endif + + # add an extra testcase for documentation validation +@@ -114,5 +120,11 @@ elif get_option('install-docs') + if run_command('[', '-d', join_paths(meson.current_source_dir(), 'html'), ']').returncode() == 0 + # install documentation, if it exists + install_subdir('html', install_dir: as_doc_target_dir) ++ ++ meson.add_install_script('sh', '-c', ++ 'if [ -f "@0@" ]; then mkdir -p $DESTDIR/@1@ && ln -sf @0@ $DESTDIR/@1@; fi' ++ .format('/usr/share/javascript/highlight.js/highlight.min.js', ++ join_paths(get_option('prefix'), as_doc_target_dir, 'html', 'static', 'js')) ++ ) + endif + endif +diff --git a/docs/style/static/js/INFO.md b/docs/style/static/js/INFO.md +new file mode 100644 +index 00000000..6e95673b +--- /dev/null ++++ b/docs/style/static/js/INFO.md +@@ -0,0 +1,8 @@ ++### AppStream Documentation JS Directory ++ ++You can place a minified copy of [Highlight.js](https://highlightjs.org/) in this ++directory to enable source-code highlighting in the documentation. ++ ++In case a system-wide copy of `highlight.min.js` and its CSS files exists in ++`/usr/share/javascript/highlight.js/`, the buildsystem will automatically detect that ++and create symbolic links to these files when installing the documentation. diff --git a/dev-libs/appstream/files/appstream-0.12.11-qt-add-missing-provided-kindid-enum.patch b/dev-libs/appstream/files/appstream-0.12.11-qt-add-missing-provided-kindid-enum.patch new file mode 100644 index 00000000000..e96b2a3856d --- /dev/null +++ b/dev-libs/appstream/files/appstream-0.12.11-qt-add-missing-provided-kindid-enum.patch @@ -0,0 +1,24 @@ +From 36f71e78f033fdb5bb880825b878b7dab31c0a73 Mon Sep 17 00:00:00 2001 +From: Aleix Pol +Date: Mon, 1 Jun 2020 13:25:25 +0200 +Subject: [PATCH] qt: add missing Provided::KindId enum + +It was never added to the Qt interface +--- + qt/provided.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/qt/provided.h b/qt/provided.h +index 1e3ba317..8e350fb0 100644 +--- a/qt/provided.h ++++ b/qt/provided.h +@@ -59,7 +59,8 @@ class APPSTREAMQT_EXPORT Provided { + KindDBusSystemService, + KindDBusUserService, + KindFirmwareRuntime, +- KindFirmwareFlashed ++ KindFirmwareFlashed, ++ KindId, + }; + Q_ENUM(Kind) +