summaryrefslogtreecommitdiffstats
path: root/meta/classes
Commit message (Collapse)AuthorAgeFilesLines
* go.bbclass: Add -buildmode=pie for non mips archRobert Yang2018-10-011-0/+10
| | | | | | | | | | Fixed QA issue like: WARNING: runc-docker do_package_qa: QA Issue: ELF binary '/path/to/runc-docker/usr/bin/runc' has relocations in .text [textrel] (From OE-Core rev: 8dcd4e6e791c3a8b8bf5e69dca9bb9c887231d69) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* archiver: generalise task running when in configured modeRoss Burton2018-10-011-13/+19
| | | | | | | | | | | | | | | When in configured mode the archive will re-run configure itself, but that doesn't work if there are other tasks that need to run such as cmake's generate_toolchain_file. Instead of hard-coding a list of classes and tasks, obtain the list of tasks preceeding do_configure, filter out ones we don't want to re-run such as do_patch and do_prepare_recipe_sysroot, and run those too. (From OE-Core rev: fe26382f94d8cb7d2453d9937aee451b757252b8) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* archiver: check tasks exist before adding dependenciesRoss Burton2018-10-011-2/+5
| | | | | | | | | | | | Some recipes don't have do_configure, or have them but are marked as noexec. Check for their existance before hooking up dependencies. [ YOCTO #12868 ] (From OE-Core rev: 5c8aa1f41f04519a8ba3997c0d8e3a71fe270fae) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* multilib: avoid expanding grub and grub-efi to multilibRobert Yang2018-10-012-3/+10
| | | | | | | | | | | | | | | | | | | | | | It doesn't make much sense to expand them to multilib, and there is an error on qemuarm64 since grub-efi supports arm64, but doesn't support armv7a or armv7ve: * Fixed: MACHINE = "qemuarm64" require conf/multilib.conf MULTILIBS = "multilib:lib32" DEFAULTTUNE_virtclass-multilib-lib32 = "armv7a" MACHINE_FEATURES_append = " efi" $ bitbake lib32-core-image-minimal Also introduced a variable NON_MULTILIB_RECIPES in multilib.conf, so that we can easily add other recipes, such as syslinux if needed. (From OE-Core rev: 25f7c6c329038b443d36074fff45a30ba3712f7a) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* mime.bbclass: fix do_package_qa_multilib error of lib32-fltkChangqing Li2018-10-011-1/+1
| | | | | | | | | | | | | | | fltk.bb inherit mime.bbclass, mime.bbclass add RDEPEND during populate_package, so need add mlprefix manually. ERROR: QA Issue: lib32-fltk package lib32-fltk-dev - suspicious values 'shared-mime-info-data-dev' in RRECOMMENDS [multilib] ERROR: QA Issue: lib32-fltk package lib32-fltk-bin - suspicious values 'shared-mime-info-data' in RDEPENDS [multilib] (From OE-Core rev: 5a26b03c9f73822554ea969e42bca82217dfd3f8) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* multilib.bbclass: fix do_package_qa_multilib errorChangqing Li2018-10-011-1/+2
| | | | | | | | | | | | | | lib32-packagegroup-anaconda-support have RDEPENDS to kernel-image, but kernel-image don't have lib32, so skip it. ERROR: QA Issue: lib32-packagegroup-anaconda-support package lib32-packagegroup-anaconda-support - suspicious values 'kernel-image' in RDEPENDS [multilib] (From OE-Core rev: 24b8c61bf7dd13f7f371d3a910947a1fac062c6b) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-yocto.bbclass: fix "referenced before assignment" errorMax Kellermann2018-09-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | If "scc --configs" fails, do_kernel_configcheck() crashes like this: 0338: try: 0339: configs = subprocess.check_output(['scc', '--configs', '-o', s + '/.kernel-meta'], env=env).decode('utf-8') 0340: except subprocess.CalledProcessError: *** 0341: bb.fatal( "Cannot gather config fragments for audit: %s" % configs) 0342: 0343: try: 0344: subprocess.check_call(['kconf_check', '--report', '-o', 0345: '%s/%s/cfg' % (s, kmeta), d.getVar('B') + '/.config', s, configs], cwd=s, env=env) Exception: UnboundLocalError: local variable 'configs' referenced before assignment This crash bug was introduced by commit 21de5cc43cfedc703e5bc0515507a6dae36afb74 (From OE-Core rev: 9602c03e8701c972f544001415efa92877622f57) Signed-off-by: Max Kellermann <max.kellermann@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* nativesdk.bbclass: set consistent staging dirs regardless of multilibChen Qi2018-09-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For now, the RECIPE_SYSROOT of nativesdk recipes is ${WORKDIR}/recipe-sysroot if multilib is disabled and ${WORKDIR}/nativesdk-recipe-sysroot if multilib is enabled. And it's causing chaos. Problems I've met include: 1) 'File Exists' error when doing extend_recipe_sysroot 2) Rebuilding failure about cmake based nativesdk recipes if toggling multilib In nativesdk.bbclass, We've set MULTILIBS to be "", and we've changed MLPREFIX to be 'nativesdk-', I think we should also set consistent RECIPE_SYSROOT to be ${WORKDIR}/recipe-sysroot. Below is an example showing why previous settings will cause do_prepare_recipe_sysroot failure. e.g. A -> C B -> C A's RECIPE_SYSROOT is .../recipe-sysroot and B's RECIPE_SYSROOT is .../nativesdk-recipe-sysroot. As extend_recipe_sysroot function uses shared manifest, i.e., the same manifest of C for both A and B, then there must be one of them having the wrong manifest. And the wrong manifest results in RECIPE_SYSROOT not cleaned up before installing new components, thus the following error. Exception: FileExistsError: [Errno 17] File exists: xxx -> xxx This happens when toggling multilib and also between nativesdk recipes and crosssdk, cross-canadian recipes. The latter situation also explains why choosing ${WORKDIR}/recipe-sysroot instead of ${WORKDIR}/nativesdk-recipe-sysroot. If we use 'nativesdk-recipe-sysroot', we still need to modify the extend_recipe_sysroot function to treat crosssdk and cross-canadian as special cases. Using 'recipe-sysroot' does not have this problem. (From OE-Core rev: 665934a506cc560bfbc469f5ed095e7d54e353a5) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* siteinfo: generalise siteinfoRoss Burton2018-09-251-8/+9
| | | | | | | | | | Add a function siteinfo_data_for_machine to look up the data for any arch/os pair, not just HOST_ARCH-HOST_OS. (From OE-Core rev: 7429ed8d2a6e48cb3415113ef62348ae211aa189) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meson: stop Meson using target CFLAGS in native buildsRoss Burton2018-09-251-5/+10
| | | | | | | | | | | | | | | | With the goal of autoconf-compatibility Meson respects $CFLAGS et al in builds. In cross-compiled build the cross file is the one true source of flags and the environment isn't used, but in a native build the environment will still be respected. As this can lead to target flags being used in the build for native binaries (including a single native binary inside a target recipe), export CFLAGS=${BUILD_CFLAGS) et al. (From OE-Core rev: 4ca0002860dca771836c0ce1c7a92b79a5f2db3f) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meson: pass correct endian in the cross fileRoss Burton2018-09-251-7/+13
| | | | | | | | | | | | Meson doesn't care for the value of the endian field, but packages may want to use it and Meson master now validates the value. Use siteinfo to obtain the endianism and write the correct value. (From OE-Core rev: 2f9adf05efdddf8dae9c58976ae56cf32d9e57f0) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel.bbclass: Avoid iterating over KERNEL_IMAGETYPES twiceAlex Kiernan2018-09-221-7/+4
| | | | | | | | | | | During deploy we iterate over KERNEL_IMAGETYPES twice, with no consumer of our changes in the interim. Collapse these two loops into one. (From OE-Core rev: 8d3139640ed4cd4e196dc2d1f6ae02d612fb9564) Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Fix modules tarball generation with usrmergeAlex Kiernan2018-09-221-2/+2
| | | | | | | | | | | | When usrmerge is enabled the kernel modules aren't under /lib, but /usr/lib; ensure we fetch the modules from the correct location so we don't have a tarball which consists of a single symlink. (From OE-Core rev: 62d2d7d12dda69d6019a1a2d5492450487e41bfd) Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-fitimage: Fix dangling symlink to image tree sourceAlex Kiernan2018-09-221-1/+1
| | | | | | | | | | | When deploying the its file, the target of the symlink is missing the its extension, add it here. (From OE-Core rev: df72761760d453b2dfc7cc2fa1344bb016df9712) Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Revert "kernel.bbclass: do not deploy fitImage; kernel-fitimage.bbclass does ↵Alex Kiernan2018-09-221-12/+6
| | | | | | | | | | | | | | | | that." This reverts commit 65cded55fa96b1ba72149a31689c081ac27af7f7. The fitImage deployed here is the one generated in kernel-fitimage.bbclass, whereas the one deployed by kernel-fitimage.bbclass is a raw image, so we need the one deployed here keeping. (From OE-Core rev: 798d2acc0141b13da7ddd18875a417b2df9d57b3) Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage.bbclass: Dependency on u-boot-mkimage-native for all uImagesReto Schneider2018-09-221-1/+1
| | | | | | | | | | | | | | | | | u-boot-mkimage-native is needed to build any type of uImages, be it the uImage target itself or for example uImage.lzma. The dependency however gets only added when at least one of KERNEL_IMAGETYPE and KERNEL_ALT_IMAGETYPE is exactly uImage. Building uImage.bin and uImage.lzma is not possible this way. This patch adds a dependency to u-boot-mkimage-native for all imagetypes which contains the string uImage. (From OE-Core rev: ac4ce0b07b2742c64d44f988ecb27e7200b5a0bc) Signed-off-by: Reto Schneider <code@reto-schneider.ch> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* siteinfo.bbclass: Add LatticeMico32 architecture site infoNathan Rossi2018-09-211-0/+1
| | | | | | | | | | | Add the basic architecture site info targets for the LatticeMico32 architecture. This architecture does not target Linux. (From OE-Core rev: 216f8ea907c8ac7e580e33dcbd12c0f30608bf74) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: Add ARC to kernel arch mapAlexey Brodkin2018-09-211-0/+1
| | | | | | | | (From OE-Core rev: d53b0b885fcf038d26d3f8aa8c5b46ec86649cea) Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* siteinfo: Define data for ARCAlexey Brodkin2018-09-211-0/+2
| | | | | | | | (From OE-Core rev: a66834f63e190377c3464ea180ccdc0262226049) Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* clutter: simplify SRC_URIRoss Burton2018-09-211-6/+1
| | | | | | | | | | The Clutter class's ability to switch between tarballs and git isn't really useful, so remove it. If it comes back, it should use the devupstream class. (From OE-Core rev: 6150ec737bad895b9fb62f711449a259887ebd1b) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* distutils{, 3}.bbclass: improve error messagesJens Rehsack2018-09-212-8/+8
| | | | | | | | | | | | | For non-python developers it's difficult to identify where start searching in case of errors. Fixing and marking the string to grep for might help finding some root causes of issues slightly quicker. (From OE-Core rev: 44fff749ee7bfe47e88286aec1e8a22e63079ca7) Signed-off-by: Jens Rehsack <sno@netbsd.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Consistent debug loggingDouglas Royds2018-09-211-8/+11
| | | | | | | | | | | | | | | Log both the source of the source_date_epoch and the resulting source_date_epoch in all cases. Also, now that we are determining the source_date_epoch successfully for both yocto and non-yocto kernels, remove the inherits_class('kernel') exception. We will log a failure to find a source_date_epoch for kernels as well. (From OE-Core rev: 48fe0e83435f9fb53b1e5b37d5d9f1c2caccd22d) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Don't enforce existence of ${S} dirDouglas Royds2018-09-211-5/+1
| | | | | | | | | | Unnecessary. (From OE-Core rev: 75d5a9d72566aca7a9f08bea21523b3c66bddeae) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Find the git repo in WORKDIR/git or S firstDouglas Royds2018-09-211-12/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change the search regime for find_git_folder(): 1. WORKDIR/git: This is the default git fetcher unpack path 2. ${S} 3. Go looking for .git/ under the WORKDIR as a last resort. linux-yocto: We had an existing (silent) defect. The linux-yocto recipes all specify two git SRC_URIs, one for the kernel source itself, the other for the kmeta data (config fragments and friends). find_git_folder() was finding the git checkout for the kmeta data, but due to a typo in the git log -1 --pretty=%ct line, we were (silently) reading the source_date_epoch from the ${S} directory = STAGING_KERNEL_DIR, which is empty. If your build/ happened to be inside a git checkout, git would walk up the directory tree, and silently read the commit timestamp from this other git checkout. The correct path to read the git commit timestamp from is the "gitpath", being that found by find_git_folder(), though this function was incorrectly finding the kmeta data checkout, not the kernel source tree. Non-kernel git recipes: The default git fetcher clones and checks out the sources at WORKDIR/git/ regardless of the setting of S (unless subpath or destsuffix is set). find_git_folder() now looks for the WORKDIR/git/.git/ directory first. Non-yocto linux kernels: Kernel recipes that don't inherit kernel-yocto should always set S = ${WORKDIR}/git, so that when base_do_unpack_append() in kernel.bbclass moves the checkout down to the STAGING_KERNEL_DIR and symlinks it as WORKDIR/git, the build can still work by following the symlink. We were previously failing to follow the symlink in the os.walk(), but we now look first for WORKDIR/git/.git/, and find it due to the symlink. If none of the above mechanisms work for finding the git checkout, perhaps there was a subpath or destsuffix specified in the SRC_URI. We go looking for the git checkout under the WORKDIR as a last resort. (From OE-Core rev: b0ddb141d36853447f85ecaac07dbc9c5779627f) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Rename ambiguous "path" var to sourcedir or workdir as appropriateDouglas Royds2018-09-211-18/+19
| | | | | | | | (From OE-Core rev: 01358d6a89623a38e66969daa431d2eecb1ce8a2) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Refactor: get_source_date_epoch_from_youngest_file()Douglas Royds2018-09-211-33/+40
| | | | | | | | (From OE-Core rev: 2c8baf6c50e5a266a1e9ac939415bd481668e17e) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* reproducible: Tidy class descriptionDouglas Royds2018-09-211-27/+22
| | | | | | | | | | Tidy whitespace, delete commented-out lines (From OE-Core rev: 254eb5a2a12fd6b5cf7427818ea9fa886ea407a6) Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* linuxloader.bbclass: Refactor to have seprate functions for musl/glibc loaderKhem Raj2018-09-211-36/+49
| | | | | | | | | | | | | this makes it possible to use this for musl where we are trying to create a glibc compat package Add missing aarch64 loader definition for glibc function (From OE-Core rev: 0a02ea79ec522582b46138a027eb166819e5647d) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* uninative: Add support for aarch64 hostsRichard Purdie2018-09-201-2/+3
| | | | | | (From OE-Core rev: b72e54b9a649faf4eb292e3bc643d5d06d4d4fea) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* insane: Recognise BPF as a valid EM_MACHINE typeKhem Raj2018-09-131-2/+4
| | | | | | | | | | | | | | | | BPF Linux ELF objects are generated with kernel-selftests with >= 4.18 kernel and when clang is enabled which packages BPF objects into packages, therefore recongnise this as a valid ELF target Add a selftest for BPF Do not flag BPF objects in target, since they pretty much will be ok for most of kernels architectures we care do support BPF (From OE-Core rev: 3667a8ec016bae3f8026ef7b4c895546804f6368) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* target-sdk-provides-dummy: skip package_qa_multilib checkKai Kang2018-09-132-2/+5
| | | | | | | | | | | | | | | The rprovides of target-sdk-provides-dummy don't be updated with multilib, so it fails package_qa_multilib check. Because target-sdk-provides-dummy doesn't install any file to sysroot, it is safe to skip package_qa_multilib check for target-sdk-provides-dummy. Remove ${MLPREFIX}target-sdk-provides-dummy from TOOLCHAIN_TARGET_TASK at same time in populate_sdk_base.bbclass. (From OE-Core rev: 3197c086269a4b21fb807a9c552b56f23c5b86dc) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sstate.bbclass: update SSTATE_DUPWHITELISTKai Kang2018-09-131-1/+3
| | | | | | | | | | | | Update SSTATE_DUPWHITELIST in sstate.bbclass. * remove ${DEPLOY_DIR_RPM}/noarch/ which is not overwritten any more * add directories for package target-sdk-provides-dummy (From OE-Core rev: 6d3ca476dbc2059f4b7fa3dfd73de6bbfed49198) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* allarch: only enable allarch when multilib is not usedKai Kang2018-09-135-9/+22
| | | | | | | | | | | | | | | | | | | | | Some allarch packages rdepends non-allarch packages. when multilib is used, it doesn't expand the dependency chain correctly, e.g. core-image-sato -> ca-certificates(allarch) -> openssl we expect dependency chain for lib32-core-image-sato: lib32-core-image-sato -> ca-certificates(allarch) -> lib32-openssl it should install lib32-openssl for ca-certificates but openssl is still wrongly required. Only enable allarch when multilib is not used to fix the issue. (From OE-Core rev: a23c482cab4f874f4a6a6889716123569eb5ece9) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel.bbclass: do not deploy fitImage; kernel-fitimage.bbclass does that.Leon Woestenberg2018-09-131-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | kernel-fitimage.bbclass replaces an occurance of "fitImage" in KERNEL_IMAGETYPE_FOR_MAKE by an image type that is buildable for the architecture (such as zImage). The kernel-fitimage.bbclass packs that image as sub-image in a flattened image tree image (fitImage) and deploys this fitImage along with the image tree source file (.its). kernel-fitimage.bbclass does not alter KERNEL_IMAGETYPES, which thus also contains "fitImage", which kernel.bbclass will also deploy redundantly with different naming. The result is a dual deployment with slightly different naming, each with a set of symlinks. The solution chosen is to have fitImage deployment be handled by kernel-fitimage.bbclass, and have kernel.bbclass ignore fitImage types during deployment. (From OE-Core rev: 65cded55fa96b1ba72149a31689c081ac27af7f7) Signed-off-by: Leon Woestenberg <leon@sidebranch.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* devicetree.bbclass: don't pad DT overlaysLuca Ceresoli2018-09-131-2/+5
| | | | | | | | | | | | | | | | | | | | By default the devicetree class adds padding to the generated .dtb files, which can be needed by the bootloader. However it also pads .dtbo files, which is not useful. Don't apply padding to the overlay devicetrees. To achieve this: * move "-p ${DT_PADDING_SIZE}" to a new variable, DTB_BFLAGS (B for "base") * add "-p 0" to DTC_OFLAGS to disable padding for overlays Cc: Nathan Rossi <nathan@nathanrossi.com> (From OE-Core rev: 678fe8c66b19f141f6869859cf365aec037e89d9) Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* testimage.bbclass: fix qemu_use_kvm handlingEmmanuel Roullit2018-09-131-2/+2
| | | | | | | | | | | | | | | | QEMU_USE_KVM can either be a boolean or a whitespace separated list of kvm supported machines. For the 'intel-corei7-64' machine, defined in meta-intel, kvm could not be used as the 'x86' substring is not part of its machine name. By changing the order of this 'or' statement and setting the 'QEMU_USE_KVM' variable to 'intel-corei7-64', it is possible to run the 'testimage' task with kvm support successfully. (From OE-Core rev: a22789253aa653dc50fb159b40910248c2f98dd4) Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* staging: Fix broken debug codeRichard Purdie2018-09-101-1/+1
| | | | | | | | | The code currently only prints a single depchain due to overwriting data instead of appending. Fix this. (From OE-Core rev: 48af19cdfa92aa9d336da50afe4ed3dde92daecc) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* staging: Ensure we handle glibc-locale do_stash_locale correctlyRichard Purdie2018-09-101-0/+2
| | | | | | | | | | | | | | | | | | | | Occasionally we see warnings like: WARNING: core-image-sato-1.0-r0 do_populate_sdk: Manifest /home/pokybuild/yocto-worker/nightly-qa-extras/build/build/tmp/sstate-control/manifest-allarch-nativesdk-linux-libc-headers.populate_sysroot not found in i686_linux allarch (variant '')? which occur when do_populate_sdk is run in an otherwise empty TMPDIR. It occurs because do_stash_locale is not recognised as a setscene task and is removed from the taskgraph meaning the dependency chains fed through setscene_depvalid don't match what was actually setscene'd. That task is recipe specific and not in the global SSTATETASKS so we hardcode the value for now to stop the build warnings. This is going to need to be revisited for a more generic solution. (From OE-Core rev: d8d5b624058920113f9d297f7f711d6d3249ae39) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* populate_base_sdk: Stop running gcc --version all the timeRichard Purdie2018-09-051-1/+1
| | | | | | | | | | Running 'gcc --version' for every image recipe is slow and increases parsing time/resource usage for no good reason. Only compute the value in when we're really running the task/function. (From OE-Core rev: bf49316bb9913b7c89de64d6a194be31aa66e16b) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* autotools.bbclass: adjust indentation for consistencyChen Qi2018-09-051-1/+1
| | | | | | | | | | All other functions in this class use TAB for indentation while the do_compile function uses '4 spaces'. Adjust it for consistency. (From OE-Core rev: c2829b74892633c554a5f8262d4cafbe0fa6c3a7) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipes: Update git.gnome.org addresses after upstream changesRichard Purdie2018-09-042-2/+2
| | | | | | | | | | | | | | | git.gnome.org is no more. It has ceased to be. It's an ex-git. Please see here: https://about.gitlab.com/2018/05/31/welcome-gnome-to-gitlab/ Note that gitlab does not support git://, only https:// (and ssh). [Commit message from Alexander Kanavin] (From OE-Core rev: 8382cdc0888ca645a44aacaac1155afb8dcde979) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* package.bbclass: warn if perms conf file does not existChen Qi2018-09-041-1/+5
| | | | | | | | | | | | | | It's possible that the perms conf file specified by FILESYSTEM_PERMS_TABLES does not exist. Currently, this situation is silently ignored, which is likely to lead to further do_rootfs failures. So fix to output a warning, telling user that the specified file in FILESYSTEM_PERMS_TABLES cannot be found. (From OE-Core rev: e14b9f2a667889092251053933dc2f3c51f01ef0) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libc-package: Add risc-v specific options to cross-localedef invocationKhem Raj2018-09-041-0/+2
| | | | | | | | | It was otherwise being deferred until boot time (From OE-Core rev: f8a4ce9b2d59a380d35305a2cd7f73b279bbd8f5) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* distutils-common-base.bbclass: Define commonly used compiler variablesKhem Raj2018-09-041-0/+12
| | | | | | | | | | | | | | | This is inspired from https://github.com/python/cpython/blob/master/configure.ac Helps cross compiling python C modules in some cases where they do not respect normal CFLAGS Errors like using gcc to link when compiler is clang is fixed (From OE-Core rev: 0ab1b35172a41021f5e27c5d17d1e131ce5befd7) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* cpan.bbclass: make RPATH fix more generalJens Rehsack2018-08-281-0/+10
| | | | | | | | | | | | | | | | | Extract a general version of RPATH fix for libxml-parser-perl_2.44.bb from 292471701 libxml-parser-perl: fix "...contains bad RPATH" into cpan.bbclass to catch most errors reported by Khem Raj via http://errors.yoctoproject.org/Errors/Build/66538/ Genrally, Perl 5 toolchain deals with cross-compile sysroots as if a dependency is installed at an exostic place on a server. This issue needs to be addressed wider into the community. (From OE-Core rev: a5439ff9627d309f6980947f5ee573d85e672228) Signed-off-by: Jens Rehsack <sno@netbsd.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-yocto: restore BSP audit visibilityBruce Ashfield2018-08-281-0/+22
| | | | | | | | | | | | | | | | | | | | During the re-working of kernel fragments and status output cleanup the visibility for BSP level errors was dropped/removed. The audit phase can detect errors, redefinition and invalid configuration fragments. We control the visibility of these reports via the existing KCONF_BSP_AUDIT_LEVEL variable. By default, errors and invalid configuration values will be displayed as a warning. If redefinition values are to be shown the audit level must be raised above the deafult value of '2'. We inhibit these by default, since there are many valid reasons why a BSP will change a default / base config .. and showing them offers no value to the BSP user. (From OE-Core rev: 4933b686b0f75d6841630917a2d90832df41cac7) Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes/kernel-yocto: Cleanup getstatusoutput usageJoshua Watt2018-08-281-7/+17
| | | | | | | | | | | | Replace usage of os.utils.getstatusoutput() with direct subprocess calls. Pass a modified environment and working directory where necessary to bypass the need to execute in a shell. (From OE-Core rev: 21de5cc43cfedc703e5bc0515507a6dae36afb74) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sstate.bbclass: make SSTATE_PRUNE_OBSOLETEWORKDIR could be overwrittenKai Kang2018-08-281-1/+1
| | | | | | | | | | Define variable SSTATE_PRUNE_OBSOLETEWORKDIR with '?=' in sstate.bbclass, then it could be overwritten by user configuration. (From OE-Core rev: 22af59c9bfec31b31027ebd2a4da162f481aa6b5) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* terminal.bbclass: use var-SHELL as the shebang of wrapper scriptHongxu Jia2018-08-281-1/+2
| | | | | | | | | | | | | | The devshell.bbclass set var-SHELL to var-DEVSHELL, and terminal.bbclass initial var-SHELL with `bash'. Keep sync with it, use var-SHELL rather than hardcoded `/bin/sh' as the shebang of wrapper script. On Ubuntu host, default shell is dash (/bin/sh -> dash), even though we assign var-SHELL with `/bin/bash', the wrapper script is still dashism. (From OE-Core rev: 27e2ede65f1193e49f9483b08a55495d88740a65) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* package.bbclass: only one hardlink of separated debug info file in each ↵Hongxu Jia2018-08-281-4/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | directory While multiple hardlinks of binary located in different dirs, there are also multiple hardlinks of separated debug info file with the same binary name in same debug dirs. But in each dir, only one debug file with original name works. Because all of binary hardlinks have one `.gnu_debuglink' which is added in `splitdebuginfo'. It caused gdb could not find debugging symbols. [Before the patch] $ find . ./usr/bin/foo ./usr/bin/foo-hd1 ./usr/bin/.debug ./usr/bin/.debug/foo ./usr/bin/.debug/foo-hd1 ./usr/libexec/foo-hd2 ./usr/libexec/.debug ./usr/libexec/.debug/foo-hd2 $ readelf --debug-dump usr/libexec/foo-hd2 Contents of the .gnu_debuglink section: Separate debug info file: foo $ gdb usr/libexec/foo-hd2 Reading symbols from usr/libexec/foo-hd2...(no debugging symbols found)...done. [Before the patch] [Apply the patch] $ find . ./usr/bin/foo ./usr/bin/foo-hd1 ./usr/bin/.debug ./usr/bin/.debug/foo ./usr/libexec/foo-hd2 ./usr/libexec/.debug ./usr/libexec/.debug/foo $ gdb usr/libexec/foo-hd2 Reading symbols from usr/libexec/foo-hd2...Reading symbols from usr/libexec/.debug/foo...done. [Apply the patch] (From OE-Core rev: d4eaf42f7708f8d3a31a04d958bd7420dd7dd6b9) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>