summaryrefslogtreecommitdiffstats
path: root/meta/classes/toolchain-scripts.bbclass
AgeCommit message (Collapse)Author
2022-08-12classes: Update classes to match new bitbake class scope functionalityRichard Purdie
Move classes to classes-global or classes-recipe as appropriate to take advantage of new bitbake functionality to check class scope/usage. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-08-12classes: Add SPDX license identifiersRichard Purdie
As stated in our top level license files, the license is MIT unless otherwise stated. Add SPDX identifers accordingly. Replace older license statementa with the standardised syntax. Also drop "All Rights Reserved" expression as it isn't used now, doesn't mean anything and is confusing. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-08-12classes: Add copyright statements to files without oneRichard Purdie
Where there isn't a copyright statement, add one to make it explicit. Also drop editor config lines where they were present. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-07-28toolchain-scripts.bbclass: adjust toolchain_create_tree_env_script to better ↵Alexander Kanavin
replicate (e)SDK Specifically: 1. Place the environment setup file into $B and not into $TMPDIR, so that the recipe using the class can itself better decide what to do with the file. 2. Use global, unified sysroots (provided through build-sysroots recipe) and not recipe-specific ones, as this allows flexible on-the-fly management of what libraries are available to build applications, without having to modify any recipes, similar to eSDK 'extensible' part. This also requires adjustment of the sstate sametune_samegsigs test, as meta-ide-support becomes dependent on $MACHINE (unified sysroots have it in their paths) and needs to be excluded from the test. 3. Add a few missing settings that have been added to SDK environment files. 4. Add a snippet to the environment setup file that also runs the relocation scripts. In regular SDKs this is executed by the SDK installer, in direct SDK we can do it when setting up the environment. Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-03-31cmake: support to create per-toolchain cmake file in SDKJagadeesh Krishnanjanappa
The patch creates ${MULTIMACH_TARGET_SYS}-toolchain.cmake file at ${SDK_INSTALL_DIR}/sysroots/${SDK_SYS}/usr/share/cmake/, which is per-toolchain CMake toolchain file containing arch-specific values and independent of OE environment variables. The file gets created after installing SDK toolchain installer ined by running "bitbake -c populate_sdk <image>". The changes are similar to meson-setup.py which is used to create arch-specific ${SDK_INSTALL_DIR}/sysroots/${SDK_SYS}/usr/share/meson/*-meson.cross [YOCTO #14644] Tested-by: Jan Dorniak <jaskij@gmail.com> Signed-off-by: Jagadeesh Krishnanjanappa <workjagadeesh@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
2022-02-08toolchain-scripts.bbclass: use double quotes for exported PS1Kai Kang
Use double quotes("") rather than single quotes('') for PS1 in EXPORT_SDK_PS1 which will be exported in SDK environment file. Then it could set PS1 for SDK env with some variables in host env, such as the original PS1. The SDK PS1 could be some distinct words plus original PS1 rather than replace the whole original PS1. For example, it could set in local.conf with SDK_PS1 = "(oesdk) \${PS1}" then it just prepends '(oesdk) ' before original PS1 after source the SDK environment file. Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2021-09-23siteinfo/autotools: Ensure task checksums reflect site filesRichard Purdie
Currently, if you change the site files, nothing rebuilds since they are not accounted for in task checksums. They could/should be through the file-checksums task flag. We need to cache all the files looked for, whether the exist or not so that if they do exist and didn't, the checksum also changes. This gets complicated by the need to clean out hardcoded build paths from the variable and that other layers can have site files. This patch adds this functionality. A new variable, SITEINFO_PATHVARS is added which controls which substitutions to make on the file-checksum values to remove the hardcoded paths. Layers adding site files will need to set this to a variable that has the layer path in it and is excluded from task hashes (COREBASE is the one the core layer uses). This patch will cause yocto-check-layer to fail for some layers where site files are added yet the layer isn't a machine specific layer. This is arguable correct since these additional site files apply to all recipes and things from a layer like core could be changed by such changes so it is right they should rebuild. There is a determinism issue potentially there if not. meta-openembedded does have some such references but looking at them they should move to core or likely just be removed as most look obsolete anyway. [YOCTO #13729] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2021-07-30Convert to new override syntaxRichard Purdie
This is the result of automated script conversion: scripts/contrib/convert-overrides.py <oe-core directory> converting the metadata to use ":" as the override character instead of "_". Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2021-03-11toolchain-scripts.bbclass: customize prompt string for SDKsKai Kang
Introduce a new variable SDK_PS1 to customize prompt string for SDKs when source script environment-setup-script. If variable SDK_PS1 is not set or empty, nothing changed. Otherwise new PS1 with the value of SDK_PS1 is used after source the sdk environment file. Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-10-08toolchain-scripts: export READELFRoss Burton
The readelf binary is prefixed, so export READELF in the SDKs so that the correct readelf binary can be used. This fixes problems with the symbol extractor in Meson with multilib SDKs where readelf can't be found correctly. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-01-07toolchain-scripts: run post-relocate scripts for every environmentRoss Burton
SDKs for multilib configurations have multiple environment scripts, so re-arrange the post-relocate hook invocation so that it runs the post-relocate hooks after sourcing each environment script. Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-08-07toolchain-scripts: put TARGET_ARCH and TARGET_OS into environmentRoss Burton
It's useful for the SDK to know exactly what TARGET_ARCH and TARGET_OS are, specifically for SDK QA. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-08-07cmake: fix linking in multilib SDKsRoss Burton
CMake, in it's infinite wisdom, when searching for libraries (using find_library) will look inside the libraries PREFIX/lib, PREFIX/lib32, and PREFIX/lib64. In a multilib SDK more than one of these will exist (potentially all three) and obviously for a given build configuration only one of those is valid. This search path is hard-coded deep inside CMake but by setting CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX we can bypass it and set an explicit lib<SUFFIX> to use. Do this by writing ${baselib} into the environment file, and then stripping "lib" from this to obtain the suffix in the cmake-specific environment script, which is then read in the CMake toolchain. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-06-07toolchain-scripts: pass env to post-relocateMartin Kelly
It's useful for the post-relocate scripts to be able to see the SDK environment, for example to see the values of CC, CXX etc. in order to dynamically generate toolchain files. To enable this, source the SDK environment script prior to calling the relocate scripts. Signed-off-by: Martin Kelly <mkelly@xevo.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-06-07toolchain-scripts: print post-relocate errorMartin Kelly
Currently, if a post-relocate script fails, it fails silently. We should be louder about this, as it likely indicates a broken SDK. Print a message if a post-relocate script fails. Signed-off-by: Martin Kelly <mkelly@xevo.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-06-07toolchain-scripts: allow non-sh post-relocateMartin Kelly
Currently, we look only for scripts matching *.sh, which means we can't write post-relocate scripts in other languages. Expand this to allow any type of script. Signed-off-by: Martin Kelly <mkelly@xevo.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-06-07toolchain-scripts: retab fileMartin Kelly
A function is uses a mix of spaces and tabs. The rest of the file uses tabs, so switch to tabs uniformly. Signed-off-by: Martin Kelly <mkelly@xevo.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-05-04toolchain-scripts/meta-ide-support: Handle dash shells correctlyRichard Purdie
Where /bin/sh is dash, the recent toolchain scripts change fails as the $(pwd) usage in oe-init-build-env doesn't function correctly. Fix this by saving and restoring the cwd and calling the script within its own directory. This fixes meta-ide-support on dash based systems. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-05-04toolchain-scripts: preserve host path in environment setup scriptChin Huat Ang
The environment setup script generated in the build directory sets the PATH variable by expanding ${PATH} which would have host paths filtered. Sourcing this script to run runqemu will not work as it complains host stty (/bin/stty) cannot be found. To resolve this, the script no longer expands ${PATH} during generation time, instead it will now source oe-init-build-env to initialize the build environment so that all host paths will be preserved. Also be sure to prepend STAGING_BINDIR_TOOLCHAIN to the PATH variable so that the toolchain from the build directory can be found. [YOCTO #12695] Signed-off-by: Chin Huat Ang <chin.huat.ang@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-02-15toolchain-shar-extract: Add post-relocate scriptsJoshua Watt
Recipes can now install post-relocation scripts which will be run when the SDK is installed. Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-28toolchain-scripts: add check for LD_LIBRARY_PATH in the SDK env setup scriptDenys Dmytriyenko
Provide a descriptive error message and exit the environment-setup script, when LD_LIBRARY_PATH is set on the host system. Signed-off-by: Denys Dmytriyenko <denys@ti.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-06-16meta: Drop further remnants of uclibc supportRichard Purdie
uclibc support was removed a while ago and musl works much better. Start to remove the various overrides and patches related to uclibc which are no longer needed. uclibc support in a layer would still be possible. I have strong reasons to believe nobody is still using uclibc since patches are missing and I doubt the metadata even parses anymore. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-26toolchain-scripts: remove CCACHE_PATH from environment scriptJoshua Lock
CCACHE_PATH was added to the toolchain-scripts in commit 1d31ddb856a80ba9da1a64ed5d701dc0f7351ef7 without a detailed explanation as to why. This commit removes that environment variable as it's causing failures since the introduction of host_gcc_version() to oe.utils in d36f41e5658bbbb6080ee833027879c119edf3e0, as used by uninative to determine NATIVELSBSTRING. This causes errors when the host has ccache available in in PATH - host_gcc_version() fails because ccache has been told to only look for the compiler in CCACHE_PATH and can't find gcc in order to check its version. Toolchain compilers aren't detected due to the binaries being prefixed with the triplet of the target. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-23Switch to Recipe Specific SysrootsRichard Purdie
This patch is comparatively large and invasive. It does only do one thing, switching the system to build using recipe specific sysroots and where changes could be isolated from it, that has been done. With the current single sysroot approach, its possible for software to find things which aren't in their dependencies. This leads to a determinism problem and is a growing issue in several of the market segments where OE makes sense. The way to solve this problem for OE is to have seperate sysroots for each recipe and these will only contain the dependencies for that recipe. Its worth noting that this is not task specific sysroots and that OE's dependencies do vary enormously by task. This did result in some implementation challenges. There is nothing stopping the implementation of task specific sysroots at some later point based on this work but that as deemed a bridge too far right now. Implementation details: * Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in TMPDIR/sysroot-components/PACKAGE_ARCH/PN. * WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and RECIPE_SYSROOT_NATIVE. * This construction is primarily done by a new do_prepare_recipe_sysroot task which runs before do_configure and consists of a call to the extend_recipe_sysroot function. * Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot dependencies. * We have to do a search/replace 'fixme' operation on the files installed into the sysroot to change hardcoded paths into the correct ones. We create a fixmepath file in the component directory which lists the files which need this operation. * Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each time a new loader is added. These are handled by adding files in bindir with the name prefixed by "postinst-" and are run in each sysroot as its created if they're present. This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them. * Since a recipe can have multiple tasks and these tasks can run against each other at the same time we have to have a lock when we perform write operations against the sysroot. We also have to maintain manifests of what we install against a task checksum of the dependency. If the checksum changes, we remove its files and then add the new ones. * The autotools logic for filtering the view of m4 files is no longer needed (and was the model for the way extend_recipe_sysroot works). * For autotools, we used to build a combined m4 macros directory which had both the native and target m4 files. We can no longer do this so we use the target sysroot as the default and add the native sysroot as an extra backup include path. If we don't do this, we'd have to build target pkg-config before we could built anything using pkg-config for example (ditto gettext). Such dependencies would be painful so we haven't required that. * PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy for each machine. The paths therefore changed, the behaviour did not. * The ccache class had to be reworked to function with rss. * The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal recipe name therefore remains a bad idea. * The logic in insane needed tweaks to deal with the new path layout, as did the debug source file extraction code in package.bbclass. * The logic in sstate.bbclass had to be rewritten since it previously only performed search and replace on extracted sstate and we now need this to happen even if the compiled path was "correct". This in theory could cause a mild performance issue but since the sysroot data was the main data that needed this and we'd have to do it there regardless with rss, I've opted just to change the way the class for everything. The built output used to build the sstate output is now retained and installed rather than deleted. * The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold up against testing. This has been rewritten too. There are some assumptions made about paths, we save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is here works but is a little hardcoded and an area for future improvement. * In order to work with eSDK we need a way to build something that looks like the old style sysroot. "bitbake build-sysroots" will construct such a sysroot based on everything in the components directory that matches the current MACHINE. It will allow transition of external tools and can built target or native variants or both. It also supports a clean task. I'd suggest not relying on this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have to have built that in a previous bitbake invocation. * pseudo is run out of its components directory. This is fine as its statically linked. * The hacks for wayland to see allarch dependencies in the multilib case are no longer needed and can be dropped. * wic needed more extensive changes to work with rss and the fixes are in a separate commit series * Various oe-selftest tweaks were needed since tests did assume the location to binaries and the combined sysroot in several cases. * Most missing dependencies this work found have been sent out as separate patches as they were found but a few tweaks are still included here. * A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my hand. That implementation can probably be neater but this is on the list of things to cleanup later at this point. In summary, the impact people will likely see after this change: * Recipes may fail with missing dependencies, particularly native tools like gettext-native, glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors * Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst * There was a separate patch series dealing with roots postinst native dependency issues. Any postinst which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS. There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean we've found all the issues. Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the task logfiles, not the console so I've intentionally left this like that for now. We can turn it down easily enough in due course. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-16meta: remove True option to getVar callsJoshua Lock
getVar() now defaults to expanding by default, thus remove the True option from getVar() calls with a regex search and replace. Search made with the following regex: getVar ?\(( ?[^,()]*), True\) Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-09-23toolchain-scripts-base: add base class for toolchain_create_sdk_versionJoshua Lock
We use toolchain_create_sdk_version() in buildtools-tarball but don't want the extra classes toolchain-scripts pulls in, therefore split out a separate base class for this function which both toolchain-scripts and the buildtools-tarball can inherit. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-09-22autotools/siteinfo: Tweak CONFIG_SITE handling for determism/racesRichard Purdie
As things stand there are multiple races in the CONFIG_SITE handling where checksums can change depending on whether site directories exist or not when parsing happens. This is bad. Secondly, there is a build race that occurs if you build virtuals in parallel with the "main" recipe, since the main recipe is parsed when the virtual is (since it sets variables like BBCLASSEXTEND) and with the current code, it may look for files and directories which could be created/destroyed which the loop is executing. This is also bad. The aclocal-copy directory should only ever be accessed by the call from autotools.bbclass. This changes the parameter name to make it clear and ensures all callers have the right usage, neatly avoiding all the problems above. Also added better comments. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-04bitbake.conf/toolchain-scripts.bbclass: Remove debug prefix mappings in SDKJacob Kroon
CFLAGS/CXXFLAGS in the SDK environment script adds debug-prefix mappings that include staging area/work directories. Remove them since the SDK shouldn't be aware of them. Signed-off-by: Jacob Kroon <jacob.kroon@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-07-01toolchain-scripts: add sysroot/usr/share/pkgconfig to PKG_CONFIG_PATHRoss Burton
Otherwise architecture-independent pkg-config files such as wayland-protocols won't be found in the SDK. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-05-06toolchain-scripts: replace source built-in callStephano Cetola
Some shells (e.g. dash) do not support the source built-in. This replaces it with the dot operator. [ YOCTO #9535 ] Signed-off-by: Stephano Cetola <stephano.cetola@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21toolchain-scripts.bbclass: add three other path to PATH in env.shJun Zhang
in sdk,there are some utils in sysroot/host-os/bin, sysroot/host-os/sbin/,sysroot/host-os/usr/bin need to use, so add these three paths to PATH in env.sh. Signed-off-by: Jun Zhang <jun.zhang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-07toolchain-scripts: drop PYTHONHOMEChristopher Larson
If this is set when nativesdk-python is not installed, it will break the host python, so it's better to handle this in python. Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-06toolchain-scripts.bbclass: Use PYTHONPATH instead of PYTHONHOMERandy Witt
In the extensible sdk it was originally intended that the native sstate would always be setscened as part of the sdk installation. However, the soon to come "minimal" sdk won't do that. A side effect of that is that pointing PYTHONHOME at the native sysroot within the "bitbake workspace" won't work. For now only set PYTHONPATH instead and continue using the python that comes from buildtools. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-12-08toolchain-scripts.bbclass: unset command_not_found_handleFang Jia
On Ubuntu-system, When sourcing the env.sh from an exported sdk, and running a bogus linux command (for example "asd"), a core dump of python is usually generated. Unset the command_not_found_handle to fix it. Signed-off-by: Fang Jia <fang.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-07-31toolchain-scripts: Extend to cover nativesdk compiler tools (e.g. nativesdk-gcc)Richard Purdie
This is needed when we add nativesdk-gcc/binutil to an SDK. Being present doesn't hurt in other cases. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-27toolchain-scripts: For non-glibc, pass compiler options to ensure the ↵Richard Purdie
correct libc selection gcc-cross-canadian-<arch> is only built once. It needs to target all the different libcs, not just the currently selected one. This change ensures that if another libc is used, the compiler correctly selects the right one. [YOCTO #8025] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-06-26toolchain-scripts: fix for multilibRobert Yang
Use MLPREFIX to fix: | cat: /path/to/sysroots/lib32-qemux86-64/sysroot-providers/virtual_libc: No such file or directory [YOCTO #7924] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-06-23toolchain-scrpts: Fix sitecache issues with multilibRichard Purdie
The use of TCLIBC in TOOLCHAIN_NEED_CONFIGSITE_CACHE is problematic since a multilib may have both uclibc and glibc for different multilibs yet switching between them doesn't change TCLIBC. This would result in "lib32-glibc" being attempted when lib32 was actually uclibc. The fix here is to use the virtual providers which bitbake switches to point correctly at the right things. This does mean we need to resolve virtual providers but we can do this using sysroot-providers. [YCOTO #7607] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-05-23toolchain-scripts.bbclass: fix quoting for CCACHE_PATHAndre McCurdy
Single quotes prevent expansion of $sdkpathnative$bindir. Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-04-15toolchain-scripts: Allow the CONFIGSITE_CACHE variable to be overriddenRichard Purdie
In multilib and baremetal configurations, this variable can cause a variety of problems due to the use of TCLIBC. At least allowing it to be overriden is a start and allows various configurations to avoid the issue. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23toolchain-scripts: Add parameters to toolchain_create_sdk_env_script.Randy Witt
To add some flexibility to setting up the paths for the toolchain, add some parameters. This initial use will be in order to point at the buildsystem toolchain copied in by copy_buildsystem.py. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-03toolchain-script: Add support for ccache builds with the SDKLaszlo Papp
It is necessary to have an SDK for developers who build their software with ccache to speed up the compilation. Without resolving this, unfortunately the compilation will fail for them. Signed-off-by: Laszlo Papp <lpapp@kde.org> Signed-off-by: Ross Burton <ross.burton@intel.com>
2014-11-20toolchain-scripts.bbclass: Export KCFLAGS to ensure sysroot is providedOtavio Salvador
When building the U-Boot the lack of a proper sysroot can trigger following error: ,---- | arm-poky-linux-gnueabi-ld.bfd: cannot find -lgcc | make[2]: *** [examples/standalone/hello_world] Error 1 | make[1]: *** [examples/standalone] Error 2 | make: *** [examples] Error 2 `---- Guillaume Fournier has posted a very complete analysis of the problem[1]. 1. https://lists.yoctoproject.org/pipermail/meta-freescale/2014-November/011270.html The use of KCFLAGS makes the build of U-Boot work out of box, now that it uses the Linux kernel build system. Reported-by: Guillaume Fournier <gfournier@brioconcept.com> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
2014-11-12meta-environment: Fix config-site with a multilib configMark Hatle
[YOCTO #6951] The TOOLCHAIN_CONFIGSITE_SYSROOTCACHE value was defaulting to the nativesdk path and not the associated target path. Set the value in toolchain-scripts to the target path. Be sure to set the MLPREFIX within the meta-environment script as multilibs are processed. Update the config_site file name to use -BPN- not PN. Otherwise the environment processing can't find the correct filename. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2014-10-10toolchains-scripts: Add support for target environment scriptsRichard Purdie
In a similar way to the previous script which adds support for native environment scripts, this adds support for target environment scripts too. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10toolchain-scripts.bbclass: Allow sourcing of subscript for environmentOtavio Salvador
Sometimes we require extra environment settings to be available on the environment for proper SDK work. This were done, in past, using '_append' tasks however with the split of the environment in a canadian package this has been broken. The easier and more flexible solution is to use environment subscripts which are sources by the main script. These are now looked at: $OECORE_NATIVE_SYSROOT/environment-setup.d/*.sh and sourced. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-23toolchain-script: Really fix CANADIANEXTRAOE issuesRichard Purdie
There was an error in the previous fix for the powerpc toolchain issue, this should correct it (and simplify the code too). [YOCTO #6490] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-03toolchain-scripts: Add handling for CANADIANEXTRAOSRichard Purdie
When we build a general toolchain script we should add all the OS variants to PATH, not just the current one. This is because some can cross reference each other and if the triplet prefixed ld can't be found for example, you recieve strange errors. Doing this resolves bugs exposed during SDK testing. [YOCTO #6490] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-11-06toolchain-scripts/meta-environment: Further cleanup code duplicationRichard Purdie
There was still duplicated code in toolchain-scripts, this further cleans up the functions to remove it. The now unused includedir parameter is also dropped. The final scripts do end up reordered slightly and the sysroot is parametrised for the IDE scripts which is an improvement but should have no functional difference. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-11-06toolchain-scripts: Drop darwin8 codeRichard Purdie
The code was clearly broken and isn't used, even by meta-darwin so we might as well remove it. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>