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 5C1DF158041 for ; Wed, 13 Mar 2024 13:05:31 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6ECBDE29BF; Wed, 13 Mar 2024 13:05:30 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 4EAEDE29BF for ; Wed, 13 Mar 2024 13:05:30 +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)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 5CB3E335C2E for ; Wed, 13 Mar 2024 13:05:29 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 75CC213DE for ; Wed, 13 Mar 2024 13:05:27 +0000 (UTC) From: "Matthew Smith" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matthew Smith" Message-ID: <1710335122.81ffe8992f23ab1e45e326af6833192384e7dcc7.matthew@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: media-gfx/renderdoc/ X-VCS-Repository: repo/gentoo X-VCS-Files: media-gfx/renderdoc/renderdoc-1.30-r2.ebuild X-VCS-Directories: media-gfx/renderdoc/ X-VCS-Committer: matthew X-VCS-Committer-Name: Matthew Smith X-VCS-Revision: 81ffe8992f23ab1e45e326af6833192384e7dcc7 X-VCS-Branch: master Date: Wed, 13 Mar 2024 13:05:27 +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: 4f346bdc-6a6e-4043-9eb3-bd365b4af049 X-Archives-Hash: adcb88e7f965724dcd01e6037f100aa8 commit: 81ffe8992f23ab1e45e326af6833192384e7dcc7 Author: Matthew Smith gentoo org> AuthorDate: Wed Mar 13 12:56:43 2024 +0000 Commit: Matthew Smith gentoo org> CommitDate: Wed Mar 13 13:05:22 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=81ffe899 media-gfx/renderdoc: drop pyside2 integration Bug: https://bugs.gentoo.org/926549 Signed-off-by: Matthew Smith gentoo.org> media-gfx/renderdoc/renderdoc-1.30-r2.ebuild | 188 +++++++++++++++++++++++++++ 1 file changed, 188 insertions(+) diff --git a/media-gfx/renderdoc/renderdoc-1.30-r2.ebuild b/media-gfx/renderdoc/renderdoc-1.30-r2.ebuild new file mode 100644 index 000000000000..e140b534e508 --- /dev/null +++ b/media-gfx/renderdoc/renderdoc-1.30-r2.ebuild @@ -0,0 +1,188 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +# The swig fork is required for compatibility with both provided and +# 3rd-party Python scripts. Required patch was sent to upstream in +# 2014: https://github.com/swig/swig/pull/251 +MY_SWIG_VER=7 +MY_SWIG=swig-${PN}-${MY_SWIG_VER} + +AUTOTOOLS_AUTO_DEPEND="no" +DOCS_BUILDER="sphinx" +DOCS_DIR="docs" +PYTHON_COMPAT=( python3_{9..12} ) +inherit autotools cmake flag-o-matic optfeature python-single-r1 docs qmake-utils verify-sig xdg + +DESCRIPTION="A stand-alone graphics debugging tool" +HOMEPAGE="https://renderdoc.org https://github.com/baldurk/renderdoc" +SRC_URI=" + https://github.com/baldurk/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz + qt5? ( https://github.com/baldurk/swig/archive/${PN}-modified-${MY_SWIG_VER}.tar.gz -> ${MY_SWIG}.tar.gz ) + verify-sig? ( https://github.com/baldurk/renderdoc/releases/download/v${PV}/v${PV}.tar.gz.asc -> ${P}.tar.gz.asc ) +" + +# renderdoc: MIT +# + cmdline: BSD (not compatible with upstream lib) +# + farm fresh icons: CC-BY-3.0 +# + half: MIT (not compatible with system dev-libs/half) +# + include-bin ZLIB (upstream doesn't exist anymore, maintained in tree) +# + md5: public-domain +# + plthook: BSD-2 +# + pugixml: MIT +# + radeon gpu analyzer: MIT +# + source code pro: OFL-1.1 +# + stb: public-domain +# + tinyfiledialogs: ZLIB +# + glslang: BSD +# + docs? ( sphinx.paramlinks: MIT ) +# swig: GPL-3+ BSD BSD-2 +LICENSE="BSD BSD-2 CC-BY-3.0 GPL-3+ MIT OFL-1.1 public-domain ZLIB" +SLOT="0" +KEYWORDS="~amd64" +IUSE="qt5" +REQUIRED_USE="doc? ( qt5 ) qt5? ( ${PYTHON_REQUIRED_USE} )" + +RDEPEND=" + app-arch/lz4:= + app-arch/zstd:= + dev-libs/miniz:= + x11-libs/libX11 + x11-libs/libxcb:= + x11-libs/xcb-util-keysyms + virtual/opengl + qt5? ( + ${PYTHON_DEPS} + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtnetwork:5[ssl] + dev-qt/qtsvg:5 + dev-qt/qtwidgets:5 + dev-qt/qtx11extras:5 + ) +" +DEPEND="${RDEPEND}" +# qtcore provides qmake, which is required to build the qrenderdoc gui. +BDEPEND=" + x11-base/xorg-proto + virtual/pkgconfig + qt5? ( + ${AUTOTOOLS_DEPEND} + ${PYTHON_DEPS} + dev-libs/libpcre + dev-qt/qtcore:5 + app-alternatives/yacc + ) + verify-sig? ( sec-keys/openpgp-keys-baldurkarlsson ) +" + +PATCHES=( + # The analytics seem very reasonable, and even without this patch + # they are NOT sent before the user accepts. But default the + # selection to off, just in case. + "${FILESDIR}"/${PN}-1.18-analytics-off.patch + + # Only search for PySide2 if pyside2 USE flag is set. + # Bug #833627 + "${FILESDIR}"/${PN}-1.18-conditional-pyside.patch + + # Pass CXXFLAGS and LDFLAGS through to qmake when qrenderdoc is + # built. + "${FILESDIR}"/${PN}-1.18-system-flags.patch + + # Needed to prevent sandbox violations during build. + "${FILESDIR}"/${PN}-1.27-env-home.patch + + "${FILESDIR}"/${PN}-1.30-r1-system-compress.patch +) + +DOCS=( util/LINUX_DIST_README ) + +VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/baldurkarlsson.gpg + +pkg_setup() { + use qt5 && python-single-r1_pkg_setup +} + +src_unpack() { + if use verify-sig; then + verify-sig_verify_detached "${DISTDIR}"/${P}.tar.gz{,.asc} + fi + + # Do not unpack the swig sources here. CMake will do that if + # required. + unpack ${P}.tar.gz +} + +src_prepare() { + cmake_src_prepare + + # Remove the calls to install the documentation files. Instead, + # install them with einstalldocs. + sed -i '/share\/doc\/renderdoc/d' \ + "${S}"/CMakeLists.txt "${S}"/qrenderdoc/CMakeLists.txt \ + || die 'sed remove doc install failed' + + # Assumes that the build directory is "${S}"/build, which it is not. + sed -i "s|../build/lib|${BUILD_DIR}/lib|" \ + "${S}"/docs/conf.py \ + || die 'sed patch doc sys.path failed' + + # Bug #836235 + sed -i '/#include ' \ + "${S}"/renderdoc/os/os_specific.h \ + || die 'sed include time.h failed' +} + +src_configure() { + local mycmakeargs=( + # Build system does not know that this is a tagged release, as + # we just have the tarball and not the git repository. + -DBUILD_VERSION_STABLE=ON + + -DENABLE_EGL=ON + -DENABLE_GL=ON + -DENABLE_GLES=ON + -DENABLE_PYRENDERDOC=$(usex qt5) + -DENABLE_QRENDERDOC=$(usex qt5) + -DENABLE_VULKAN=ON + + # Upstream says that this option is unsupported and should not + # be used yet. + -DENABLE_UNSUPPORTED_EXPERIMENTAL_POSSIBLY_BROKEN_WAYLAND=OFF + + -DENABLE_XCB=ON + -DENABLE_XLIB=ON + + # renderdoc_capture.json is installed here + -DVULKAN_LAYER_FOLDER="${EPREFIX}"/etc/vulkan/implicit_layer.d + ) + + use qt5 && mycmakeargs+=( + -DPython3_EXECUTABLE="${PYTHON}" + -DRENDERDOC_SWIG_PACKAGE="${DISTDIR}"/${MY_SWIG}.tar.gz + + # Needed after qtchooser removal, bug #836474. + -DQMAKE_QT5_COMMAND="$(qt5_get_bindir)"/qmake + + # Bug #926549 + -DQRENDERDOC_ENABLE_PYSIDE2=OFF + ) + + # Lots of type mismatch issues. + filter-lto + + cmake_src_configure +} + +src_compile() { + cmake_src_compile + docs_compile +} + +pkg_postinst() { + xdg_pkg_postinst + optfeature "android remote contexts" dev-util/android-tools + optfeature "vulkan contexts" media-libs/vulkan-loader +}