# Copyright 2016-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 PYTHON_COMPAT=( python3_{10..13} pypy3 ) DISTUTILS_USE_PEP517=setuptools inherit bash-completion-r1 edo distutils-r1 flag-o-matic toolchain-funcs if [[ ${PV} = *9999* ]]; then EGIT_REPO_URI="https://github.com/mesonbuild/meson" inherit ninja-utils git-r3 BDEPEND=" ${NINJA_DEPEND} $(python_gen_any_dep 'dev-python/pyyaml[${PYTHON_USEDEP}]') " else inherit verify-sig MY_PV=${PV/_/} MY_P=${P/_/} S=${WORKDIR}/${MY_P} SRC_URI=" https://github.com/mesonbuild/meson/releases/download/${MY_PV}/${MY_P}.tar.gz verify-sig? ( https://github.com/mesonbuild/meson/releases/download/${MY_PV}/${MY_P}.tar.gz.asc ) https://github.com/mesonbuild/meson/releases/download/${MY_PV}/meson-reference.3 -> meson-reference-${MY_PV}.3 " BDEPEND="verify-sig? ( sec-keys/openpgp-keys-jpakkane )" VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/jpakkane.gpg if [[ ${PV} != *_rc* ]] ; then KEYWORDS="~alpha amd64 ~arm ~arm64 hppa ~loong ~m68k ~mips ~ppc ppc64 ~riscv ~s390 sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris" fi fi DESCRIPTION="Open source build system" HOMEPAGE="https://mesonbuild.com/" LICENSE="Apache-2.0" SLOT="0" IUSE="test" RESTRICT="!test? ( test )" DEPEND=" test? ( dev-libs/glib:2 dev-libs/gobject-introspection app-alternatives/ninja dev-vcs/git sys-libs/zlib[static-libs(+)] virtual/pkgconfig ) " RDEPEND=" !/dev/null) ${EPYTHON} -u run_tests.py ) || die "Testing failed with ${EPYTHON}" } python_install_all() { distutils-r1_python_install_all insinto /usr/share/vim/vimfiles doins -r data/syntax-highlighting/vim/{ftdetect,indent,syntax} insinto /usr/share/zsh/site-functions doins data/shell-completions/zsh/_meson dobashcomp data/shell-completions/bash/meson if [[ ${PV} = *9999* ]]; then DESTDIR="${ED}" eninja -C docs/builddir install else newman "${DISTDIR}"/meson-reference-${MY_PV}.3 meson-reference.3 fi }