aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes
AgeCommit message (Collapse)Author
2017-10-10sign_rpm.bbclass: force rpm serial signingLeonardo Sandoval
Newer versions of gpg (at least 2.1.5 and 2.2.1) have issues when signing occurs in parallel so (unfortunately) the signing must be done serially. Once the upstream problem is fixed, this patch must be reverted, otherwise we loose all the intrinsic parallelism from bitbake. [YOCTO #12022] Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-10-10kernel.bbclass: fix KERNEL_IMAGETYPE(S) for Image.gzNicolas Dechesne
KERNEL_IMAGETYPES lists all the kernel images that we want to build. in cb17b6c2a7 (kernel.bbclass: support kernel image type of vmlinux.gz), some logic was added to support vmlinux.gz which is not a target built by kernel makefiles (only vmlinux). It is clear that the goal of this logic is only to support vmlinux.gz and not others compressed format (such as Image.gz) which are valid target for kernel makefiles. For Image.gz we should rely on the kernel makefiles and not do the compression in kernel class. This patch updates the logic used to filter out non supported kernel target from KERNEL_IMAGETYPES, and make vmlinux.gz a 'special case', instead of *.gz. If more special cases are needed in the future, we could add them in a similar way. This patch should be a no-op for anyone using vmlinux or vmlinux.gz, and on top of that it is fixing the build for Image.gz which was not working until now. Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit cfc0c897656fe67e81a6a5dcd936dff785529f41) Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-09-22image.bbclass: Sorted ctypes to avoid basehash errorGerson Fernando Budke
When selected multiple subimages a similar error could happend: Variable do_image_cpio[subimages] value changed \ from 'cpio.gz.u-boot cpio.gz' to 'cpio.gz cpio.gz.u-boot' To avoid this, 'ctypes' should be sorted at 'gen_conversion_cmds'. This garantee that 'CONVERSION_CMD_xxx' are always written in tha same order and consequently 'do_image_cpio' have the same hash. (From OE-Core rev: 271f1a5f65b8685a1e3645026876251122ef3974) Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-08-29kernel, license, sstate, rootfs.py: Remove deploy directory READMEMike Crowe
It isn't clear that the README_-_DO_NOT_DELETE_FILES_IN_THIS_DIRECTORY.txt file in the deploy directory warrants the complexity it brings elsewhere. Let's just remove it entirely. In particular, if two do_image_complete tasks run in parallel they risk both trying to put their image into ${DEPLOY_DIR_IMAGE} at the same time. Both will contain a README_-_DO_NOT_DELETE_FILES_IN_THIS_DIRECTORY.txt file. In theory this should be safe because "cp -alf" will just cause one to overwrite the other. Unfortunately, coreutils cp also has a race[1] which means that if one copy creates the file at just the wrong point the other will fail with: cp: cannot create hard link ‘..../tmp-glibc/deploy/images/pantera/README_-_DO_NOT_DELETE_FILES_IN_THIS_D.txt’ to +‘..../tmp-glibc/work/rage_against-oe-linux-gnueabi/my-own-image/1.0-r0/deploy-my-own-image-complete/README_-_DO_NOT_DELETE_FILES_IN_THIS_DIRECTORY.txt’: File exists [1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25680 (From OE-Core rev: 71e9e88847d7000781642ea6187ebd8f40dfdcfe) Signed-off-by: Mike Crowe <mac@mcrowe.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-08-29insane.bbclass: fix override handling in RDEPENDS QAGan Yau Wai
The package_qa_check_rdepends() in insane.bbclass has incorrectly replace its localdata OVERRIDES value with the package name. Fixing it by appending the package name to the existing OVERRIDES value. This resolves RDEPENDS QA error when setting PACKAGECONFIG using a pn- override at local.conf. Cherry picked from master 60d28dd72daee235150ab6605cbf953f1ea691df and modified to work with older bitbake where 2nd parameter in localdata.getVar was mandatory. [YOCTO #11374] Signed-off-by: Gan Yau Wai <yau.wai.gan@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29icecc.bbclass: prevent nativesdk builds depending on target specific KERNEL_CCMartin Jansa
* without this we cause nativesdk-linux-libc-headers to depend on target specific KERNEL_CC (through icecc_get_tool -> icecc_is_kernel -> KERNEL_CC -> HOST_CC_KERNEL_ARCH -> TARGET_CC_KERNEL_ARCH -> TUNE_FEATURES(thumb) as shown by bitbake-diffsigs: OE qemux86@ ~/build/oe-core $ ls /OE/build/oe-core/tmp-glibc/sstate-diff/1499859497/qemu*/*sdk*/*/*do_configure.sigdata* /OE/build/oe-core/tmp-glibc/sstate-diff/1499859497/qemuarm/x86_64-nativesdk-oesdk-linux/nativesdk-linux-libc-headers/4.10-r0.do_configure.sigdata.3a9a423878d56524e0ee8e42eba1804f /OE/build/oe-core/tmp-glibc/sstate-diff/1499859497/qemux86/x86_64-nativesdk-oesdk-linux/nativesdk-linux-libc-headers/4.10-r0.do_configure.sigdata.401071dbaa88903ece37d35a47965ff2 OE qemux86@ ~/build/oe-core $ bitbake-diffsigs /OE/build/oe-core/tmp-glibc/sstate-diff/1499859497/qemu*/*sdk*/*/*do_configure.sigdata* basehash changed from 39774238b66763c598153132e87a2c1a to aa2d66e770bf533e312536eb0a401c4c Variable TARGET_CC_KERNEL_ARCH value changed from '${@bb.utils.contains('TUNE_FEATURES', 'thumb', '-mno-thumb-interwork-marm', '', d)} TUNE_FEATURES{thumb} = Set' to '' Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29image: Fix "metadata is not deterministic" when chaining 2+ CONVERSION_CMDsTom Rini
When we have more than one CONVERSION_CMD being used, for example ext4.gz.sha256sum we will see errors about "metadata is not deterministic". This is because we do not have a stable order of intermediate files that will be removed in the generated shell command. We fix this by calling sorted() on the set of rm_tmp_images so that we will have a stable hash again. Cc: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Tom Rini <trini@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 98a2afeb3a53bec7a72a4a9846e1dba636cc6f3d) Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29image.bbclass: Correct chaining compression supportTom Rini
When chaining of compression/conversion types was added, we had a new way to handle doing things like "ext4.bz2.sha256sum" or "ext2.gz.u-boot". However, because the U-Boot image class isn't included normally, it wasn't properly converted at the time. After the support was added the "clean" argument that the .u-boot code uses no longer functions. The fix for this inadvertently broke chaining compression/conversion. First, correct the u-boot conversion code. Fixes: 46bc438374de ("image.bbclass: do exact match for rootfs type") Cc: Zhenhua Luo <zhenhua.luo@nxp.com> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Tom Rini <trini@konsulko.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 0a7ce0b971a208956cb895ba5a869ec8c5d94703) excluded lz4 and lzo chnages Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29archiver: Escape recipe name in regexJoshua Watt
The recipe name needs to be escaped when using it in a regular expression so that and special characters are treated literally Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29GNU_MIRROR: switch from ftp to httpsMaxin B. John
Based on the same reason behind DEBIAN's switch from ftp: https://www.debian.org/News/2017/20170425 (From OE-Core rev: ba119d836c0f4b20a39c92fa2e64abb0d5a55ad4) Signed-off-by: Maxin B. John <maxin.john@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-08-29DEBIAN_MIRROR: switch from ftp to httpMaxin B. John
All public-facing debian.org FTP services will be shut down on November 1, 2017 The mirrors should just be accessed using HTTP instead. https://www.debian.org/News/2017/20170425 Fixes [YOCTO #11413] (From OE-Core rev: c2cdc4d9155d7a3b9cba60fa9cbb448cf64c62bd) Signed-off-by: Maxin B. John <maxin.john@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-06-16package_ipk: Clean up Source entry in ipk packagesRichard Purdie
There is the potential for sensitive information to leak through the urls there and removing it brings this into the behavior of the other package backends since filtering it is likely error prone. Since ipks don't appear to be generated at all if we don't set this, set the field to the recipe name used (basename only, no paths). This avoids information leaking. We may want to drop the field if opkg can allow that at a future point but the recipe name is a suitable identifier for now. Reported-by: Andrej Valek <andrej.valek@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-13sstate.bbclass: check if mirror directory is writableEd Bartosh
Commit 51edde653707e7a3cd2186082458f01f32cd1996 makes a wrong assumption that SSTATE_MIRRORS have write permissions. A mirror is by definition outside of it's user control. In my use case it happens I does not have permissions to update the access time of the dereferenced symbolic-link file. Checked if file is writable before changing its atime. Thanks to Paulo Neves for the patch. [YOCTO #11307] Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-05-25insane: remove broken unsafe-references-in-binaries testRoss Burton
This test aims to detect binaries in /bin which link to libraries in /usr/lib, for the case where the user has /usr on a separate filesystem to /. However it doesn't scan both image/ and the sysroot, so if a binary in /bin links to a library in /usr/lib that was built by the same recipe then it will error out. This test isn't enabled by default, and because of this serious bug I suspect nobody else is enabling it either. As /usr being on a separate partition to / is a very rare configuration these days I think we should delete the test: if someone cares sufficiently they should write a test that actually works. (From OE-Core rev: a6af5bbf3dad6f0951c67a0aae13ef86a8906893) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-05-18sstate.bbclass: update .siginfo atimeEd Bartosh
.siginfo files are not being accessed from local or NFS-mounted sstate mirrors when sstate package is installed, so their atime is not updated. If sstate mirror is cleaned based on access time, they get deleted, even though they are still being used. Updated atime of .siginfo symlinks with 'touch -a'. This command dereferences symlinks pointing to the local mirror and updates atime of the .siginfo file on the mirror. [YOCTO #10857] Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Denys Dmytriyenko <denys@ti.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-05-18sanity.bbclass: modify check for shellJuro Bystricky
Due to the recently implemented update-alternatives for bash binary, sanity checker may end up with a (false-positive) error such as: Error, /bin/sh links to /bin/bash.bash, must be dash or bash This patch modifies the test: presence of "/bash" or "/dash" in shell binary name results in pass. [YOCTO#11108] Signed-off-by: Juro Bystricky <juro.bystricky@intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-05-18image_types.bbclass: fix image dependency chain collectionAndre McCurdy
If image type "foo" depends on image type "bar.xz", then dependencies should be collected from the base image type (ie "IMAGE_DEPENDS_bar") not from "IMAGE_DEPENDS_bar.xz". Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 8a9f249a9166347cc0468191ce130003e3d306e1) Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-05-18image_types.bbclass: IMAGE_TYPEDEP_ now adds deps for conversion typesRandy Witt
Previously if IMAGE_TYPEDEP_* contained a conversion type of the form, "foo.bar", the dependency on CONVERSION_DEPENDS_bar would not get added to the task depends for do_rootfs. [YOCTO #10883] Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> (cherry picked from commit 037d39898e0e16c6d5b24a8d3844abfb328d3c14) Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-02-08classes: Fix alternatives and rc.d orderingDavid Vincent
When using an alternative as an initscript, the ordering between update-rc.d and update-alternatives tasks during prerm and postinst tasks must always be the following in order to work: * prerm: - stop daemon - remove alternative * postinst: - add alternative - start daemon This patchset adds comments to the scripts generated by both classes and organize the generated sections based on those comments. [YOCTO #10433] Signed-off-by: David Vincent <freesilicon@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> (cherry picked from commit aa87b1a4dcc14e4dfe719b6c55045c5662bc59c2)
2017-01-12populate_sdk_ext: whitelist do_package tasksEd Bartosh
With enabled SSTATE_MIRRORS sstate code expects mirrors to contain entries for all tasks, which is not the case for ext installer as it uses reduced sstate cache. Added do_package tasks to BB_SETSCENE_ENFORCE_WHITELIST to prevent installer failing with ERROR: Sstate artifact unavailable [YOCTO #10832] (From OE-Core rev: 2ed46ada4b8e496493835e84b36f7e9c367f59d2) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-12populate_sdk_ext: fix working with uninative sstateEd Bartosh
Mapped uninative sstate directories to make ext SDK installer to use them when it's run on systems with gcc version different from gcc version used to build installer. [YOCTO #10832] Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-11uninative: Parameterise the use of STAGING_DIRRichard Purdie
This means that a user can change TMPDIR in a multiconfig situation and still only have one path to the uninative setup. Without this change its not possile to make such a setup work. (From OE-Core rev: 779422c5458f5f643b3a4a0dedaa4d9ad709367a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-11uninative: rebuild uninative for gcc 4.8 and 4.9Ed Bartosh
Some c++ libraries fail to build if uninative is built with gcc 5.x and host gcc version is either 4.8 or 4.9. The issue should be solved by making separate uninative sstate directory structure sstate-cache/universal-<gcc version> for host gcc versions 4.8 and 4.9. This causes rebuilds of uninative if host gcc is either 4.8 or 4.9 and it doesn't match gcc version used to build uninative. [YOCTO #10441] (From OE-Core rev: d36f41e5658bbbb6080ee833027879c119edf3e0) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel-yocto: explicitly trap subcommand errorsBruce Ashfield
To trap errors and halt processing, do_kernel_metadata was recently switched to exit on any non zero return code. While the concept is sound, there are subcommands that have legitimate non-zero return codes. Instead of removing set +e, we'll explicitly check the return code of the commands that can error, and throw a bbfatal to alert the user. (From OE-Core rev: a4705e62d0973c290011fc0d250501d358b659e8) Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11archiver: don't change directory when generating tarballRoss Burton
There's no need to chdir() as tarfile.add() can be told what name to use in the archive. (From OE-Core rev: d0b282bce34db44dde4dd7f53a64dfaafe6789de) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11cve-check: allow recipes to override the product nameRoss Burton
Add a new variable CVE_PRODUCT for the product name to look up in the NVD database. Default this to BPN, but allow recipes such as tiff (which is libtiff in NVD) to override it. (From OE-Core rev: ba330051570a4c991885ee726cb187e0c911bd4f) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel.bbclass: fix kernel_do_compile for KERNEL_IMAGETYPE = "vmlinux.gz" on ↵Andreas Oberritter
mips The target directory didn't exist. (From OE-Core rev: bd62851dc236a0279c735b290782602e275de5c1) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel.bbclass: do not copy bundled initramfs to /bootAndreas Oberritter
These files cause warnings because they don't get packaged, now that they don't land in kernel-vmlinux anymore. (From OE-Core rev: a49569e3a7534779bbe3f01a0647fd076c95798d) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel.bbclass: Avoid wildcards for kernel imagesAndreas Oberritter
With multiple kernel images enabled starting with 'vmlinux', e.g. vmlinux.gz and vmlinux.bin, all files landed inside the kernel-vmlinux package. On top of that, even initramfs images were included, e.g. vmlinux.gz-initramfs-*. (From OE-Core rev: b7f4133b44b740e8ac8e758b0d4a3ee32d326332) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel.bbclass: Use real filenames in kernel packagesAndreas Oberritter
When iterating over kernel image types to set up their packaging variables, don't use make targets but the real names. It was surprising if both vmlinux.bin and vmlinux.gz were enabled and only the latter had its filename extension removed from the package name. (From OE-Core rev: aa189f183e10588f7e8d642f351bd9b8d69f3ea9) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel.bbclass: allow uncompressed initramfs archivesAndreas Oberritter
The code failed to copy the initramfs in case it was a plain cpio archive. (From OE-Core rev: 7dbdb4ea91aa027866da2bd46c65fe65a25c848f) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11staging: Drop unused SYSROOT_LOCKRichard Purdie
This hasn't been used in years and isn't referenced anywhere, drop the definition. (From OE-Core rev: 68258f856f08f35813964e58ef761471e29373ad) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11kernel-yocto: exit on non-zero return codeBruce Ashfield
Historically the processing of kernel meta data contained some commands that exited with a non-zero return code. Special processing was required to properly deal with their exit. That is no longer true, and instead of handling all return codes and doing an explicit 'exit' call, we can remove set -e from the routine and have all errors be trapped and stop processing. (From OE-Core rev: 476ffd57cf5b6fba40d4e3f5dd913824ab8a8d3d) Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11systemd.bbclass: don't block on service restartMark Asselstine
The current class works fine when a recipe uses SYSTEMD_AUTO_ENABLE 'enable' and has no on device pkg_postinst(), ie when the postinst is run as part of rootfs creation. However, when there is a component of pkg_postinst() that is run on device the 'systemctl restart' is run as part of the run_postinsts.service at boot. This results in the boot spinning indefinitely with: [ *** ] A start job is running for Run pending postinsts (7s / no limit) The issue could potentially be that the packages service has an 'After' clause which comes later in the boot, beyond run_postinsts.service, creating a chicken before the egg scenario. Even service files without an 'After' clause cause this situation however. Despite this not being the cause of the issue this fix will prevent this scenario from happenning. Using strace we are able to find that during boot, when run_postinsts.service is running attempting to start or restart any service will result in the call get stuck on poll(). Since the run_postinsts.service does not monitor the outcome of the call to restart we can work around this by using '--no-block'. (From OE-Core rev: 6ad6a0084a73088fc2a27ab9958e5c46d6e094fc) Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11insane: rewrite the expanded-d test as a QAPKGTESTRoss Burton
Instead of being executed for every file in every package, this is now just called for each package. It is also now correctly called for packages which don't have any content but do have postinst scripts. [ YOCTO #10711 ] (From OE-Core rev: afda72b2424528eaff9054327530bdf5654bec66) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11insane: add QAPKGTEST, a package-wide equivilant to QAPATHTESTRoss Burton
QAPATHTEST defines a function that is executed for every file in every package. For tests which just need to look at the datastore this is massive overkill. Add QAPKGTEST, which is invoked for each package in the recipe. (From OE-Core rev: acc3cc26099c77e4eeb44c75bc7167ab58ef1147) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11insane: factor out the test matrix processingRoss Burton
Pull the test matrix processing out as a function so it can be reused. (From OE-Core rev: 3caccd3f6079b7e284d32e1eb0217107425e7bf8) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11insane: fix expanded-d testRoss Burton
This test should be looking for the expanded value of ${D} in the expanded value of pkg_postinst and so on, but one of the getVar() calls was passing expand=False so the test would never be true. (From OE-Core rev: cc545044cba51317bee32e3bf674723e422e3a8a) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11insane: Add aarch64 baremetal mappings to the QA arch testAlexandre Belloni
Add mappings for aarch64-elf and aarch64_be-elf to binary lookup table which allows for the generation of baremetal toolchains. (From OE-Core rev: e90a1c4b8fd7baa738eb4683e5eac60905e04296) Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11conf: add C++ flags for uninative interoperatilityRoss Burton
Create a common include file for compiler flags which allow native binaries to be interoperable on a wide range of hosts. In particular the C++ ABI is problematic so choose the CXX11 version to allow interoperation between gcc4 and gcc5 based hosts. Moving this to a common include instead of uninative.bbclass allows uninative to be configured later and used in the eSDK (where its mandatory) even if the base configuration doesn't enable uninative by default (e.g. nodistro in OE-Core). [ YOCTO #10645 ] (From OE-Core rev: 60c912ae9306532bdd4c5e09a65863ee77c12f43) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11cmake.bbclass: Set CXXFLAGS and CFLAGSKhem Raj
We strip the TOOLCHAIN_OPTIONS and HOST_CC_ARCH from CC/CXX in cmake.bbclass whereas CFLAFS and CXXFLAGS assume that TOOLCHAIN_OPTIONS are part of CC/CXX variables, this causes compile failures when cmake is running compiler tests during configure on some architectures especially armhf, because hf ABI information -mfloat-abi is part of TOOLCHAIN_OPTIONS, so what happens is that testcase gets compiled without hard-float, howver, during linking the float ABI option is passed via LDFLAGS, now linker rejects this and fails like /mnt/a/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/6.2.0/ld: error: cmTC_27947 uses VFP register arguments, CMakeFiles/cmTC_27947.dir/src.cxx.o does not mnt/a/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/6.2.0/ld: failed to merge target specific data of file CMakeFiles/cmTC_27947.dir/src.cxx.o collect2: error: ld returned 1 exit status This means that CMake now fails the configure time test too which is not right, e.g. it might disable features which actually do exist and should be enabled e.g. in case above it is resulting as below Performing C++ SOURCE FILE Test HAS_BUILTIN_SYNC_SUB_AND_FETCH failed with the following output: Its actually a bug in CMake see https://gitlab.kitware.com/cmake/cmake/issues/16421 CMake is ignoring CMAKE_CXX_FLAGS when using CHECK_CXX_SOURCE_COMPILES function. Until it is fixed upstream, we add HOST_CC_ARCH and TOOLCHAIN_OPTIONS to CFLAGS and CXXFLAGS, so that we can ensure that compiler invocation remains consistent. (From OE-Core rev: 826f3cdb474b5728b22f08d2342fc90235ca9e7d) 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> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2017-01-11cve-check.bbclass: CVE-2014-2524 / readline v5.2André Draszik
Contrary to the CVE report, the vulnerable trace functions don't exist in readline v5.2 (which we keep for GPLv2+ purposes), they were added in readline v6.0 only - let's whitelist that CVE in order to avoid false positives. See also the discussion in https://patchwork.openembedded.org/patch/81765/ (From OE-Core rev: b881a288eec598002685f68da80a24e0478fa496) Signed-off-by: André Draszik <adraszik@tycoint.com> Reviewed-by: Lukasz Nowak <lnowak@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16rm_work: Ensure we don't remove sigbasedata filesRichard Purdie
We don't remove sigdata files, we also shouldn't remove sigbasedata files as this hinders debugging. (From OE-Core rev: 988349f90c8dc5498b1f08f71e99b13e928a0fd0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-11-16sstate: Ensure we don't remove sigbasedata filesRichard Purdie
We don't remove sigdata files, we also shouldn't remove sigbasedata files as this hinders debugging. (From OE-Core rev: 1ebd85f8dfe45b92c0137547c05e013e340f9cec) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-11-16classes/populate_sdk_ext: prevent invalid TEMPLATECONF entering eSDKPaul Eggleton
If you are using a repository which contains a .templateconf file that sets TEMPLATECONF to point into a layer it contains, but you aren't using that layer in your bblayers.conf, the eSDK would produce an error during the preparation step of the installation. An example would be using the poky repository but setting DISTRO to your own custom distro and removing meta-poky from your bblayers.conf. The eSDK doesn't support creating new build directories, so we don't care about the templates and can thus force a known good value to prevent this from happening. Fixes [YOCTO #10568]. (From OE-Core rev: 5ee32191a18013061dfa72e64713a94c5d321496) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16testsdk.bbclass: Clean up comments, clarify image choices.Robert P. J. Day
Make it clear that SDK testing can use any valid image. (From OE-Core rev: d190c69347921a626665a53469dcf99b3c86994b) Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16insane.bbclass:buildpaths: open() file with 'rb'Robert Yang
open() is default to 'rt' which may cause decoding errors when open binary file: $ bitbake xcursor-transparent-theme [snip] Exception: UnicodeDecodeError: 'utf-8' codec can't decode byte 0xfd in position 18: invalid start byte [snip] (From OE-Core rev: ddbab61f47efd9b4fde38ef8f0f3482c78abe37c) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16classes/nativesdk: set SDK_OLDEST_KERNEL appropriatelyPaul Eggleton
SDK_OLDEST_KERNEL currently only controls the check on SDK installation, however as with OLDEST_KERNEL it should be controlling the OLDEST_KERNEL value for building glibc used in the SDK. Thus, set it in nativesdk.bbclass. This means we need to move the default to bitbake.conf so that it can be seen in both places. Also set a more reasonable default for SDK_OLDEST_KERNEL for x86/x86-64 as glibc 2.24 still supports back to 2.6.32 there and there are still people wanting to build SDKs that will install on older distros (e.g. CentOS 6). However it's not possible to set this with overrides since there aren't any for the SDK_ARCH, however we can instead set the variable from conf files in conf/machine-sdk especially as there is now a soft default for SDKMACHINE. Fixes [YOCTO #10561]. (From OE-Core rev: 42d5781e31c5bf76b5b7e27abed4f6f3fd65bf40) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16classes/populate_sdk_base: fix usage of & character in SDK_TITLEPaul Eggleton
If you used an & character in SDK_TITLE (possibly indirectly from DISTRO_NAME) then sed interpreted this as a directive to paste in the replaced string (@SDK_TITLE@ in this case). Escape any & characters in SDK_TITLE to avoid that. (From OE-Core rev: acb85689c13cfdac21435509001048af5c3a7e99) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2016-11-16uboot-sign: fix do_concat_dtb for .img, .romGeorge McCollister
Now that out of tree building is enabled, ${B} must be used instead of ${S} as the path for UBOOT_BINARY. (From OE-Core rev: 1fe17c52e4d7ce1b9d69aaa2cd9d4b351a4b2603) Signed-off-by: George McCollister <george.mccollister@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>