diff options
author | Martin Väth <martin@mvath.de> | 2017-07-26 13:28:41 +0200 |
---|---|---|
committer | Martin Väth <martin@mvath.de> | 2017-07-26 13:28:41 +0200 |
commit | 290b20d40b42f17c1dcf5ee1249acb69df5d586d (patch) | |
tree | 5361a686abc911bc45d8692bc07bdc37866cd536 /eclass | |
parent | app-portage/eix: Alpha version bump (diff) | |
download | mv-290b20d40b42f17c1dcf5ee1249acb69df5d586d.tar.gz mv-290b20d40b42f17c1dcf5ee1249acb69df5d586d.tar.bz2 mv-290b20d40b42f17c1dcf5ee1249acb69df5d586d.zip |
Reflect changes in documentation of meson_optional.eclass
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/ChangeLog | 5 | ||||
-rw-r--r-- | eclass/meson_optional.eclass | 28 |
2 files changed, 23 insertions, 10 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog index 7ea8ab31..79f24054 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -60,5 +60,8 @@ Support new package layout by manually specifying id with option -i 25 Jul 2017; Martin Väth <martin@mvath.de>: - Copy and meson.eclass from gentoo tree, since developers refuse to make it + Copy meson.eclass from gentoo tree, since developers refuse to make its use optionally: https://bugs.gentoo.org/show_bug.cgi?id=626054 + + 26 Jul 2017; Martin Väth <martin@mvath.de>: + Reflect changes in documentation of meson_optional.eclass diff --git a/eclass/meson_optional.eclass b/eclass/meson_optional.eclass index 157b52e0..53972b53 100644 --- a/eclass/meson_optional.eclass +++ b/eclass/meson_optional.eclass @@ -1,22 +1,24 @@ # Copyright 2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# @ECLASS: meson.eclass +# @ECLASS: meson_optional.eclass # @MAINTAINER: -# William Hubbs <williamh@gentoo.org> -# Mike Gilbert <floppym@gentoo.org> +# Martin Väth <martin<mvath.de> # @BLURB: common ebuild functions for meson-based packages # @DESCRIPTION: # This eclass contains the default phase functions for packages which # use the meson build system. +# The only difference to meson.eclass is that it supports also the +# MESON_AUTO_DEPEND variable which the gentoo maintainers refuse to include: +# https://bugs.gentoo.org/show_bug.cgi?id=626054 # # @EXAMPLE: -# Typical ebuild using meson.eclass: +# Typical ebuild using meson_optional.eclass: # # @CODE # EAPI=6 # -# inherit meson +# inherit meson_optional # # ... # @@ -51,6 +53,12 @@ _MESON_ECLASS=1 MESON_DEPEND=">=dev-util/meson-0.40.0 >=dev-util/ninja-1.7.2" + +# @ECLASS-VARIABLE: MESON_AUTO_DEPEND +# @DESCRIPTION: +# Set to 'no' to disable automatically adding to DEPEND. This lets +# ebuilds former conditional depends by using ${MESON_DEPEND} in +# their own DEPEND string. [ "${MESON_AUTO_DEPEND:=yes}" != yes ] || DEPEND=${MESON_DEPEND} # @ECLASS-VARIABLE: BUILD_DIR @@ -190,9 +198,11 @@ meson_src_install() { einstalldocs } -meson_optional_src_configure() { meson_src_configure; } -meson_optional_src_compile() { meson_src_compile; } -meson_optional_src_test() { meson_src_test; } -meson_optional_src_install() { meson_src_install; } +# This is not nice but necessary if we want to keep the names of meson.eclass: +# Without this, EXPORT_FUNCTIONS for these functions would not work... +meson_optional_src_configure() { meson_src_configure "$@"; } +meson_optional_src_compile() { meson_src_compile "$@"; } +meson_optional_src_test() { meson_src_test "$@"; } +meson_optional_src_install() { meson_src_install "$@"; } fi |