Commit Graph

14 Commits

Author SHA1 Message Date
Thilo Fromm
d1e2f6d1f2 catalyst_toolchains: don't touch the SDK
This change removes 8 years old code from the toolchains build which
tries to update SDK libraries for unknown reasons, breaking the
toolchains build in the glibc-2.33 update.

Signed-off-by: Thilo Fromm <thilo@kinvolk.io>
2021-06-25 10:37:21 +02:00
Marga Manterola
e04156a0f1
bootstrap_sdk: build and upload SDK toolchain pkgs
Before, we were relying on the toolchains job to build and upload
packages that were part of the SDK. With this change, all packages that
should be part of the SDK are built and uploaded by the SDK job. The
toolchains job only builds toolchain packages specific for the release.

This change includes several adjustments done to both the SDK and the
toolchains jobs to make this work:
 * Make the SDK job build all cross toolchains, including Rust
 * Stop building Rust in the toolchains job and use the one in the SDK
   instead.
 * In toolchain_util.sh: detect when the symlink folder for crossdev
   packages is missing and run crossdev to create it during
   update_chroot setup.
 * Make it possible to build the SDK starting from stage 4 instead of
   stage 1, to make the SDK building faster for PR branches / nightlies
   (full build should still be done for releases / weeklies).
2020-06-29 15:18:55 +05:30
Dongsu Park
b13976285e build_library: deal with both virtual/rust and dev-lang/rust
Toolchain utils have installed only `dev-lang/rust`. It could result
in version mismatch between `virtual/rust` and `dev-lang/rust`, because
`dev-lang/rust` does not automatically pull in `virtual/rust`.

So install `virtual/rust` instead of `dev-lang/rust`.
2020-06-10 20:30:22 +02:00
Flatcar Buildbot
c7bbb2b1e2 2345.0.0 2019-12-04 14:59:11 +01:00
David Michael
afff45366a build_toolchains: Update sysroot settings for newer portage
Since EAPI=7 was supported, portage can no longer use different
ROOT and SYSROOT values.  This adjusts the paths so that the first
phase builds cross-toolchains under /usr/${CHOST}, then the native
toolchains are built under /build/${BOARD} (as was being done
previously).  Now that the cross-toolchain development files can't
be used when building the native toolchain, the headers and libs
are stupidly copied into the board root to be used used and then
overwritten by the board packages as they are built.  Since this is
all done in a chroot, these changes shouldn't affect the SDK host.
2018-08-29 21:40:21 +00:00
Michael Marineau
6e6a0a4967 toolchain_util: include repos.conf in bootstrap build environments
This is required for the eventual removal of `$PORTDIR` and
`$PORTDIR_OVERLAY` and ensures toolchain rebuilds/updates with
`./build_packages --nousepkg` don't erroniously try to use ebuilds from
`/usr/portage` inside of the SDK.

In order to fix up the build_toolchains script the crossdev overlay
needs to be setup properly, previously only setup_board did it.

Overall silences a lot of warnings and fixes an issue with crossdev:

    /usr/bin/emerge-wrapper: line 48: /eclass/toolchain-funcs.eclass: No such file or directory
    /usr/bin/emerge-wrapper: line 49: tc-arch: command not found
2015-04-01 16:30:37 -07:00
Geoff Levand
ea6cf50b8d toolchain_util.sh: Fix _configure_sysroot CBUILD
The portage CBUILD and HOSTCC variables need to be set to the SDK host to get
a proper cross build when building target binaries.

Change _configure_sysroot to use the CBUILD environment variable to set the
CBUILD and HOSTCC variables of ${ROOT}/etc/portage/make.conf.  Also, fix up all
calls to _configure_sysroot to set the CBUILD environment variable.

Fixes setup_board failure when the host and target architectures differ.

Signed-off-by: Geoff Levand <geoff@infradead.org>

[marineam: fixed a copy/paste error]
2015-04-01 15:54:43 -07:00
Michael Marineau
21614c5942 fix(toolchain_util): Move toolchain build-dep code from catalyst.
Now this code can be shared with setup_board. Only required if
setup_board is called with --nousepkg which is rare to never but feels
like the correct thing to do. Alternatively setup_board could always
use binary packages (as it basically does now).
2013-11-29 17:56:58 -08:00
Michael Marineau
d5a19a0700 fix(toolchain_util.sh): Move cross-toolchain install code to common lib.
This will eventually be used by setup_board instead of the even more
complicated toolchain code provided by chromite.
2013-11-07 13:28:13 -08:00
Michael Marineau
986548722d fix(toolchain_util.sh): Move native->cross pkg translation to function
Will be useful in other places and seems better to hide the bash magic.
2013-11-07 13:28:13 -08:00
Michael Marineau
9187adb7ca fix(catalyst_toolchains.sh): Fix error in doc comment 2013-10-23 12:07:39 -07:00
Michael Marineau
169cc17394 fix(build_toolchains): Fix simple logging typo 2013-10-23 12:02:25 -07:00
Michael Marineau
31d5ced3df fix(build_toolchains): Remove hard-coded portage profile 2013-10-23 11:58:19 -07:00
Michael Marineau
c503b0248b add(build_toolchains): New command to build cross and native target toolchains.
This replaces the cross-toolchain compile step in bootstrap_sdk and adds the
ability to build native toolchains using the cross toolchain. This is just
the first step towards actually providing the native toolchain in a container.
2013-10-23 11:07:01 -07:00