Gentoo Archives: gentoo-dev

From: Michael Orlitzky <mjo@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Re: cmake + ninja vs autotools
Date: Sun, 19 Nov 2017 19:20:41
Message-Id: 226d3a37-3ef7-77e1-c515-0b45589eda96@gentoo.org
In Reply to: Re: [gentoo-dev] Re: cmake + ninja vs autotools by "William L. Thomson Jr."
1 On 11/19/2017 01:00 PM, William L. Thomson Jr. wrote:
2 >>
3 >> This is broken: Static metadata like DEPEND must not depend
4 >> on dynamic data like environment variables which are supposed
5 >> to change at emerge time.
6 >
7 > I wondered about that. I guess adding to DEPEND via eclass is bad then.
8 >
9
10 So long as you add to DEPEND unconditionally, the issue that Martin
11 pointed out does not apply. If you need to fudge the conditional, you
12 can put it behind a USE flag; for example,
13
14 DEPEND+=" some_use_expand_flag_foo? ( foo )"
15
16 in the eclass. That's still adding to DEPEND unconditionally, even
17 though its effect on the dependency tree (at "emerge" time) is
18 conditional on the USE flag.