Gentoo Archives: gentoo-dev

From: Mike Gilbert <floppym@g.o>
To: Gentoo Dev <gentoo-dev@l.g.o>
Cc: frp.bissey@×××××.com, Agostino Sarubbo <ago@g.o>
Subject: Re: [gentoo-dev] RFC: Standard build environment variables
Date: Sun, 28 Jun 2020 15:26:18
Message-Id: CAJ0EP41T2R1V_YhHJh0XwgSnpgi7XhgJcinZMCYv3sxkW+9QUg@mail.gmail.com
In Reply to: [gentoo-dev] RFC: Standard build environment variables by Michael Orlitzky
1 On Sun, Jun 28, 2020 at 8:18 AM Michael Orlitzky <mjo@g.o> wrote:
2 >
3 > As many of you probably know, ago@ has been expanding the scope of our
4 > CFLAGS/CC support to include some other common build variables:
5 >
6 > * CC
7 > * CXX
8 > * AR
9 > * CPP
10 > * NM
11 > * RANLIB
12 > * AS
13 > * LD
14 >
15 > Some of those are POSIX standards[0],
16 >
17 > * CC
18 > * AR
19 >
20 > Others are de-facto GNU make standards[1],
21 >
22 > * CXX
23 > * CPP
24 > * AS
25 >
26 > and a few are de-facto GNU libtool standards[2]:
27 >
28 > * NM
29 > * RANLIB
30 > * LD
31 >
32 > If we expect them all to work properly in Gentoo, we have to agree on
33 > what they mean, and thus how they should be injected into build systems.
34 > For example, we had a problem with sci-mathematics/pari, whose upstream
35 > is using the LD environment variable for something other than what GNU
36 > libtool uses it for. With LD set to something libtooly in the
37 > environment, the pari build fails. We can solve that by unsetting LD in
38 > the ebuild, but for that to be The Right Thing To Do, we should be
39 > expecting LD to contain something libtooly, and thus something
40 > inappropriate to be passed to the pari build.
41 >
42 > To avoid these issues, I suggest creating a list of "Gentoo environment
43 > variables" in the devmanual with descriptions of how they should be used
44 > and pointers to the references (for why we chose that meaning). That way
45 > a user can export LD, for example, and know that it will be used how he
46 > thinks it will be used.
47
48 Makes sense to me.