summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-05-09 17:01:09 +0100
committerSam James <sam@gentoo.org>2023-05-09 18:46:17 +0100
commitdb12d7be4fb8e598047da65128b65246dd6a20dd (patch)
treeded55a7016a4c731f197e162a4e8b81b53bfe467
parentsys-kernel/gentoo-sources: drop 4.14.311 (diff)
downloadgentoo-db12d7be4fb8e598047da65128b65246dd6a20dd.tar.gz
gentoo-db12d7be4fb8e598047da65128b65246dd6a20dd.tar.bz2
gentoo-db12d7be4fb8e598047da65128b65246dd6a20dd.zip
app-arch/zchunk: conditionally build tests
Signed-off-by: Sam James <sam@gentoo.org>
-rw-r--r--app-arch/zchunk/zchunk-1.2.3.ebuild10
-rw-r--r--app-arch/zchunk/zchunk-9999.ebuild12
2 files changed, 21 insertions, 1 deletions
diff --git a/app-arch/zchunk/zchunk-1.2.3.ebuild b/app-arch/zchunk/zchunk-1.2.3.ebuild
index 78b7906664ab..e89d8926554d 100644
--- a/app-arch/zchunk/zchunk-1.2.3.ebuild
+++ b/app-arch/zchunk/zchunk-1.2.3.ebuild
@@ -18,6 +18,8 @@ fi
LICENSE="BSD-2"
SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
DEPEND="
app-arch/zstd:=
@@ -25,3 +27,11 @@ DEPEND="
dev-libs/openssl:=
"
RDEPEND="${DEPEND}"
+
+src_configure() {
+ local emesonargs=(
+ $(meson_use test tests)
+ )
+
+ meson_src_configure
+}
diff --git a/app-arch/zchunk/zchunk-9999.ebuild b/app-arch/zchunk/zchunk-9999.ebuild
index 76677dce82f5..e89d8926554d 100644
--- a/app-arch/zchunk/zchunk-9999.ebuild
+++ b/app-arch/zchunk/zchunk-9999.ebuild
@@ -13,11 +13,13 @@ if [[ ${PV} == 9999 ]]; then
EGIT_REPO_URI="https://github.com/zchunk/zchunk.git"
else
SRC_URI="https://github.com/zchunk/zchunk/archive/${PV}.tar.gz -> ${P}.tar.gz"
- KEYWORDS="~amd64"
+ KEYWORDS="~amd64 ~x86"
fi
LICENSE="BSD-2"
SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
DEPEND="
app-arch/zstd:=
@@ -25,3 +27,11 @@ DEPEND="
dev-libs/openssl:=
"
RDEPEND="${DEPEND}"
+
+src_configure() {
+ local emesonargs=(
+ $(meson_use test tests)
+ )
+
+ meson_src_configure
+}