Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH 2/4] kernel-build.eclass: Build logic for dist-kernels
Date: Sun, 05 Jan 2020 06:05:11
Message-Id: 598712a6c3c467c870e98f284efd4afdb7b16859.camel@gentoo.org
In Reply to: Re: [gentoo-dev] [PATCH 2/4] kernel-build.eclass: Build logic for dist-kernels by Mike Gilbert
1 On Sat, 2020-01-04 at 18:41 -0500, Mike Gilbert wrote:
2 > On Sat, Jan 4, 2020 at 4:24 PM Michał Górny <mgorny@g.o> wrote:
3 > > +# @FUNCTION: kernel-build_src_configure
4 > > +# @DESCRIPTION:
5 > > +# Prepare the toolchain for building the kernel, get the default .config
6 > > +# or restore savedconfig, and get build tree configured for modprep.
7 > > +kernel-build_src_configure() {
8 > > + debug-print-function ${FUNCNAME} "${@}"
9 > > +
10 > > + # force ld.bfd if we can find it easily
11 > > + local LD="$(tc-getLD)"
12 > > + if type -P "${LD}.bfd" &>/dev/null; then
13 > > + LD+=.bfd
14 > > + fi
15 > > +
16 > > + MAKEARGS=(
17 > > + V=1
18 > > +
19 > > + HOSTCC="$(tc-getCC)"
20 > > + HOSTCXX="$(tc-getCXX)"
21 > > + HOSTCFLAGS="${CFLAGS}"
22 > > + HOSTLDFLAGS="${LDFLAGS}"
23 >
24 > I think the HOST variables should reference the CBUILD toolchain. Example below.
25 >
26 > # Sets BUILD_CFLAGS and BUILD_LDFLAGS if not set in make.conf.
27 > tc-export_build_env
28 >
29 > HOSTCC="$(tc-getBUILD_CC)"
30 > HOSTCXX="$(tc-getBUILD_CXX)"
31 > HOSTCFLAGS="${BUILD_CFLAGS}"
32 > HOSTLDFLAGS="${BUILD_LDFLAGS}"
33 >
34
35 Yeah, I was supposed to fix this and I've forgotten. Thanks for doing
36 the work for me ;-).
37
38 --
39 Best regards,
40 Michał Górny

Attachments

File name MIME type
signature.asc application/pgp-signature