Commit Graph

109 Commits

Author SHA1 Message Date
Christopher Larson
d2b3e641de tcmode: explicitly check for bindir's existence
JIRA: SB-6206

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-11-04 09:58:32 -07:00
Christopher Larson
c2a2eb36f0 tcmode: kill redundant Error: in sanity check errors
bb.fatal already prints ERROR:, so prefixing it with Error: is pointless and
redundant.

JIRA: SB-6206

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-11-04 09:58:26 -07:00
Abdur Rehman
3ac97834f1 tcmode: set localedir back to ${exec_prefix}/lib/locale
This reverts commit 4c72f28c6e
to align localedir with the external toolchain

Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
2015-10-21 21:46:45 +05:00
Christopher Larson
89002198a4 tcmode: fix BASELIB for aarch64
The library path in the sourcery toolchain for aarch64 is lib64, not lib.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-10-14 21:13:22 -07:00
Christopher Larson
b90444dfbd tcmode: add aarch64 to EXTERNAL_TARGET_SYSTEMS
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-10-13 12:45:54 -07:00
Christopher Larson
5ce0b68788 Use --no-sysroot-suffix
With this, we can avoid the need to create a symlink for the multilib sysroot
suffix. This also adds a nativesdk package to the sdk to adjust the
environment setup there to use it as well.

JIRA: SB-6018

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-10-07 12:56:19 -07:00
Christopher Larson
4c72f28c6e tcmode: drop wrong localedir override
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-09-17 14:34:13 -07:00
Adnan Ali
e7114c0235 OMerge branch 'release/2014.12-async1' 2015-09-09 15:50:05 +05:00
Christopher Larson
fc71b90a13 tcmode: improve CodeBench PATH removal
We were explicitly removing the old default install path. Rather than
explicitly removing the new install path, remove */codebench/bin/, since
that's the new structure of the installs.

JIRA: SB-5383

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-08-04 12:07:54 -07:00
Christopher Larson
bfc86fd9c4 oe.external: move common functions here
Also provide external-common.bbclass to wrap its inclusion and setup
associated metadata. This will make easier to search sysroots for files
without pulling in the rest of the external toolchain class.

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-07-29 13:10:51 -07:00
Christopher Larson
e030657d62 sourcery-tuning: fix -march=armv5e failures
The most common failure case was qemuarm. Currently, ARMPKGSFX_THUMB is used
in TUNE_CCARGS, and it only includes 't' when ARM_INSTRUCTION_SET=thumb.
Bypass that check for armv5, as we need -march=armv5te rather than
-march=armv5t, but we still want -mthumb removed when appropriate.

Fixes #86

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-07-29 11:24:37 -07:00
Christopher Larson
bae98b2af6 tcmode: blacklist gcc-source
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-07-21 12:46:11 -07:00
Christopher Larson
ba1954bc85 Split out blacklist_dynamic.bbclass
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
2015-07-21 12:45:42 -07:00
Christopher Larson
f21cb41351 Properly blacklist ${TARGET_ARCH}-suffixed recipes
This fixes issues with multilib handling.

JIRA: SB-4705

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-06-30 19:11:19 -07:00
Christopher Larson
2a27def5b6 gcc-runtime-external: use upstream metadata
Also splits sanitizers into gcc-sanitizers to align with oe-core.

JIRA: SB-5005

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-30 09:02:18 -07:00
Christopher Larson
c95d2ddbc0 tcmode: blacklist libgcc-initial
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-28 11:45:16 -07:00
Christopher Larson
251db4c885 tcmode: improve external toolchain sanity checks
- Move from BuildStarted time to TreeDataPreparationStarted, as we want
  bitbake -e to work, so it has to run after ConfigParsed, and we want to see
  these errors rather than the highly verbose unbuildable -external recipe
  errors which occur when generating the runqueue, so we need to run before
  BuildStarted.
- Add 'does gcc exist' sanity test. This also shows an informative warning if
  the bindir exists, but the gcc binary doesn't, and EXTERNAL_TARGET_SYS ==
  TARGET_SYS, which indicates we failed to find a prefix via
  EXTERNAL_TARGET_SYSTEMS.
- Add 'is GCC_VERSION UNKNOWN' sanity test, mentioning the failure of gcc
  version extraction, and pointing to the debug messages to see what actually
  happened.

JIRA: SB-4850, SB-1029

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-20 13:29:31 -07:00
Christopher Larson
05a7e45b7b tcmode: don't use the Name handling in inline python
Currently, the checksumming doesn't handle it well.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-20 13:22:12 -07:00
Christopher Larson
6ffb77e4c9 external-run: use debug messages, not warnings
While these messages are useful when debugging, the warnings clutter up the
log due to running before our sanity checks, potentially confusing the user.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-20 13:16:10 -07:00
Christopher Larson
13b7be29ba Handle EXTERNAL_TOOLCHAIN correctly in checksums
We want the path included in the checksums for the -external-cross recipes, as
they wrap the external binaries and hardcode that path, but we don't want it
included in the checksums for anything else, and we don't want rebuilding the
external-cross recipes to cause rebuilds of thing sthat depend upon them.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-01 13:17:32 -07:00
Christopher Larson
279a1b01d9 tcmode: don't include EXTERNAL_TARGET_SYSTEMS in checksums
We only care about the resulting value of EXTERNAL_TARGET_SYS, not the
components that fed into it.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-01 13:16:39 -07:00
Christopher Larson
5f40a4db3c tcmode: ensure that SOURCERY_VERSION's value is in our checksums
Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-04-01 13:15:35 -07:00
Christopher Larson
a653aaf0c9 Merge pull request #63 from MentorEmbedded/external-run-in-tmpdir
external-run.inc: run in TMPDIR, not TOPDIR
2015-03-31 11:49:56 -07:00
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
864d52f9c8 tcmode: drop sdk toolchain removal
This is more a distro/user decision, I think, so move it there. Also this was
insufficient, as just removing `packagegroup-cross-canadian-${MACHINE}` without
adding back in `meta-environment-${MACHINE}` results in an sdk which hangs on
install.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
2015-01-27 09:04:51 -07:00
Fahad Arslan
00285aff17 tune-ppce6500.inc: add e6500 tune files based on oe-core tune file
Signed-off-by: Fahad Arslan <Fahad_Arslan@mentor.com>
2015-01-23 21:19:46 +05: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
d758930d00 Merge remote-tracking branch 'origin/release/2014.05' into merge-rel201405-to-rel201412
* origin/release/2014.05:
  tcmode: disable pseudo for gcc/g++/cpp
  Revert "Merge pull request #36 from MentorEmbedded/sb-1905"
2014-10-28 10:14:10 -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