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.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id ACF4315ACFB for ; Mon, 10 Apr 2023 12:39:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D9E84E077A; Mon, 10 Apr 2023 12:39:13 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id B020AE077A for ; Mon, 10 Apr 2023 12:39:13 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DCC25340CCB for ; Mon, 10 Apr 2023 12:39:12 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 0AB918C6 for ; Mon, 10 Apr 2023 12:39:11 +0000 (UTC) From: "Matt Turner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matt Turner" Message-ID: <1681130272.ffa74c36cc92a3f4728892b8378e594df07028f6.mattst88@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: x11-libs/vte/files/, x11-libs/vte/ X-VCS-Repository: repo/gentoo X-VCS-Files: x11-libs/vte/files/vte-0.70-integer-value-is-outside-the-valid-range-clang-16.patch x11-libs/vte/vte-0.70.3-r1.ebuild X-VCS-Directories: x11-libs/vte/ x11-libs/vte/files/ X-VCS-Committer: mattst88 X-VCS-Committer-Name: Matt Turner X-VCS-Revision: ffa74c36cc92a3f4728892b8378e594df07028f6 X-VCS-Branch: master Date: Mon, 10 Apr 2023 12:39:11 +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: 5e50975f-8d94-47e3-a779-8eb53ea2de08 X-Archives-Hash: 4bf39ce5ddc2d536c59e13716ca57b85 commit: ffa74c36cc92a3f4728892b8378e594df07028f6 Author: brahmajit das gmail com> AuthorDate: Sat Apr 1 07:56:47 2023 +0000 Commit: Matt Turner gentoo org> CommitDate: Mon Apr 10 12:37:52 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ffa74c36 x11-libs/vte: Fix clang 16 build failure with -Wenum-constexpr-conversion GSpawnFlags is enum with max value 1 << 15 which means it fits into a short int, however here we are OR'ing VTE_SPAWN_* as well which have higher values Closes: https://bugs.gentoo.org/895834 Signed-off-by: brahmajit das gmail.com> Signed-off-by: Matt Turner gentoo.org> ...value-is-outside-the-valid-range-clang-16.patch | 47 +++++++++ x11-libs/vte/vte-0.70.3-r1.ebuild | 105 +++++++++++++++++++++ 2 files changed, 152 insertions(+) diff --git a/x11-libs/vte/files/vte-0.70-integer-value-is-outside-the-valid-range-clang-16.patch b/x11-libs/vte/files/vte-0.70-integer-value-is-outside-the-valid-range-clang-16.patch new file mode 100644 index 000000000000..ab6aceae196c --- /dev/null +++ b/x11-libs/vte/files/vte-0.70-integer-value-is-outside-the-valid-range-clang-16.patch @@ -0,0 +1,47 @@ +# From 9400d41660e6c27b672f9c77855d736581f499bf Mon Sep 17 00:00:00 2001 +# From: Khem Raj +# Date: Thu, 2 Mar 2023 22:57:00 +0100 +# Subject: [PATCH] pty: Do not typecast to GSpawnFlags +# +# GSpawnFlags is enum with max value 1 << 15 which means it fits into +# a short, however here we are oring VTE_SPAWN_* as well which have +# higher values (by design). This fixes a compile error on clang 16 +# with the -Wenum-constexpr-conversion flag. +# +# Fixes: https://gitlab.gnome.org/GNOME/vte/-/issues/2618 +# (cherry picked from commit 9b41cd1014299d01111b64b705f013e28398821a) +# +# Also refer: https://gitlab.gnome.org/GNOME/vte/-/commit/9400d41660e6c27b672f9c77855d736581f499bf.patch +--- a/src/vtepty.cc ++++ b/src/vtepty.cc +@@ -574,18 +574,18 @@ catch (...) + static constexpr inline auto + all_spawn_flags() noexcept + { +- return GSpawnFlags(G_SPAWN_LEAVE_DESCRIPTORS_OPEN | +- G_SPAWN_DO_NOT_REAP_CHILD | +- G_SPAWN_SEARCH_PATH | +- G_SPAWN_STDOUT_TO_DEV_NULL | +- G_SPAWN_STDERR_TO_DEV_NULL | +- G_SPAWN_CHILD_INHERITS_STDIN | +- G_SPAWN_FILE_AND_ARGV_ZERO | +- G_SPAWN_SEARCH_PATH_FROM_ENVP | +- G_SPAWN_CLOEXEC_PIPES | +- VTE_SPAWN_NO_PARENT_ENVV | +- VTE_SPAWN_NO_SYSTEMD_SCOPE | +- VTE_SPAWN_REQUIRE_SYSTEMD_SCOPE); ++ return (G_SPAWN_LEAVE_DESCRIPTORS_OPEN | ++ G_SPAWN_DO_NOT_REAP_CHILD | ++ G_SPAWN_SEARCH_PATH | ++ G_SPAWN_STDOUT_TO_DEV_NULL | ++ G_SPAWN_STDERR_TO_DEV_NULL | ++ G_SPAWN_CHILD_INHERITS_STDIN | ++ G_SPAWN_FILE_AND_ARGV_ZERO | ++ G_SPAWN_SEARCH_PATH_FROM_ENVP | ++ G_SPAWN_CLOEXEC_PIPES | ++ VTE_SPAWN_NO_PARENT_ENVV | ++ VTE_SPAWN_NO_SYSTEMD_SCOPE | ++ VTE_SPAWN_REQUIRE_SYSTEMD_SCOPE); + } + + static constexpr inline auto diff --git a/x11-libs/vte/vte-0.70.3-r1.ebuild b/x11-libs/vte/vte-0.70.3-r1.ebuild new file mode 100644 index 000000000000..9f1b6512767d --- /dev/null +++ b/x11-libs/vte/vte-0.70.3-r1.ebuild @@ -0,0 +1,105 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +PYTHON_COMPAT=( python3_{9..11} ) + +inherit gnome.org meson python-any-r1 vala xdg + +DESCRIPTION="Library providing a virtual terminal emulator widget" +HOMEPAGE="https://wiki.gnome.org/Apps/Terminal/VTE" + +# Once SIXEL support ships (0.66 or later), might need xterm license (but code might be considered upgraded to LGPL-3+) +LICENSE="LGPL-3+ GPL-3+" +SLOT="2.91" # vte_api_version in meson.build +IUSE="+crypt debug gtk-doc +icu +introspection systemd +vala vanilla" +KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86" +REQUIRED_USE=" + gtk-doc? ( introspection ) + vala? ( introspection ) +" + +# Upstream is hostile and refuses to upload tarballs. +SRC_URI="https://gitlab.gnome.org/GNOME/${PN}/-/archive/${PV}/${P}.tar.bz2" +SRC_URI="${SRC_URI} !vanilla? ( https://dev.gentoo.org/~mattst88/distfiles/${PN}-0.70.0-command-notify.patch.xz )" + +DEPEND=" + >=x11-libs/gtk+-3.24.22:3[introspection?] + >=dev-libs/fribidi-1.0.0 + >=dev-libs/glib-2.52:2 + crypt? ( >=net-libs/gnutls-3.2.7:0= ) + icu? ( dev-libs/icu:= ) + >=x11-libs/pango-1.22.0 + >=dev-libs/libpcre2-10.21:= + systemd? ( >=sys-apps/systemd-220:= ) + sys-libs/zlib + introspection? ( >=dev-libs/gobject-introspection-1.56:= ) + x11-libs/pango[introspection?] +" +RDEPEND="${DEPEND} + ~gui-libs/vte-common-${PV}[systemd?] +" +BDEPEND=" + ${PYTHON_DEPS} + dev-libs/libxml2:2 + dev-util/glib-utils + gtk-doc? ( dev-util/gi-docgen ) + >=sys-devel/gettext-0.19.8 + virtual/pkgconfig + vala? ( $(vala_depend) ) +" + +PATCHES=( + "${FILESDIR}"/$PN-0.70-integer-value-is-outside-the-valid-range-clang-16.patch +) + +src_prepare() { + default + use vala && vala_setup + xdg_environment_reset + + use elibc_musl && eapply "${FILESDIR}"/${PN}-0.66.2-musl-W_EXITCODE.patch + + if ! use vanilla; then + # Part of https://src.fedoraproject.org/rpms/vte291/raw/f37/f/vte291-cntnr-precmd-preexec-scroll.patch + # Adds OSC 777 support for desktop notifications in gnome-terminal or elsewhere + eapply "${WORKDIR}"/${PN}-0.70.0-command-notify.patch + fi + + # -Ddebugg option enables various debug support via VTE_DEBUG, but also ggdb3; strip the latter + sed -e '/ggdb3/d' -i meson.build || die + sed -i 's/vte_gettext_domain = vte_api_name/vte_gettext_domain = vte_gtk3_api_name/' meson.build || die +} + +src_configure() { + local emesonargs=( + -Da11y=true + $(meson_use debug debugg) + $(meson_use gtk-doc docs) + $(meson_use introspection gir) + -Dfribidi=true # pulled in by pango anyhow + -Dglade=true + $(meson_use crypt gnutls) + -Dgtk3=true + -Dgtk4=false + $(meson_use icu) + $(meson_use systemd _systemd) + $(meson_use vala vapi) + ) + meson_src_configure +} + +src_install() { + meson_install # not meson_src_install because this would include einstalldocs, which would result in file collisions with gui-libs/vte + # Remove files that are provided by gui-libs/vte-common + rm "${ED}"/usr/libexec/vte-urlencode-cwd || die + rm "${ED}"/etc/profile.d/vte.sh || die + rm "${ED}"/etc/profile.d/vte.csh || die + if use systemd; then + rm "${ED}"/usr/lib/systemd/user/vte-spawn-.scope.d/defaults.conf || die + fi + if use gtk-doc; then + mkdir -p "${ED}"/usr/share/gtk-doc/ || die + mv "${ED}"/usr/share/doc/vte-${SLOT} "${ED}"/usr/share/gtk-doc/vte-${SLOT}-gtk3 || die + fi +}