aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2018-11-30uboot-sign.bbclass: fix signature and deploymentrbt/ubootRobert Yang
Fixed: MACHINE = "beaglebone-yocto" KERNEL_CLASSES += "kernel-fitimage" KERNEL_IMAGETYPE_beaglebone-yocto = "fitImage" UBOOT_MACHINE_beaglebone-yocto = "am335x_boneblack_vboot_config" UBOOT_MKIMAGE_DTCOPTS = "-I dts -O dtb -p 2000" UBOOT_SIGN_KEYDIR = "${TOPDIR}/conf" UBOOT_SIGN_KEYNAME = "dev" UBOOT_SIGN_ENABLE = "1" IMAGE_INSTALL_remove = "kernel-image-zimage" $ cd conf $ openssl genrsa -F4 -out dev.key 2048 $ openssl req -batch -new -x509 -key dev.key -out dev.crt $ cd ../ $ bitbake u-boot linux-yocto $ grep signature tmp/deploy/images/beaglebone-yocto/*.dtb Binary file tmp/deploy/images/beaglebone-yocto/u-boot-beaglebone-yocto-2018.07-r0.dtb matches Binary file tmp/deploy/images/beaglebone-yocto/u-boot-beaglebone-yocto.dtb matches Binary file tmp/deploy/images/beaglebone-yocto/u-boot.dtb matches And there would be no signature info when rebuild from sstate: $ bitbake u-boot linux-yocto -cclean $ bitbake u-boot linux-yocto $ grep signature tmp/deploy/images/beaglebone-yocto/*.dtb No result This s because kernel directly edit ${DEPLOY_DIR_IMAGE}/u-boot.dtb, (Note, it is global ${DEPLOY_DIR_IMAGE}, not recipe's DEPLOYDIR), so that the modified info is not in sstate, and would be lost when rebuild from sstate. There are other problems in previouse code: - The u-boot.dtb is provided by u-boot, but edited by kernel during signing, so it should be deployed by kernel rather than u-boot. - The u-boot.do_concat_dtb directly install files to global ${DEPLOY_DIR_IMAGE}, this is incorrect, the ${DEPLOY_DIR_IMAGE} should be installed by do_deploy. - It seems that it assumes do_deploy depends on do_install according the comments, but they have no relationships: # do_concat_dtb is scheduled _before_ do_install as it overwrite the # u-boot.bin in both DEPLOYDIR and DEPLOY_IMAGE_DIR. - The do_concat_dtb should be run after do_compile, but it doesn't have this dependency. Make u-boot install u-boot.dtb to ${datadir}, kernel copies u-boot.dtb from ${STAGING_DATADIR} to ${B} and deploy it can fix the problem. [YOCTO #12112] Reported-by: Christian Andersen <c.andersen@kostal.com> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
2018-11-29musl: Update to latest trunkKhem Raj
Complete changelogs are here https://git.musl-libc.org/cgit/musl/log/?qt=range&q=c50985d5c8e316c5c464f352e79eeebfed1121a9..39ef612aa193cc6e954ac5a01574300ccd4b7ef9 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/sdk/python: add Python 2 and fix detectionRoss Burton
Add a Python 2 form to exercise that if present, and fix the setUp() so it actually looks for a package that exists (nativesdk-python3 is a virtual package, the interpretter is in nativesdk-python3-core). Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29libc-package: fix postinst error when ENABLE_BINARY_LOCALE_GENERATION = "0"Alexander Kanavin
[YOCTO #13028] Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29classes/update-alternatives: Skip alternatives when disabledJoshua Watt
Skips the update alternative steps for recipes that shouldn't have them enabled. Fixes errors like: nativesdk-bzip2-1.0.6-r5 do_package: bzip2: alternative target (/opt/poky/2.5+snapshot/sysroots/i686-pokysdk-mingw32/usr/bin/bunzip2 or /opt/poky/2.5+snapshot/sysroots/i686-pokysdk-mingw32/usr/bin/bunzip2.bzip2) does not exist, skipping... When building mingw SDKs [YOCTO #12962] Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/selftest/recipeutils: Fix parallel selftest failuresRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29python: Adds instructions to the manifest fileAlejandro Enedino Hernandez Samaniego
While there is a bit of documentation regarding building a new manifest file for python, it seems that users usually only read the manifest file. The manifest file is in JSON format which doesn't allow comments, hence why instructions were initially put elsewhere. This patch hacks the call to open the JSON manifest file by using a marker to trick it into reading only part of the file as the manifest itself, and keep the other part as comments, which contain instructions for the user to run the create_manifest task after an upgrade or when adding a new package. Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29python3: Adds instructions to the manifest fileAlejandro Enedino Hernandez Samaniego
While there is a bit of documentation regarding building a new manifest file for python, it seems that users usually only read the manifest file. The manifest file is in JSON format which doesn't allow comments, hence why instructions were initially put elsewhere. This patch hacks the call to open the JSON manifest file by using a marker to trick it into reading only part of the file as the manifest itself, and keep the other part as comments, which contain instructions for the user to run the create_manifest task after an upgrade or when adding a new package. Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29libtasn1: no need to inherit binconfigRoss Burton
This recipe doesn't ship a *-config binary, so don't inherit binconfig. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29image_types: use cpio-native to build cpio imagesRoss Burton
As per the previous commit, upstream cpio has a bug which means it crashes on append. If the image being built has already had testimage ran then cpio-native will be in the sysroot. It's also possible that some distributions are shipping this broken CVE patch too. Now that our cpio-native is fixed, until we can be sure that the host cpio isn't broken depend on cpio-native if building a cpio image. [ YOCTO #13042 ] Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29cpio: fix crash when appending to archivesRoss Burton
The upstream fix for CVE-2016-2037 introduced a read from uninitialized memory bug when appending to an existing archive, which is an operation we perform when building an image. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/selftest/context: Improve log file handlingRichard Purdie
The existing logfile is simply placed in the current directory. Since the test changes cwd to BUILDDIR, the symlink to the log can be placed in an invalid directory. We also see trackbacks if the symlink is invalid. Improve things by: * Placing logs in LOG_DIR (or BUILDDIR if unset). * Using a full path to the log meaning the log and link are placed in the same directory. * Using lexists instead of exists so invalid symlinks are handled correctly. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29meta-selftest/error: Cleanup large trailing whitespaceRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/selftest/buildoptions: Ensure diskmon tests run consistentlyRichard Purdie
Heartbeat events default to once a second and we need to ensure we have enough time in the task to see them. Add a nostamp delay task 5s long so we can have a consistently timed task which doesn't need cleanup or have unneeded dependencies. This ensures we should deterministically see the disk moinitor events regardless of the state of the build. This is done in a way which doesn't corrupt build state or need cleanup and is efficient. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/selftest/runcmd: Increase timeout deltaRichard Purdie
Expecting 1s accuracy on a 2s timeout on a heavily loaded system has proven to be unreliable. Update this to a 5s timeout with a 3s delta which should be achievable. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oeqa/selftest/buildoptions: Improve ccache testRichard Purdie
This test occisionally fails as m4 doesn't recompile, meaning the logfile test then doesn't find mention of ccache. To ensure m4 does recompile, clean m4 before force compiling it. (Reading the test is confusing due to the test cleanup also involving a clean) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29python-native: fix one do_populate_sysroot warningChangqing Li
Fix below warning: WARNING: Skipping RPATH /usr/lib64 as is a standard search path for work/x86_64-linux/python-native/2.7.15-r1.1/recipe-sysroot-native/ usr/lib/python2.7/lib-dynload/_bsddb.so setup.py will check db.h under include_dirs, for native build, /usr/lib64 will be insert to postion 0 of include_dirs, so it's priority is higher then our sysroot, cause db.h sysroot is ignored, and rpath set to /usr/lib64. and this cause warning when do_populate_sysroot. use append to fix it. Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29nspr: improve reproducibilityMingli Yu
Remove _BUILD_STRING and _BUILD_TIME in _pl_bld.h to avoid introducing timestamp in the .so library such as libnspr4.so as below: $ readelf --wide --decompress --hex-dump=.rodata libnspr4.so [snip] 0x00004000 32303138 2d31312d 31352030 353a3439 2018-11-15 05:49 [snip] [YOCTO #12639] Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29ghostscript: 9.25 -> 9.26Hongxu Jia
- Drop backported CVE fixes 000[1-8]*.patch Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29attr: Strip build host paths and tool versions from ptest filesDouglas Royds
Using the new PTEST_BUILD_HOST_FILES mechanism. Specifically remove reference to build host rpm version, if any. Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29acl: Strip build host tool details from installed ptest fileDouglas Royds
Adopt the PTEST_BUILD_HOST_FILES mechanism to strip build host paths from the installed builddefs file. Also strip the record of the build host rpm version. Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29acl: Use install instead of cpDouglas Royds
Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29strace: Strip build host tool details from installed ptest MakefileDouglas Royds
Adopt new PTEST_BUILD_HOST_PATTERN mechanism. Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29openssl: Strip perl version from installed ptest configdata.pm fileDouglas Royds
Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29openssl ptest: Strip build host paths from configdata.pmDouglas Royds
This file contains CC, CPP, CFLAGS, CXXFLAGS and the like. Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29ptest: Optionally strip build host tool info from installed filesDouglas Royds
Several packages (eg. acl, attr, openssl) install Makefiles or other build host configuration files for ptest so that they can run `make check`, for instance. These build host files commonly include paths and versions of build host tools, (eg. rpm or perl) whose presence and version depends on the build host distro. Optionally strip lines from installed PTEST_BUILD_HOST_FILES using an extended regex pattern defined in PTEST_BUILD_HOST_PATTERN. This has no effect on the on-target ptest. Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29ptest: Reproducibility: Strip build host paths from any installed MakefileDouglas Royds
A common pattern for ptest is to install a Makefile that provides a make check target. These generated Makefiles are normally full of build host paths, to hosttools, and to files and scripts within the source or build tree. They also commonly include the CFLAGS and CPPFLAGS. None of these build host paths can possibly work on-target, so stripping them has no effect on the success of the resulting ptests. Stripping the HOSTTOOLS_DIR has this effect, for instance: -MKDIR_P = /home/douglas/workspace/upstream/build/tmp/hosttools/mkdir -p +MKDIR_P = mkdir -p The curious WORKDIR/*= pattern avoids non-parseable -fdebug-prefix-map patterns in the CFLAGS by adding an arbitrary ".", eg: -fdebug-prefix-map=.=/usr/src/debug/rsyslog/8.37.0-r0 In all other cases, we simply remove the WORKDIR, eg: CPP = arm-tait-linux-gnueabi-gcc -E --sysroot=recipe-sysroot ... Signed-off-by: Douglas Royds <douglas.royds@taitradio.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-29oe-selftest: add some tests for recipeutils modulePaul Eggleton
Add some tests for functions in meta/lib/oe/recipeutils.py, in particular for a few issues I've just fixed. I haven't added tests for all of the functions - some of them are already being tested via devtool in any case. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28lib/oe/recipeutils: drop obsolete functionsPaul Eggleton
These date from the time before Tinfoil's API covered this functionality (back when you could actually access cooker from a tinfoil-based script). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28lib/oe/recipeutils: patch_recipe(): fix replacing varflag valuesPaul Eggleton
The code here wasn't correctly getting the variable history for varflags, so for example if you did a devtool upgrade on a recipe where the SRC_URI checksums were in the .inc file (typical for python recipes in order to support both python 2 and 3) then after the upgrade the new values would be set in the recipe and the old values were left in the .inc, which is not right. Teach the code here how to get the history for varflags so it works properly. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28lib/oe/recipeutils: patch_recipe(): fix handling of values across ↵Paul Eggleton
includes/classes If we were setting a variable and part of the variable's value was being set in a class or a .inc file, we were still just setting the value outright on the assumption that it was too hard to do otherwise. With some careful use of the variable history we can do better for certain situations i.e. when the recipe does not currently set the value outright. Additionally, correctly remove _appends for variables we are changing if we're trying to remove the value added in the _append. Fixes [YOCTO #12623] and partially fixes [YOCTO #9360]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28scripts/runqemu: Improve lockfile handling for python with close_fd=TrueRichard Purdie
On python versions with close_fds=True (python 3.2 onwards), the tap device lockfile isn't passed to the child process. Since this guards against use of an active interface, we really want this here, so pass it in pass_fds. This means if the parent exits early, the child still holds the lock, avoiding messages like: runqemu - ERROR - Failed to run qemu: qemu-system-x86_64: could not configure /dev/net/tun (tap0): Device or resource busy Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28scripts/runqemu: Tidy up lock handling codeRichard Purdie
Various tweaks: - Balance up the aquire/release functions - Use debug messge for both acquiring and release message for consistency in logs - Use None instead of an empty string - Reset the value of the field if we don't have the lock any more Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28oeqa/qemurunner: Remove resource python warningsRichard Purdie
If runqemu fails it would leak an unclosed socket and file. Ensure we close these in all cases to remove the resource warning. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28scripts/runqemu: Fix logic error causing failures with MACHINE from the ↵Richard Purdie
environment MACHINE=qemux86-64 oe-selftest -r runqemu.RunqemuTests.test_boot_machine_slirp_qcow2 fails yet oe-selftest -r runqemu.RunqemuTests.test_boot_machine_slirp_qcow2 with MACHINE in local.conf would work. It turns out that: runqemu slirp wic.qcow2 qemux86-64 works but: MACHINE=qemux86-64 runqemu slirp wic.qcow2 qemux86-64 does not. The reason are the misplaced return statements in runqemu, its skipping a block of logic when MACHINE is set in the environment when it shouldn't. Fix this. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28oeqa/utils/commands: Avoid log message duplicationRichard Purdie
Each time a runqemu() fails, the log handler would be left behind meaning messages from any subsequent run would be duplicated (or worse/more). This ensures we remove the handler regardless and means we no longer have the duplication. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-28oeqa/utils/qemurunner: Fix python ResourceWarning for unclosed fileRichard Purdie
Fixes: Stderr: /media/build1/poky/meta/lib/oeqa/utils/qemurunner.py:381: ResourceWarning: unclosed file <_io.BufferedWriter name=16> self.runqemu = None Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27python/python3: use cc_basename to replace CC for checking compilerChangqing Li
When working path contains "clang"/"gcc"/"icc", it might be part of $CC because of the "--sysroot" parameter. That could cause judgement error about clang/gcc/icc compilers. eg: if build under /yocto/builds/xicc/, bitbake python, $CC will contains xicc, will make $CC match *icc, but actuall xicc just folder name. When "*icc" is matched, below errors are reported when compiling python/python3: x86_64-wrs-linux-gcc: error: strict: No such file or directory x86_64-wrs-linux-gcc: error: unrecognized command line option '-fp-model' Here use cc_basename to replace CC for checking compiler to avoid such kind of issue. Signed-off-by: Li Zhou <li.zhou@windriver.com> Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27meson: Correct use of the _append operatorPeter Kjellerstedt
The value to SRC_URI_append_class-native was not prefixed with a space. This was not noticed as the SRC_URI before applying the _append contains trailing spaces. However, if one, e.g., has a .bbappend and adds to the SRC_URI using SRC_URI += "file://foo.patch", then there no longer is any trailing space and the _append concatenates the two URIs together, leading to a build failue. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27oeqa/utils/commands: Add extra qemu failure loggingRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27uboot-sign.bbclass: Remove tab indentations in python codeRobert Yang
Use 4 spaces to replace a tab. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27netbase: add entry to /etc/hosts according to /etc/hostnameChen Qi
We default hostname to ${MACHINE}, but it's not in /etc/hosts, resulting in commands like `hostname -f' failing due to lack of entry. So add entry to /etc/hosts according to /etc/hostname. We do this via pkg_postinst because hostname is set in base-files recipe. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gst-validate: upgrade 1.14.2 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-python: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-omx: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-rtsp-server: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-vaapi: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-libav: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-plugins-ugly: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-27gstreamer1.0-plugins-bad: upgrade 1.14.3 -> 1.14.4Anuj Mittal
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>