Commit Graph

83 Commits

Author SHA1 Message Date
Christopher Larson
4a2f9d3bb1 external-run.inc: run in TMPDIR, not TOPDIR
TMPDIR is already in the BB_HASHBASE_WHITELIST, whereas TOPDIR is not.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-03-31 11:48:44 -07:00
Christopher Larson
0beb66b376 Split up external-sourcery-toolchain into separate recipes
common-license.bbclass will set LIC_FILES_CHKSUM to a common license file
based on LICENSE, which is appropriate for a case where we have no sources to
refer to.
external-toolchain.bbclass, among other things, handles extraction of files in
the external toolchain sysroot, based on patterns in the FILES variables,
checking alternate locations to better support any arbitrary toolchain, and
has basic mirror handling for checking multiple paths within the sysroots.

Under normal circumstances, I'd want this to use highly granular commits, but
this branch has been extremely long lived (>1yr) and is such an invasive
refactoring that attempting to break it down now would be of limited
usefulness.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2014-12-19 10:35:25 -07:00
Christopher Larson
c9e4b593af tcmode: don't set SDKGCCVERSION
There's no need for the crosssdk and nativesdk gcc bits to be the same version
as the external toolchain.

JIRA: SB-3919

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2014-10-31 20:32:49 -07:00
Christopher Larson
8856633063 Merge remote-tracking branch 'origin/release/2014.05'
* origin/release/2014.05:
  tcmode: disable pseudo for gcc/g++/cpp
  Revert "Merge pull request #36 from MentorEmbedded/sb-1905"
2014-10-27 17:34:18 -07:00
Christopher Larson
0bad0369f0 Adjust for poky switching to glibc
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2014-09-02 09:07:08 -07:00
Christopher Larson
6dae53dcd3 Merge remote-tracking branch 'origin/daisy'
* origin/daisy:
  tcmode: Add -msgxx-glibc option if supported by the tools.
2014-07-21 12:44:55 -07:00
Christopher Larson
e7c5f947bf tcmode: disable pseudo for gcc/g++/cpp
The sourcery toolchain writes temporary files to /tmp, and includes the
username. If multiple users are doing builds with pseudo enabled, it'll try to
write to the other user's file, since both will use 'root', and the build will
fail as a result.

We don't want to wrap all the toolcahin binaries, as they don't all call the
tools which write these lockfiles, and objcopy has to be excluded, as it
modifies installed binaries when the packaging process splits out the debug
info. If that operation occurs outside of pseudo's knowledge, Bad Things will
happen.

JIRA: MEIP-393, SB-1905

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-07-21 11:34:22 -07:00
Christopher Larson
6f37610680 Revert "Merge pull request #36 from MentorEmbedded/sb-1905"
This reverts commit f901bfd098, reversing
changes made to 69d2f98eda.

cs-license & friends don't obey TMPDIR, so this workaround had no useful
effect for our builds.
2014-07-18 16:03:21 -07:00
Drew Moseley
57478d6cf8 tcmode: Add -msgxx-glibc option if supported by the tools.
Basing this check off "arch == x86" is not strictly correct.
This option should be used on any toolchain where it is a valid
option to ensure that the build host libraries are ignored.

Signed-off-by: Drew Moseley <drew_moseley@mentor.com>
2014-07-18 10:26:18 -04:00
Christopher Larson
c9829b9baa tcmode: obey MGLS_LICENSE_FILE, not MGLS
JIRA: SB-3112

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-06-24 14:58:09 -07:00
Christopher Larson
0bae350148 tcmode: don't use BB_HASHBASE_WHITELIST_append
Currently, bitbake isn't always using the finalized configuration metadata to
get the value of this variable, so the _append isn't always applied.

JIRA: MEIBPADIT-811

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-06-17 09:49:41 -07:00
Christopher Larson
b4493e0236 tcmode: use /tmp/sourcery-$LOGNAME for TMPDIR
Work around the bad interaction between cs-license and pseudo by shoving all
the temporary files into a subdir by the user's original logname.

JIRA: SB-1905

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-06-13 10:16:25 -07:00
Christopher Larson
562dfbda09 Revert "tcmode: disable pseudo when running the toolchain"
This caused all manner of breakage due to the toolchain writing out files with
wrong ownership, then those files would end up leaking into the rootfs.

JIRA: INTAMDDET-129, SB-2725

This reverts commit 6bd4ec919a.
2014-05-16 12:17:10 -07:00
Christopher Larson
c0786d219c tcmode: add MGLS, LM_LICENSE_FILE to BB_HASHBASE_WHITELIST
This ensures that they don't affect our checksums/signatures. These affect the
behavior of the toolchain licensing, not the output.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-17 14:41:54 -07:00
Christopher Larson
e1b0f111bb tcmode: export MGLS and LM_LICENSE_FILE
This is necessary for the toolchain licensing.

JIRA: SB-2612

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-17 10:28:06 -07:00
Christopher Larson
256ad7dff5 Merge pull request #30 from kergoth/sb-2602
tcmode: drop en_US.UTF-8 from GLIBC_GENERATE_LOCALES
2014-04-14 15:08:28 -07:00
Drew Moseley
45d049fa91 tcmode-external-sourcery: Add x86_64-amd-linux-gnu toolchain prefix.
Allow x86-64 builds to use x86_64-amd-linux-gnu as the prefix for the
cross tools.

Signed-off-by: Drew Moseley <drew_moseley@mentor.com>
2014-04-14 15:15:37 -04:00
Christopher Larson
27fe7fc82f tcmode: drop en_US.UTF-8 from GLIBC_GENERATE_LOCALES
This locale doesn't seem to be available in the external toolchain, so make
sure it isn't included in this variable, otherwise locale-base will depend
upon a non-existant package.

JIRA: SB-2602

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-14 11:51:19 -07:00
Christopher Larson
075e1b76a4 csl-versions: use eventmask for the handler
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-10 15:05:53 -07:00
Christopher Larson
5f48a48ec7 tcmode: use eventmask for the handler
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-10 15:05:50 -07:00
Christopher Larson
6bd4ec919a tcmode: disable pseudo when running the toolchain
The sourcery toolchain writes temporary files to /tmp, and includes the
username. If multiple users are doing builds with pseudo enabled, it'll try to
write to the other user's file, since both will use 'root', and the build will
fail as a result.

Initially, I attempted to alter CC, KERNEL_CC, LD, etc to prepend with 'env
PSEUDO_UNLOAD=1 ', but this isn't ideal, as it seems there are cases where our
vars aren't obeyed. For example, the kernel build runs gcc -E, but it seems it
gets that from the cross-compiler prefix, not from CC, and we aren't passing
anything in for CPP. So, for now, use wrappers to deal with it, to ensure that
absolutely any call to any of the toolchain binaries will unload pseudo.

JIRA: MEIP-393, SB-1905

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-04-10 12:38:58 -07:00
Paul Woegerer
edc3532d6a Also allow bbs in addition to bbappends 2014-03-18 12:48:25 +01:00
Christopher Larson
bea0c577c8 layer.conf: add LAYERDEPENDS
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2014-03-10 08:19:20 -07:00
Drew Moseley
f4d984d96d tcmode-external-sourcery: Allow x86_64-linux-gnu as toolchain prefix.
Allow x86-64 builds to use x86_64-linux-gnu as the prefix for the
cross tools.

Signed-off-by: Drew Moseley <drew_moseley@mentor.com>
2014-03-07 19:00:41 -05:00
Christopher Larson
4228b31e44 csl-versions: improve main ver for Preview releases
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2013-10-23 13:18:34 -07:00
Christopher Larson
29a5e89e5f csl-versions: fix syntax of gdb ver when there's an error
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2013-10-17 08:56:09 -07:00
Christopher Larson
6be35fcbd6 tcmode-external-sourcery: s/mkdirhier/utils.mkdirhier/
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2013-10-17 03:17:48 +00:00
Christopher Larson
965ae8df88 tune-*: ensure we apply the e500v2 gcc ice fix
Push out our append to TUNE_CCARGS to the end of the parse with _append, so it
shouldn't be affected by the e500v2 :=, and manually apply its gcc ice fix.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-08-21 07:58:49 -07:00
Christopher Larson
e71ffa3603 tune-*: don't die if the ccargs are expanded early
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-08-21 07:49:52 -07:00
Christopher Larson
227565a5df tcmode: set NO32LIBS ?= "0" 2013-07-25 09:58:21 -07:00
Christopher Larson
2d75af10a0 tcmode: add CSL_TARGET_SYS_x86-64
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-07-17 09:04:25 -07:00
Christopher Larson
1f21d8825f tcmode: kill the TOOLCHAIN_HOST_TASK override
This means we won't be able to build meta-toolchain with an external
toolchain, but it does mean we don't screw up buildtools-tarball. If we need
a functional meta-toolchain in the future, we can resurrect a superior
implementation of this.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-06-27 16:35:54 -07:00
Christopher Larson
5f3b4e7921 tcmode: add SDKGCCVERSION bits
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-06-27 16:34:42 -07:00
Christopher Larson
3b44877887 Move GNU_HASH warning fixes here from meta-mentor
Internal toolchains generally don't see these, as they build that toolchain
with the default behavior they expect, so it's appropriate to include these
fixes with the external toolchain configuration, for now.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-05-31 09:38:09 -07:00
Christopher Larson
5d423c4509 tcmode-external-sourcery: don't break when not in a loop
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-05-01 15:27:28 -07:00
Christopher Larson
e2075d4a78 tcmode-external-sourcery: create ld.bfd toolchain symlink
Now that KERNEL_LD uses ld.bfd, we need to ensure that it exists when using an
external toolchain.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-05-01 15:21:40 -07:00
Christopher Larson
dd059648cd Merge remote-tracking branch 'mel/master' into HEAD
* mel/master:
  external-sourcery-toolchain: kill more bits we don't want in eglibc-utils
  Work around upstream FILESDIR/FILESPATH changes
  external-sourcery-toolchain: fix dev vs staticdev packaging issue
  external-sourcery-toolchain: kill oprofile bits
  external-sourcery-toolchain: silence GNU_HASH warning for libquadmath
  tcmode: prefer a matching gcc version for target recipes
  external-sourcery-toolchain: add libquadmath packages
  external-sourcery-toolchain: kill ${exec_prefix}/lib/locale in do_install_locale
  external-sourcery-toolchain: also package ${prefix}/libexec
  external-sourcery-toolchain: forgot to rstrip the trailing newline

Conflicts:
	recipes/meta/external-sourcery-toolchain.bb

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-04-01 15:04:40 -04:00
Christopher Larson
f62e16eff3 external-sourcery-toolchain: provide libc-initial
This keeps eglibc-initial out of the build when using eglibc-sourcery.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2013-03-08 14:20:47 -07:00
Christopher Larson
be73bed243 tcmode: prefer a matching gcc version for target recipes
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-11-09 14:50:32 -07:00
Christopher Larson
1e24d0e84a toolchain-scripts: add TOOLCHAIN_PATH_ADD to PATH
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-10-30 15:38:23 -07:00
Christopher Larson
f367734c1c tcmode: use the class override for PATH add
This ensures that we aren't modifying the PATH for nativesdk/cross/crosssdk.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-10-30 09:03:57 -07:00
Christopher Larson
04461e5205 tcmode: don't ship a toolchain in the sdk for now
Long term, may want to add the ability to ship the cross-canadian content from
the external toolchain.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-10-29 17:44:30 -07:00
Christopher Larson
d6bbda9d7d tcmode: don't early expand PATH in its adjustments
To avoid issues when a user installed a Sourcery toolchain to the default path
and let it modify their PATH, we iterate over PATH and remove the problematic
elements. Unfortunately, in doing so, we inadvertently forced an early
expansion of PATH due to getting it in its expanded form, then setting PATH
based on that form. Instead, operate against the unexpanded PATH.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-10-26 10:24:38 -07:00
Christopher Larson
2845e07df7 tcmode: filter out default cs intall paths from PATH
The toolchain installer can end up modifying the user's PATH via their
dotfiles, but if the ia32 sourcery g++ toolchain is always in the user's path,
things can fail to build, as the ia32 toolchain provides non-prefixed binaries
(e.g. 'gcc', 'ld').

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-10-24 08:35:29 -07:00
Christopher Larson
171a53d0b6 tcmode: add EXTERNAL_TOOLCHAIN to the build configuration display
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-26 12:51:09 -07:00
Christopher Larson
965baa3484 tcmode: set localedir to ${exec_prefix}/lib/locale
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-21 09:45:54 -07:00
Christopher Larson
c28de0269d Fix previous commit
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-21 08:18:32 -07:00
Christopher Larson
52ced4c8ac tcmode: make absolutely certain we don't add to PATH for native
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-21 08:16:58 -07:00
Christopher Larson
d08a375446 tcmode: add default LDEMULATION to fix parse error
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-20 08:07:55 -07:00
Christopher Larson
72ff116b8e tcmode: pass LDEMULATION for mips64 to fix busybox build
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2012-09-19 22:58:44 -07:00