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) server-digest SHA256) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 720E315808B for ; Sun, 20 Feb 2022 18:39:26 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 882C3E0843; Sun, 20 Feb 2022 18:39:25 +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 6553FE0843 for ; Sun, 20 Feb 2022 18:39:25 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (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 58BC03437A3 for ; Sun, 20 Feb 2022 18:39:24 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id B92992CC for ; Sun, 20 Feb 2022 18:39:22 +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: <1645382356.9e7bddcce802a7ec8e3e731592fa18e3ba5ff0a2.mattst88@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-misc/tracker/files/, app-misc/tracker/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-misc/tracker/files/tracker-3.2.1-build-Add-an-option-to-control-building-tests.patch app-misc/tracker/tracker-3.2.1.ebuild X-VCS-Directories: app-misc/tracker/ app-misc/tracker/files/ X-VCS-Committer: mattst88 X-VCS-Committer-Name: Matt Turner X-VCS-Revision: 9e7bddcce802a7ec8e3e731592fa18e3ba5ff0a2 X-VCS-Branch: master Date: Sun, 20 Feb 2022 18:39:22 +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: f56dc6b2-b245-4243-8837-445eb06e933e X-Archives-Hash: ce6dcc4418b9e610f0b92d113495e998 commit: 9e7bddcce802a7ec8e3e731592fa18e3ba5ff0a2 Author: Matt Turner gentoo org> AuthorDate: Sun Feb 20 18:38:56 2022 +0000 Commit: Matt Turner gentoo org> CommitDate: Sun Feb 20 18:39:16 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9e7bddcc app-misc/tracker: Fix test dependencies Closes: https://bugs.gentoo.org/832141 Signed-off-by: Matt Turner gentoo.org> ...d-Add-an-option-to-control-building-tests.patch | 69 ++++++++++++++++++++++ app-misc/tracker/tracker-3.2.1.ebuild | 3 + 2 files changed, 72 insertions(+) diff --git a/app-misc/tracker/files/tracker-3.2.1-build-Add-an-option-to-control-building-tests.patch b/app-misc/tracker/files/tracker-3.2.1-build-Add-an-option-to-control-building-tests.patch new file mode 100644 index 000000000000..9480a6269c75 --- /dev/null +++ b/app-misc/tracker/files/tracker-3.2.1-build-Add-an-option-to-control-building-tests.patch @@ -0,0 +1,69 @@ +From db36d010737d5eeceff300e3dd5e315c5d0382a2 Mon Sep 17 00:00:00 2001 +From: Matt Turner +Date: Wed, 16 Feb 2022 10:59:33 -0800 +Subject: [PATCH] build: Add an option to control building tests + +Commit 8569c99d2926 ("Look for a Python installation with the tap +module") correctly added a dependency on the gi Python module for tests. +Commit 51ca035697a4 ("Make tracker:endpoint test work on macOS") +restructured Python probing by moving it to the top-level meson.build. + +These two commits have the side-effect of exposing the fact that the +gi Python module is really only a test dependency, and should not be +required if building without tests. + +As such, add a -Dtests=bool option to disable building tests. This +reduces the number of ninja targets from 232 to 188 on my non-test +build. +--- + meson.build | 13 +++++++++---- + meson_options.txt | 2 ++ + 2 files changed, 11 insertions(+), 4 deletions(-) + +diff --git a/meson.build b/meson.build +index 4e59b8240..f4dd58fd4 100644 +--- a/meson.build ++++ b/meson.build +@@ -75,9 +75,12 @@ if get_option('man') + a2x = find_program('a2x') + endif + +-py_modules = ['gi'] +-if get_option('tests_tap_protocol') +- py_modules += 'tap' ++py_modules = [] ++if get_option('tests') ++ py_modules += 'gi' ++ if get_option('tests_tap_protocol') ++ py_modules += 'tap' ++ endif + endif + python = import('python').find_installation('python3', modules: py_modules) + +@@ -358,7 +361,9 @@ tracker_uninstalled_nepomuk_ontologies_dir = join_paths(meson.current_source_dir + tracker_uninstalled_stop_words_dir = join_paths(meson.current_source_dir(), 'src', 'libtracker-common', 'stop-words') + tracker_uninstalled_testutils_dir = join_paths(meson.current_source_dir(), 'utils') + +-subdir('tests') ++if get_option('tests') ++ subdir('tests') ++endif + subdir('examples') + + subdir('po') +diff --git a/meson_options.txt b/meson_options.txt +index a7e647d02..ec8ea8bc2 100644 +--- a/meson_options.txt ++++ b/meson_options.txt +@@ -20,6 +20,8 @@ option('systemd_user_services', type: 'boolean', value: true, yield: true, + description: 'Whether to install systemd user .service files') + option('systemd_user_services_dir', type: 'string', value: '', yield: true, + description: 'Directory to install systemd user unit files (or empty to use default)') ++option('tests', type: 'boolean', value: true, ++ description: 'Whether to build tests') + option('test_utils', type: 'boolean', value: true, + description: 'Whether to install the trackertestutils Python package') + option('test_utils_dir', type: 'string', value: '', +-- +2.34.1 + diff --git a/app-misc/tracker/tracker-3.2.1.ebuild b/app-misc/tracker/tracker-3.2.1.ebuild index 81ebe3d808b7..534f1b18334a 100644 --- a/app-misc/tracker/tracker-3.2.1.ebuild +++ b/app-misc/tracker/tracker-3.2.1.ebuild @@ -43,6 +43,7 @@ BDEPEND=" >=sys-devel/gettext-0.19.8 virtual/pkgconfig test? ( + $(python_gen_any_dep 'dev-python/pygobject[${PYTHON_USEDEP}]') $(python_gen_any_dep 'dev-python/tappy[${PYTHON_USEDEP}]') ) ${PYTHON_DEPS} @@ -52,6 +53,7 @@ PDEPEND="miners? ( >=app-misc/tracker-miners-${PV_SERIES} )" PATCHES=( "${FILESDIR}"/${PN}-3.1.1-Fix-asciidoc-manpage.xsl-location.patch "${FILESDIR}"/${PN}-3.2.1-Add-config-options-for-libsoup.patch + "${FILESDIR}"/${PN}-3.2.1-build-Add-an-option-to-control-building-tests.patch ) function inotify_enabled() { @@ -94,6 +96,7 @@ src_configure() { -Dunicode_support=icu -Dbash_completion_dir="$(get_bashcompdir)" -Dsystemd_user_services_dir="$(systemd_get_userunitdir)" + $(meson_use test tests) -Dintrospection=enabled -Dlibsoup2=enabled -Dlibsoup3=disabled