Gentoo Archives: gentoo-dev

From: Jason Zaman <perfinion@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [RFC] New eclass: mate
Date: Fri, 10 Jun 2016 03:54:26
Message-Id: 20160610035412.GA6716@meriadoc.perfinion.com
In Reply to: Re: [gentoo-dev] [RFC] New eclass: mate by NP-Hardass
1 On Thu, Jun 09, 2016 at 08:19:43AM -0400, NP-Hardass wrote:
2 > # Old EAPIs are banned.
3 > case "${EAPI:-0}" in
4 > 5|6) ;;
5 > *) die "EAPI=${EAPI} is not supported" ;;
6 > esac
7
8 How reasonable would it be to ban EAPI5 as well? This is a new eclass so
9 it may be better to just take the time to go to EAPI6 directly and not
10 have to migrate 5->6 later on.
11
12
13 > # @FUNCTION: python_cond_func_wrap
14 > # @DESCRIPTION: Wraps a function for conditional python use, to run for each
15 > # python implementation in the build directory.
16 > python_cond_func_wrap() {
17 > if use python; then
18 > python_foreach_impl run_in_build_dir "$@"
19 > else
20 > $@
21 > fi
22 > }
23
24 I dont see where you inherited the python eclasses? You also probably
25 need to use use_if_iuse (from eutils.eclass) instead since it seems like
26 python might not be in all the ebuilds. Afaik, you're not allowed to
27 call use foo if foo is not in IUSE already.
28
29 Also I'm not sure if having functions start with python_ could lead to
30 conflicts later on with the python eclasses?
31
32 Other than these minor things, look good!
33 -- Jason

Replies

Subject Author
Re: [gentoo-dev] [RFC] New eclass: mate NP-Hardass <NP-Hardass@g.o>