Gentoo Archives: gentoo-dev

From: "Vadim A. Misbakh-Soloviov" <gentoo@×××.name>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH] systemd.eclass: set BDEPEND for EAPI 7
Date: Mon, 06 Aug 2018 19:35:59
Message-Id: 3181714.0gOeftyz4v@tp
In Reply to: Re: [gentoo-dev] [PATCH] systemd.eclass: set BDEPEND for EAPI 7 by Ulrich Mueller
1 В письме от понедельник, 6 августа 2018 г. 22:13:49 MSK пользователь Ulrich
2 Mueller написал:
3 > >>>>> On Mon, 6 Aug 2018, Mike Gilbert wrote:
4 > > -DEPEND="virtual/pkgconfig"
5 > > +if [[ ${EAPI} == [0123456] ]]; then
6 >
7 > This should use ${EAPI:-0} because for EAPI 0 the variable can be
8 > empty.
9 >
10 > > + DEPEND="virtual/pkgconfig"
11 > > +else
12 > > + BDEPEND="virtual/pkgconfig"
13 > > +fi
14
15 And how about "-le"/"-lt"/"-ge"/"-gt"/"-eq" syntax?
16 Or even ((EAPI<7))?
17 Are they forbidden to use in eclasses?
18
19 Anyway, I think, it is possible to add something like "EAPI=${EAPI:-0}"
20 somewhere at the top of eclass, to don't call "${EAPI:-0}" each time when EAPI
21 variable is needed.

Replies