Gentoo Archives: gentoo-dev

From: Alexis Ballier <aballier@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH 2/2] cmake-utils.eclass: export compilers to environment instead of setting in toolchain file, bug 542530
Date: Fri, 04 Nov 2016 12:37:57
Message-Id: 20161104133742.157aab8f@gentoo.org
In Reply to: Re: [gentoo-dev] [PATCH 2/2] cmake-utils.eclass: export compilers to environment instead of setting in toolchain file, bug 542530 by James Le Cuirot
1 On Fri, 4 Nov 2016 12:33:37 +0000
2 James Le Cuirot <chewi@g.o> wrote:
3
4 > On Fri, 4 Nov 2016 13:20:16 +0100
5 > Alexis Ballier <aballier@g.o> wrote:
6 >
7 > > On Thu, 3 Nov 2016 00:52:17 +0100
8 > > Maciej Mrozowski <reavertm@×××××.com> wrote:
9 > >
10 > > > From: Maciej Mrozowski <reavertm@g.o>
11 > > >
12 > > > ---
13 > > > eclass/cmake-utils.eclass | 6 +++---
14 > > > 1 file changed, 3 insertions(+), 3 deletions(-)
15 > > >
16 > > > diff --git a/eclass/cmake-utils.eclass b/eclass/cmake-utils.eclass
17 > > > index 88d2163..23cc094 100644
18 > > > --- a/eclass/cmake-utils.eclass
19 > > > +++ b/eclass/cmake-utils.eclass
20 > > > @@ -525,13 +525,13 @@ enable_cmake-utils_src_configure() {
21 > > >
22 > > > local toolchain_file=${BUILD_DIR}/gentoo_toolchain.cmake
23 > > > cat > ${toolchain_file} <<- _EOF_ || die
24 > > > - SET (CMAKE_C_COMPILER $(tc-getCC))
25 > > > - SET (CMAKE_CXX_COMPILER $(tc-getCXX))
26 > > > - SET (CMAKE_Fortran_COMPILER $(tc-getFC))
27 > > > SET (CMAKE_AR $(type -P $(tc-getAR)) CACHE
28 > > > FILEPATH
29 > >
30 > >
31 > > Have you tested cross compiling ?
32 > > IIRC toolchain file is used *before* getting those vars from env and
33 > > is used to determine system & compiler type. Without this you get
34 > > bugs like #503216
35 >
36 > I was dubious (since I filed that bug) but I briefly tested by
37 > cross-compiling media-libs/openal and it worked. I didn't think to try
38 > older CMake versions though. The behaviour might have changed.
39 >
40
41 could you please send me (in private) build logs with & without the
42 changes please ?
43
44 (dont have easy access to a x compile setup atm)

Replies