]> code.ossystems Code Review - openembedded-core.git/log
openembedded-core.git
7 years agoyocto-compat-layer.py: allow README with suffix
Patrick Ohly [Tue, 27 Jun 2017 15:33:42 +0000 (17:33 +0200)]
yocto-compat-layer.py: allow README with suffix

It may be useful to append a suffix denoting the file format. For
example, README.rst is rendered differently when viewed on Github, and
also helps editors to switch to a mode more suitable for the format.

The tests uses a file pattern to find the README file(s) and treats
the one with the shortest name as the main one which must not be
empty.

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoyocto-compat-layer.py: add test_world
Patrick Ohly [Tue, 27 Jun 2017 15:33:41 +0000 (17:33 +0200)]
yocto-compat-layer.py: add test_world

"test_signatures" ignores wold build breakage for the sake of
reporting differences also when a world build is broken. Therefore we
need a dedicated test that a world build at least theoretically can
proceed without obvious parse time problems (dependencies, parse
errors, dangling .bbappends, etc.).

This is similar to the BSP test_machine_world. The difference is
that test_world doesn't change the MACHINE.

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoyocto-compat-layer.py: apply test_signatures to all layers
Patrick Ohly [Tue, 27 Jun 2017 15:33:40 +0000 (17:33 +0200)]
yocto-compat-layer.py: apply test_signatures to all layers

Software layers were previously allowed to change signatures, but
that's not desired for those layers either. The rule that a layer
which is "Yocto Compatible 2.0" must not change signatures unless
explicitly requested holds for all kinds of layers.

However, as this is something that software layers might not be able
to do right away, testing for signature changes in software layers can
be disabled. It's on by default, as that was Richard's
recommendation. Whether that should change needs further discussion as
part of finalizing "Yocto Compatible 2.0".

As it might still change, the tool now has both a with/without
parameter so that users of the tool can choose the desired behavior
without being affected by future changes to the default.

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoyocto-compat-layer.py: tolerate broken world builds during signature diff
Patrick Ohly [Tue, 27 Jun 2017 15:33:39 +0000 (17:33 +0200)]
yocto-compat-layer.py: tolerate broken world builds during signature diff

The "test_signatures" test ignored a broken world build when getting
signatures, but the code which then tried to analyze a difference
found by the test didn't, which prevented printing the difference.

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoyocto-compat-layer.py: avoid adding layers more than once
Patrick Ohly [Tue, 27 Jun 2017 15:33:38 +0000 (17:33 +0200)]
yocto-compat-layer.py: avoid adding layers more than once

add_layer_dependencies() might get called more than once, or one of
the layer dependencies might already be present. The function should
not add layers again because doing so can cause warnings like:

  WARNING: Duplicate inclusion for .../meta-openembedded/meta-oe/conf/distro/include/meta_oe_security_flags.inc in .../meta-openembedded/meta-oe/conf/layer.conf

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoiptables: Apply 0001-fix-build-with-musl.patch unconditionally
Khem Raj [Mon, 26 Jun 2017 05:36:19 +0000 (22:36 -0700)]
iptables: Apply 0001-fix-build-with-musl.patch unconditionally

This patch is generic enough, That it can be applied universally
and makes maintainence easier

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
(cherry picked from commit f769b8389091b4ffaff8f6f8fc7e53462ce176a5)
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agotzcode-native: quote ${CC}
Enrico Scholz [Fri, 23 Jun 2017 11:19:12 +0000 (13:19 +0200)]
tzcode-native: quote ${CC}

build fails else with

| + make -j 8 -l 6 cc=ccache gcc
| make: *** No rule to make target 'gcc'.  Stop.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: Ross Burton <ross.burton@intel.com>
(cherry picked from commit 5729c1563359e12ebb4451bb1ce7ba3fff4ed2d4)
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoqemuboot.conf: make cpus match built artifacts
Martin Kelly [Tue, 2 May 2017 19:20:13 +0000 (12:20 -0700)]
qemuboot.conf: make cpus match built artifacts

Currently, the qemu CPUs for are specified as generic, but the built
artifacts are not. For example, we build x86-64 artifacts targeting
core2duo but run them in qemu with generic qemu/kvm CPUs. This causes
some packages that take advantage of the host architecture to crash
because they try to use CPU features not advertised by qemu. As an
example, Qt uses ssse3. When artifacts linked against Qt and built
targeting core2duo attempt to run on a generic qemu/kvm CPU, we get
the following crash:

Incompatible processor. This Qt build requires the following features:
     ssse3

We could fix this by making packages like Qt not take advantage of CPU
features. However, we will probably keep facing similar issues over
time, so it's better to resolve them in a more enduring way.

Fix this by making the qemu -cpu arguments match the built artifacts.

(From OE-Core rev: 20b3574749420a1fef2cb2e0579584453dd4c5c5)

Signed-off-by: Martin Kelly <mkelly@xevo.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>
7 years agopackage_manager.py: set dnf's releasever setting from DISTRO_CODENAME
Alexander Kanavin [Wed, 21 Jun 2017 12:58:21 +0000 (15:58 +0300)]
package_manager.py: set dnf's releasever setting from DISTRO_CODENAME

So that:

1) dnf does not complain anymore about releasever not being set and then fail
for the same reason;

2) it's possible to refer to $releasever in dnf package feed configuration
(repo paths in particular) without hardconding the release name (pyro, morty, etc.)

(From OE-Core rev: 789e3fc225adbb61f10aaa3bbc3677856f5f0238)

Signed-off-by: Alexander Kanavin <alexander.kanavin@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>
7 years agozlib: Pass pre-calculate uname enable re-entrant flags
Khem Raj [Tue, 13 Jun 2017 23:13:44 +0000 (16:13 -0700)]
zlib: Pass pre-calculate uname enable re-entrant flags

Fix ptest generation

(From OE-Core rev: 07f4b0f016225e2b211689a270e56b2923ecb434)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agogit: Add a dependency on perl for gitweb
Peter Kjellerstedt [Thu, 15 Jun 2017 13:53:08 +0000 (15:53 +0200)]
git: Add a dependency on perl for gitweb

(From OE-Core rev: db31c837b579dc64bc86553cbc95736bfca97a90)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.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>
7 years agotexi2html: Add a dependency on perl
Peter Kjellerstedt [Thu, 15 Jun 2017 13:53:07 +0000 (15:53 +0200)]
texi2html: Add a dependency on perl

(From OE-Core rev: c391547e95b1854960b90d93fd9f80f02f761e61)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.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>
7 years agolinux-firmware: Avoid a dependency on python-core
Peter Kjellerstedt [Thu, 15 Jun 2017 13:53:06 +0000 (15:53 +0200)]
linux-firmware: Avoid a dependency on python-core

Remove the check_whence.py script since it is only needed to validate
the WHENCE file, and only if explicitly running `make check`.

(From OE-Core rev: 1fc4d5a31f05970d8d80b0106ea81d486f298e33)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.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>
7 years agolibpcap: apply fix from upstream to fix build race
Ross Burton [Fri, 16 Jun 2017 12:32:15 +0000 (13:32 +0100)]
libpcap: apply fix from upstream to fix build race

../libpcap-1.8.1/grammar.y:78:10:
fatal error: scanner.h: No such file or directory

(From OE-Core rev: aaed4e92d79919e40c896536fcb4ff6567c9a755)

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>
7 years agotzdata: Install zone1970.tab
Jan Kiszka [Fri, 16 Jun 2017 07:28:05 +0000 (09:28 +0200)]
tzdata: Install zone1970.tab

The modern version of zone.tab is required by tzselect e.g.

(From OE-Core rev: de467998ecfa5fa1d2e9dd43a4a3d828cf9ccade)

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.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>
7 years agolibxml2: Fix CVE-2017-0663
Andrej Valek [Wed, 14 Jun 2017 13:07:56 +0000 (15:07 +0200)]
libxml2: Fix CVE-2017-0663

Fix type confusion in xmlValidateOneNamespace

Comment out code that casts xmlNsPtr to xmlAttrPtr. ID types
on namespace declarations make no practical sense anyway.

Fixes bug 780228

CVE: CVE-2017-0663
(From OE-Core rev: a965be7b6a1d730851b4a3bc8fd534b9b2334227)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agolibxml2: Fix CVE-2017-5969
Andrej Valek [Wed, 14 Jun 2017 13:01:35 +0000 (15:01 +0200)]
libxml2: Fix CVE-2017-5969

Fix NULL pointer deref in xmlDumpElementContent

Can only be triggered in recovery mode.

Fixes bug 758422

CVE: CVE-2017-5969
(From OE-Core rev: 0cae039cbe513b7998e067f4f3958af2ec65ed1a)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agolibxml2: Fix CVE-2017-9049 and CVE-2017-9050
Andrej Valek [Wed, 14 Jun 2017 12:58:47 +0000 (14:58 +0200)]
libxml2: Fix CVE-2017-9049 and CVE-2017-9050

Fix handling of parameter-entity references

There were two bugs where parameter-entity references could lead to an
unexpected change of the input buffer in xmlParseNameComplex and
xmlDictLookup being called with an invalid pointer.

Fixes bug 781205 and bug 781361

CVE: CVE-2017-9049 CVE-2017-9050
(From OE-Core rev: 2300762fef8fc8e3e56fb07fd4076c1deeba0a9b)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agolibxml2: Fix CVE-2017-9047 and CVE-2017-9048
Andrej Valek [Wed, 14 Jun 2017 12:55:03 +0000 (14:55 +0200)]
libxml2: Fix CVE-2017-9047 and CVE-2017-9048

xmlSnprintfElementContent failed to correctly check the available
buffer space in two locations.

Fixes bug 781333 and bug 781701

CVE: CVE-2017-9047 CVE-2017-9048
(From OE-Core rev: bb0af023e811907b4e641b39f654ca921ac8794a)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agolibxml2: Avoid reparsing and simplify control flow in xmlParseStartTag2
Andrej Valek [Wed, 14 Jun 2017 12:38:35 +0000 (14:38 +0200)]
libxml2: Avoid reparsing and simplify control flow in xmlParseStartTag2

(From OE-Core rev: 4651afdd457eca06da07331186bf28b98df2eeff)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agolibxml2: Disable LeakSanitizer when running API tests
Andrej Valek [Wed, 14 Jun 2017 12:34:37 +0000 (14:34 +0200)]
libxml2: Disable LeakSanitizer when running API tests

Makefile.am: Disable LeakSanitizer when running API tests

The autogenerated API tests leak memory.

Upstream-Status: Backported - [https://git.gnome.org/browse/libxml2/commit/?id=ac9a4560ee85b18811ff8ab7791ddfff7b144b0a]
(From OE-Core rev: e3985be0ddb40e8db44422092c875a4e373a6da3)

Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agoclasses/buildhistory: fix failures collecting output signatures
Paul Eggleton [Tue, 9 May 2017 00:38:39 +0000 (12:38 +1200)]
classes/buildhistory: fix failures collecting output signatures

It's possible for tasks to stage symlinks that point to non-existent
files; an example is ncurses-native.do_populate_sysroot. There wasn't
any error checking here so this broke the build when "task" was included
in BUILDHISTORY_FEATURES. In any case we shouldn't be following symlinks
and getting the sha256sum of the link target - we need concern ourselves
only with the target path, so check if the file is a link and sha256 the
target path instead if it is. If it's neither a regular file nor a
symlink (perhaps a pipe or a device), just skip it.

(From OE-Core rev: f60520d97f53dafe783f61eb58fe249798a1e1be)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
7 years agotcf-agent: kill with USR2 in systemd stop
Martin Kelly [Thu, 1 Jun 2017 05:43:54 +0000 (14:43 +0900)]
tcf-agent: kill with USR2 in systemd stop

tcf-agent ignores SIGTERM, so upstream uses USR2 instead. This issue was noticed
by Jan Kiszka and Brian Avery around the same time:

https://patchwork.openembedded.org/patch/139546/
https://patchwork.openembedded.org/patch/139560/

However, these patches fixed only the init scripts, not the systemd service
file. This patch fixes the systemd file.

(From OE-Core rev: 4f8ed1b3bf676a58055ebe01184b3594459a4118)

Signed-off-by: Martin Kelly <mkelly@xevo.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agotcf-agent: Fix daemon termination
Jan Kiszka [Sun, 30 Apr 2017 15:28:01 +0000 (17:28 +0200)]
tcf-agent: Fix daemon termination

The upstream init script uses SIGUSR2 to terminate that daemon because
SIGTERM is ignored. As the killproc function does not support specifying
a signal, switch to start-stop-daemon. Drop the retry loop because
SIGUSR2 is lethal for agent.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agolibgcrypt: fix CVE-2017-7526
Ross Burton [Tue, 18 Jul 2017 22:07:09 +0000 (23:07 +0100)]
libgcrypt: fix CVE-2017-7526

Fixes CVE-2017-7526, 'flush+reload side-channel attack on RSA secret keys dubbed
"Sliding right into disaster"'.

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agolibgcrypt: fix CVE-2017-9526
Ross Burton [Tue, 18 Jul 2017 22:07:08 +0000 (23:07 +0100)]
libgcrypt: fix CVE-2017-9526

In libgcrypt before 1.7.7, an attacker who learns the EdDSA session key (from
side-channel observation during the signing process) can easily recover the
long-term secret key. 1.7.7 makes a cipher/ecc-eddsa.c change to store this
session key in secure memory, to ensure that constant-time point operations are
used in the MPI library.

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobuild-appliance-image: Update to pyro head revision
Richard Purdie [Wed, 12 Jul 2017 06:06:06 +0000 (07:06 +0100)]
build-appliance-image: Update to pyro head revision

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobuild-appliance: Set to pyro release branch
Richard Purdie [Wed, 12 Jul 2017 06:05:44 +0000 (07:05 +0100)]
build-appliance: Set to pyro release branch

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobuild-appliance-image: Update to pyro head revision
Richard Purdie [Tue, 11 Jul 2017 23:28:32 +0000 (00:28 +0100)]
build-appliance-image: Update to pyro head revision

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agomkefidsk: fix bash/dash shell quoting problem
Saul Wold [Tue, 11 Jul 2017 15:14:16 +0000 (08:14 -0700)]
mkefidsk: fix bash/dash shell quoting problem

mkefidsk currently writes a startup.nsh with embedded control characters.
This happens because \b etc are control sequences to the shell echo
command when using dash. The resulting startup.nsh causes the bootup
to fail, and the user is dropped into the EFI shell to manually run
startup.nsh.

Patch originally provided by Troy D. Hanson <troy.hanson@jhuapl.edu>

[YOCTO #9665]

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 008d6cb5bb4969f53a228893c502be8c9420ecb0)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agosystemd-boot.bbclass: Add configuration data to secondary EFI partition
California Sullivan [Tue, 27 Jun 2017 00:52:17 +0000 (17:52 -0700)]
systemd-boot.bbclass: Add configuration data to secondary EFI partition

The secondary EFI partition is used when booting in EFI mode, and
without the configuration data we don't get any boot targets.

Partial fix to [YOCTO #11503].

(From OE-Core master rev: 84aa7a00810e135fdad3f77bdb1da7d1f5fb8627)

Signed-off-by: California Sullivan <california.l.sullivan@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agopackage_manager: flush installed_pkgs file before oe-pkgdata-util uses it
Martin Jansa [Mon, 26 Jun 2017 06:52:54 +0000 (08:52 +0200)]
package_manager: flush installed_pkgs file before oe-pkgdata-util uses it

* since this commit:
  commit f5a1013ffa9815f22e13989e2bcb83f966e7ce2c
  Author: Ross Burton <ross.burton@intel.com>
  Date:   Tue Apr 18 16:19:12 2017 +0100

    package_manager: don't race on a file when installing complementary
    packages

  the file isn't closed before oe-pkgdata-util uses it and this
  temporary file might look empty to oe-pkgdata-util, because it
  wasn't flushed yet. Which resulted in almost empty debugfs tarballs
  and no locale packages in regular rootfs.
* without this change:
  124K May 30 07:41 core-image-full-cmdline-raspberrypi3-64-20170530054003-dbg.rootfs.tar.gz
* with this change:
  173M May 30 07:29 core-image-full-cmdline-raspberrypi3-64-20170530052715-dbg.rootfs.tar.gz

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 877d38db08aa7060d16405443cf70539c559fe82)
Signed-off-by: Anders Darander <anders@chargestorm.se>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agou-boot-mkimage: fix nativesdk build
Max Krummenacher [Wed, 17 May 2017 20:11:34 +0000 (22:11 +0200)]
u-boot-mkimage: fix nativesdk build

If building for nativesdk the wrong rss sysroot is used leading the
following error message.

| ERROR: oe_runmake failed
| In file included from tools/imximage.c:13:0:
| include/image.h:1024:27: fatal error: openssl/evp.h: No such file or directory
|  # include  <openssl/evp.h>

Tools needed on the build host (script/basic/fixdep) and code compiled
for the SDK machine are both built with the build host's compiler,
leading to additinal errors.

Adding CROSS_COMPILE="${HOST_PREFIX}" and using the cross-compiler for
the SDK_ARCH fixes the build error.
The resulting binary in the SDK is working.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agoRevert "bitbake.conf: Add sdl-config to HOSTTOOLS if using host SDL"
Richard Purdie [Tue, 27 Jun 2017 12:48:59 +0000 (13:48 +0100)]
Revert "bitbake.conf: Add sdl-config to HOSTTOOLS if using host SDL"

This clearly wasn't tested as the correct variable is ASSUME_PROVIDED.

This reverts commit 91cee064332969207334cd1ee5c31d02610281fc.

7 years agopackage_ipk: Clean up Source entry in ipk packages
Richard Purdie [Fri, 16 Jun 2017 08:42:30 +0000 (09:42 +0100)]
package_ipk: Clean up Source entry in ipk packages

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>
7 years agomkelfimage: Fix broken patch when building native
Saul Wold [Mon, 5 Jun 2017 22:47:56 +0000 (15:47 -0700)]
mkelfimage: Fix broken patch when building native

A change occured about a year ago that broke the native build, fix
that patch

[YOCTO #11590]

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoautomake: Backport perl 5.22 fix
Marek Vasut [Tue, 13 Jun 2017 13:39:14 +0000 (14:39 +0100)]
automake: Backport perl 5.22 fix

Backport 13f00eb4493c "automake: port to Perl 5.22 and later"
from automake upstream to fix build with perl 5.22 .

Signed-off-by: Marek Vasut <marex@denx.de>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobitbake.conf: Add sdl-config to HOSTTOOLS if using host SDL
Jonathan Liu [Thu, 1 Jun 2017 12:15:52 +0000 (22:15 +1000)]
bitbake.conf: Add sdl-config to HOSTTOOLS if using host SDL

If ASSUME_PROVIDES contains libsdl-native, we need to add sdl-config
to HOSTTOOLS to allow access to the host sdl-config.

Signed-off-by: Jonathan Liu <net147@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agopiglit: add patches for unbuildable surfaceless Mesa test
Daniel Díaz [Wed, 7 Jun 2017 14:51:21 +0000 (09:51 -0500)]
piglit: add patches for unbuildable surfaceless Mesa test

[Backported from master.]

Some EGL implementations do not actually ship all Khronos-
extensions. As it turns out, the Mali 450 driver does not
include any of the following symbols, used by the
egl_mesa_platform_surfaceless.c spec test:
* eglGetPlatformDisplay
* eglCreatePlatformPixmapSurface
* eglCreatePlatformWindowSurface

The Right Thing To Do was to obtain the implementation of
these functions (via eglGetProcAddress), as is provided
by their EXT counterparts. These are guaranteed to exist
since they are required by EGL_EXT_platform_base.

Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agopiglit: add patch for lack of gbm_bo_map
Daniel Díaz [Wed, 7 Jun 2017 14:51:20 +0000 (09:51 -0500)]
piglit: add patch for lack of gbm_bo_map

[Backported from master.]

[Piglit Bug #100978] -- https://bugs.freedesktop.org/show_bug.cgi?id=100978

When linking against Mali 450 r6, errors like the following
can be seen:
  ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_unmap'
  ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_map'
  collect2: error: ld returned 1 exit status
  make[2]: *** [bin/point-sprite] Error 1

This is due to gbm_bo_map() and gbm_bo_unmap() being recently
added but not yet implemented by all graphics drivers.

Instead of relying on GBM's version, actually try to link
against those symbols.

Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agopiglit: depend on virtual/egl
Daniel Díaz [Wed, 7 Jun 2017 14:51:19 +0000 (09:51 -0500)]
piglit: depend on virtual/egl

[Backported from master.]

While building for Hikey using Mali 450 driver (r6p0), an
error like the following appears while linking:

  [  1%] Linking C shared library ../../../../lib/libpiglitutil.so
  [...]
  [...]/aarch64-linaro-linux/gcc/aarch64-linaro-linux/6.3.1/ld: cannot find -lEGL
  collect2: error: ld returned 1 exit status
  make[2]: *** [lib/libpiglitutil.so.0] Error 1

Mesa generally provides virtual/egl (along with virtual/libgl,
which satisfies Piglit's current DEPENDS) but that is not the
implementation to use with Mali.

Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoimage-vm: Avoid use of fold, tac and paste commands for DISK_SIGNATURE
Jonathan Liu [Thu, 8 Jun 2017 11:07:54 +0000 (21:07 +1000)]
image-vm: Avoid use of fold, tac and paste commands for DISK_SIGNATURE

These commands are not whitelisted by the HOSTTOOLS variable which
silently prevents the MBR disk signature from being written to the
image.

Reported-by: Michael Davis <michael.davis@essvote.com>
Signed-off-by: Jonathan Liu <net147@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agokernel: predefine KBUILD_BUILD_USER and KBUILD_BUILD_HOST
Joshua Lock [Fri, 19 May 2017 15:53:06 +0000 (16:53 +0100)]
kernel: predefine KBUILD_BUILD_USER and KBUILD_BUILD_HOST

By exporting KBUILD_BUILD_USER with a pre-defined value we improve the
reproducibility of the kernel and remove the requirement for whoami in the
HOSTTOOLS.
KBUILD_BUILD_HOST also helps improve the reproducibility of the kernel.

For more kernel reproducibility options see:
https://lwn.net/Articles/437864/

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agobinutils: fix CVE-2017-7210
Yuanjie Huang [Fri, 26 May 2017 02:40:41 +0000 (19:40 -0700)]
binutils: fix CVE-2017-7210

CVE: CVE-2017-7210

[BZ 21157] -- https://sourceware.org/bugzilla/show_bug.cgi?id=21157

PR binutils/21157: Fix handling of corrupt STABS enum type strings.

(From OE-Core rev: d12a99cba6c9dc9e1f6bc3a7ca8057f07e9cb950)

Signed-off-by: Yuanjie Huang <yuanjie.huang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobinutils: fix CVE-2017-7209 in readelf
Yuanjie Huang [Fri, 26 May 2017 02:40:40 +0000 (19:40 -0700)]
binutils: fix CVE-2017-7209 in readelf

CVE: CVE-2017-7209

[BZ 21135] -- https://sourceware.org/bugzilla/show_bug.cgi?id=21135

PR binutils/21135: Fix invalid read of section contents whilst processing
a corrupt binary.

(From OE-Core rev: 2df642ca0a1e4a4e6616729018cf32d2108cabb2)

Signed-off-by: Yuanjie Huang <yuanjie.huang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agolibxslt: Fix CVE-2017-5029
Fan Xin [Fri, 26 May 2017 02:39:06 +0000 (11:39 +0900)]
libxslt: Fix CVE-2017-5029

Backport upstream patch to fix CVE-2017-5029.

(From OE-Core rev: 5266e74c990df1cf965d162d9695eb5a698883ae)

Signed-off-by: Fan Xin <fan.xin@jp.fujitsu.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoghostscript: CVE-2016-7977, CVE-2016-7978, CVE-2016-7979, CVE-2017-9216
Catalin Enache [Mon, 29 May 2017 11:23:08 +0000 (14:23 +0300)]
ghostscript: CVE-2016-7977, CVE-2016-7978, CVE-2016-7979, CVE-2017-9216

Ghostscript before 9.21 might allow remote attackers to bypass the SAFER
mode protection mechanism and consequently read arbitrary files via the
use of the .libfile operator in a crafted postscript document.

Use-after-free vulnerability in Ghostscript 9.20 might allow remote
attackers to execute arbitrary code via vectors related to a reference
leak in .setdevice.

Ghostscript before 9.21 might allow remote attackers to bypass the SAFER
mode protection mechanism and consequently execute arbitrary code by
leveraging type confusion in .initialize_dsc_parser.

libjbig2dec.a in Artifex jbig2dec 0.13, as used in MuPDF and Ghostscript,
has a NULL pointer dereference in the jbig2_huffman_get function in
jbig2_huffman.c. For example, the jbig2dec utility will
crash (segmentation fault) when parsing an invalid file.

References:
https://nvd.nist.gov/vuln/detail/CVE-2016-7977
https://nvd.nist.gov/vuln/detail/CVE-2016-7978
https://nvd.nist.gov/vuln/detail/CVE-2016-7979
https://nvd.nist.gov/vuln/detail/CVE-2017-9216

Upstream patches:
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=8abd22010eb4db0fb1b10e430d5f5d83e015ef70
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=6f749c0c44e7b9e09737b9f29edf29925a34f0cf
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=875a0095f37626a721c7ff57d606a0f95af03913
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=3ebffb1d96ba0cacec23016eccb4047dab365853

(From OE-Core rev: 584dfa2f780d5785aaff01f84fbabc18b3478d76)

Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoghostscript: CVE-2016-8602, CVE-2017-7975
Catalin Enache [Mon, 8 May 2017 13:42:59 +0000 (16:42 +0300)]
ghostscript: CVE-2016-8602, CVE-2017-7975

The .sethalftone5 function in psi/zht2.c in Ghostscript before 9.21 allows remote
attackers to cause a denial of service (application crash) or possibly execute
arbitrary code via a crafted Postscript document that calls .sethalftone5 with an
empty operand stack.

Artifex jbig2dec 0.13, as used in Ghostscript, allows out-of-bounds writes because
of an integer overflow in the jbig2_build_huffman_table function in jbig2_huffman.c
during operations on a crafted JBIG2 file, leading to a denial of service (application
crash) or possibly execution of arbitrary code.

References:
https://nvd.nist.gov/vuln/detail/CVE-2016-8602
https://nvd.nist.gov/vuln/detail/CVE-2017-7975

Upstream patches:
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=f5c7555c303
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=5e57e483298

(From OE-Core rev: 8f919c2df47ca93132f21160d919b6ee2207d9a6)

Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobinutils: fix CVE-2017-6969 in readelf
Yuanjie Huang [Wed, 24 May 2017 09:55:17 +0000 (02:55 -0700)]
binutils: fix CVE-2017-6969 in readelf

CVE: CVE-2017-6969
[BZ 21156] -- https://sourceware.org/bugzilla/show_bug.cgi?id=21156

PR binutils/21156: Fix illegal memory accesses in readelf when
ing a corrupt binary.
PR binutils/21156: Fix another memory access error in readelf when
parsing a corrupt binary.

(From OE-Core rev: de04c9811f7ce5179ba261bd8eae921d7873d6cd)

Signed-off-by: Yuanjie Huang <yuanjie.huang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agorpcbind: Fix CVE-2017-8779
Fan Xin [Wed, 24 May 2017 08:10:52 +0000 (17:10 +0900)]
rpcbind: Fix CVE-2017-8779

This vulnerability is also called "rpcbomb".
Backport upstream patch to fix this vulnerability.

CVE: CVE-2017-8779

(From OE-Core rev: 7936c9451eb4c376a78a0ac7461d1b2430c7f1f3)

Signed-off-by: Fan Xin<fan.xin@jp.fujitsu.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobinutils: Fix CVE-2017-8392
Fan Xin [Wed, 24 May 2017 05:43:11 +0000 (14:43 +0900)]
binutils: Fix CVE-2017-8392

Backport upsream commit to fix CVE-2017-8392

CVE: CVE-2017-8392

[BZ 21409] -- https://sourceware.org/bugzilla/show_bug.cgi?id=21409

        PR 21409, segfault in _bfd_dwarf2_find_nearest_line

        PR 21409
        * dwarf2.c (_bfd_dwarf2_find_nearest_line): Don't segfault when
        no symbols.

(From OE-Core rev: dff01b827c87ae135a1d5511b1efbdad01c0eaee)

Signed-off-by: Fan Xin <fan.xin@jp.fujitsu.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agocve-check.bbclass: make warning contain CVE IDs
Chen Qi [Tue, 9 May 2017 09:31:36 +0000 (17:31 +0800)]
cve-check.bbclass: make warning contain CVE IDs

When warning users about unpatched CVE, we'd better put CVE IDs into
the warning message, so that it would be more straight forward for the
user to know which CVEs are not patched.

So instead of:
  WARNING: gnutls-3.5.9-r0 do_cve_check: Found unpatched CVE, for more information check /path/to/workdir/cve/cve.log.
We should have:
  WARNING: gnutls-3.5.9-r0 do_cve_check: Found unpatched CVE (CVE-2017-7869), for more information check /path/to/workdir/cve/cve.log.

(From OE-Core rev: ad46069e7b58f2fba373131716f28407816fa1a6)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agocve-check-tool: backport a patch to make CVE checking work
Chen Qi [Mon, 8 May 2017 03:12:11 +0000 (11:12 +0800)]
cve-check-tool: backport a patch to make CVE checking work

CVE checking in OE didn't work as do_populate_cve_db failed with the following
error message.

  [snip]/downloads/CVE_CHECK/nvdcve-2.0-2002.xml is not consistent

Backport a patch to fix this error.

(From OE-Core rev: ee55b5685aaa4be92d6d51f8641a559d4e34ce64)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agooeqa/selftest: lock down Meson git revision for reliability
Ross Burton [Mon, 5 Jun 2017 16:30:42 +0000 (17:30 +0100)]
oeqa/selftest: lock down Meson git revision for reliability

The test_recipetool_create_github test fetches HEAD of the repository so
upstream changes can (and do) break the test.  Avoid these problems by passing
the rev= argument in the URL to lock the checkout to the same version that is
fetched in the github_tarball test.

Also pass the commands to runCmd() as a list instead of a string, the semicolon
in the URL needs more quotes if the shell is involved and passing a list
bypasses the shell entirely.

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoscriptutils: fix fetch_uri() to work with RSS
Paul Eggleton [Mon, 29 May 2017 02:01:56 +0000 (14:01 +1200)]
scriptutils: fix fetch_uri() to work with RSS

Since recipe-specific sysroots were implemented, devtool add and devtool
upgrade operations that fetch from a URL that requires native sysroot
dependencies will fail to work as there is no recipe-specific sysroot
set up for them during fetching. An example was any URL pointing to a
tarball compressed with xz, e.g. devtool upgrade on gnutls.

The most expedient way to fix this is to set up a dummy recipe-specific
sysroot to use for the fetch/unpack operations. We do this in the same
manner as bitbake -b does, so we're just taking all of the sysroot
components available and creating a sysroot from those rather than
ensuring the correct dependencies are there - this means that we're
still going to have problems if e.g. xz-native hasn't been built yet,
but that issue will be trickier to solve and is tracked separately.

Fixes [YOCTO #11474].

(From OE-Core master rev: 559151e783759af78b5cdd76cdbb9ce325a391e6)

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>
7 years agocryptodev-linux: update SRC_URI
Chang Rebecca Swee Fun [Fri, 26 May 2017 07:07:01 +0000 (15:07 +0800)]
cryptodev-linux: update SRC_URI

Gna! project announced that the download site from gna.org HTTP server
will soon be closing down. We have verified that the site is no longer
accessible without network proxy cache. We need to update SRC_URI to
point to new alternative (nwl.cc HTTP server) in order to avoid fetcher
issues in future.

[YOCTO #11575]

Signed-off-by: Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobash: CVE-2016-0634
Zhixiong Chi [Thu, 20 Apr 2017 07:04:54 +0000 (15:04 +0800)]
bash: CVE-2016-0634

A vulnerability was found in a way bash expands the $HOSTNAME.
Injecting the hostname with malicious code would cause it to run
each time bash expanded \h in the prompt string.

Porting patch from <https://ftp.gnu.org/gnu/bash/bash-4.3-patches/
bash43-047> to solve CVE-2016-0634

CVE: CVE-2016-0634

(From OE-Core rev: 7dd6aa1a4bf6e9fc8a1998cda6ac5397bb5cd5cb)

Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agostaging: Allow BB_LIMITEDDEPS to avoid BB_TASKDEPDATA
Richard Purdie [Mon, 8 May 2017 10:56:22 +0000 (11:56 +0100)]
staging: Allow BB_LIMITEDDEPS to avoid BB_TASKDEPDATA

In the limited dependency case we don't use any of the data from
BB_TASKDEPDATA. Restructure the code so this variable doesn't have
to be set. This allows the function to be called from other contexts
without creating artificial constructs. There should be no functional
change, behaviour remains unchanged.

(From OE-Core rev: 71e5243e3ebadb90b45fe418dac3eaa2c1b896bd)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agosstate: Ensure native/cross recipes have relocation of HOSTTOOLS_DIR
Richard Purdie [Thu, 4 May 2017 10:59:14 +0000 (11:59 +0100)]
sstate: Ensure native/cross recipes have relocation of HOSTTOOLS_DIR

The previous change to relocate HOSTTOOLS wasn't complete as some files,
particularly in gcc stashed build directories were not being correctly
relocated. This patch addresses the issue.

(From OE-Core rev: 21dd36cc12a033b012544c5d15a6f8afd84dabc9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agopython.inc: Fix python2/3 hosttools path references
Richard Purdie [Thu, 4 May 2017 10:58:05 +0000 (11:58 +0100)]
python.inc: Fix python2/3 hosttools path references

Both native and target versions of this file reference mkdir and install
in hosttools paths. Use the version from PATH instead.

(From OE-Core rev: 080197bf3bdf612da8104c2ae7f0b2c8dea32a0b)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agorpm: Ensure macros file doesn't reference HOSTTOOLS
Richard Purdie [Thu, 4 May 2017 10:56:25 +0000 (11:56 +0100)]
rpm: Ensure macros file doesn't reference HOSTTOOLS

Currently the file encodes full paths to various host tools in the
HOSTTOOLS directory which is bad in native and target cases. We can
simply use the versions from PATH quite safely in OE.

(From OE-Core rev: be901200d94beaa35e1d05eb502b117b3b523609)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
7 years agoGNU_MIRROR: switch from ftp to https
Maxin B. John [Tue, 9 May 2017 16:19:22 +0000 (19:19 +0300)]
GNU_MIRROR: switch from ftp to https

Based on the same reason behind DEBIAN's switch from ftp:
https://www.debian.org/News/2017/20170425

Signed-off-by: Maxin B. John <maxin.john@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agoDEBIAN_MIRROR: switch from ftp to http
Maxin B. John [Tue, 9 May 2017 16:19:21 +0000 (19:19 +0300)]
DEBIAN_MIRROR: switch from ftp to http

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]

Signed-off-by: Maxin B. John <maxin.john@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agouseradd: remove preinst script referring to recipe sysroot
Maxin B. John [Tue, 9 May 2017 16:19:20 +0000 (19:19 +0300)]
useradd: remove preinst script referring to recipe sysroot

Remove recipe-specific-sysroot details from the preinst scripts
generated by useradd.bbclass.

This was added to match the default from bitbake.conf. Unlike the default
case, the dependencies used by useradd mean that a default passwd/group
file is always present. This means we don't need the native sysroot fallback.

Fixes [YOCTO #11460]

Signed-off-by: Maxin B. John <maxin.john@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agouseradd.bbclass: Handle COMPONENTS_DIR when restoring state
Peter Kjellerstedt [Wed, 3 May 2017 21:13:39 +0000 (23:13 +0200)]
useradd.bbclass: Handle COMPONENTS_DIR when restoring state

The export of PSEUDO in useradd_sysroot() contains references to
${COMPONENTS_DIR}. These need to be handled when restoring
postinst-useradd-${PN} from the sstate cache.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7 years agobitbake.conf: Add COMPONENTS_DIR for ${STAGING_DIR}-components
Peter Kjellerstedt [Wed, 3 May 2017 21:13:38 +0000 (23:13 +0200)]
bitbake.conf: Add COMPONENTS_DIR for ${STAGING_DIR}-components

The path to where to install and find the sysroot components is used
in many places. This warrants it to get its own variable.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobuild-appliance-image: Update to master head revision 2017-04 2017-04-pyro yocto-2.3
Richard Purdie [Mon, 1 May 2017 07:56:43 +0000 (08:56 +0100)]
build-appliance-image: Update to master head revision

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agosstate.bbclass, staging.bbclass: Handle HOSTTOOLS_DIR when restoring state
Peter Kjellerstedt [Fri, 28 Apr 2017 15:01:02 +0000 (17:01 +0200)]
sstate.bbclass, staging.bbclass: Handle HOSTTOOLS_DIR when restoring state

Paths to host tools that have been copied to ${HOSTTOOLS_DIR} may end
up in the sstate cache. They thus need to be corrected when restoring
from the sstate cache.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobitbake.conf: Add HOSTTOOLS_DIR for ${TMPDIR}/hosttools
Peter Kjellerstedt [Fri, 28 Apr 2017 15:01:01 +0000 (17:01 +0200)]
bitbake.conf: Add HOSTTOOLS_DIR for ${TMPDIR}/hosttools

The path to where to install and find the tools copied from the host
environment is already used in a couple of places. This warrants it to
get its own variable.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobuild-appliance-image: Update to master head revision
Richard Purdie [Sat, 29 Apr 2017 10:17:55 +0000 (11:17 +0100)]
build-appliance-image: Update to master head revision

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobuild-appliance-image: Update to master head revision
Richard Purdie [Sat, 29 Apr 2017 10:17:31 +0000 (11:17 +0100)]
build-appliance-image: Update to master head revision

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agopackage_deb.bbclass: Avoid writing empty custom fields
Andreas Oberritter [Fri, 28 Apr 2017 18:38:22 +0000 (20:38 +0200)]
package_deb.bbclass: Avoid writing empty custom fields

Avoids parser errors if PACKAGE_ADD_METADATA_DEB is set to an
empty value.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agopackage_deb.bbclass: Fix multi-line package descriptions
Andreas Oberritter [Fri, 28 Apr 2017 18:38:21 +0000 (20:38 +0200)]
package_deb.bbclass: Fix multi-line package descriptions

In deb control files, each line of a long description starts with
a single space. Empty lines are represented by a single space
followed by a single full stop character.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobusybox: make bash a valid login shell if enabled
Andreas Oberritter [Fri, 28 Apr 2017 18:31:29 +0000 (20:31 +0200)]
busybox: make bash a valid login shell if enabled

Add bash to /etc/shells if busybox is built with bash applet anabled
to fix login via dropbear.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agogst-player: Disable visualizations as workaround
Jussi Kukkonen [Fri, 28 Apr 2017 11:54:34 +0000 (14:54 +0300)]
gst-player: Disable visualizations as workaround

Audio playback in gtk-play is broken with vaapi because the
visualizations do not work: disable visualizations as workaround.
This should be reverted as soon as [YOCTO #11410] is fixed.

Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agolibxml2: CVE-2016-9318
Catalin Enache [Fri, 14 Apr 2017 08:43:32 +0000 (11:43 +0300)]
libxml2: CVE-2016-9318

libxml2 2.9.4 and earlier, as used in XMLSec 1.2.23 and earlier
and other products, does not offer a flag directly indicating that
the current document may be read but other files may not be opened,
which makes it easier for remote attackers to conduct XML External
Entity (XXE) attacks via a crafted document.

Reference:
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-9318

Upstream patch:
https://git.gnome.org/browse/libxml2/commit/?id=2304078555896cf1638c628f50326aeef6f0e0d0

Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agoghostscript : CVE-2016-10219, CVE-2016-10220, CVE-2017-5951
Catalin Enache [Fri, 21 Apr 2017 12:04:17 +0000 (15:04 +0300)]
ghostscript : CVE-2016-10219, CVE-2016-10220, CVE-2017-5951

The intersect function in base/gxfill.c in Artifex Software, Inc. Ghostscript
9.20 allows remote attackers to cause a denial of service (divide-by-zero
error and application crash) via a crafted file.

The gs_makewordimagedevice function in base/gsdevmem.c in Artifex Software, Inc.
Ghostscript 9.20 allows remote attackers to cause a denial of service (NULL
pointer dereference and application crash) via a crafted file that is
mishandled in the PDF Transparency module.

The mem_get_bits_rectangle function in base/gdevmem.c in Artifex Software, Inc.
Ghostscript 9.20 allows remote attackers to cause a denial of service (NULL
pointer dereference and application crash) via a crafted file.

References:
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10219
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10220
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-5951

Upstream patches:
http://git.ghostscript.com/?p=ghostpdl.git;h=4bef1a1d32e29b68855616020dbff574b9cda08f
http://git.ghostscript.com/?p=ghostpdl.git;h=daf85701dab05f17e924a48a81edc9195b4a04e8
http://git.ghostscript.com/?p=ghostpdl.git;h=bfa6b2ecbe48edc69a7d9d22a12419aed25960b8

Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agobind: Security fix CVE-2016-6170
Yi Zhao [Thu, 13 Apr 2017 05:48:13 +0000 (13:48 +0800)]
bind: Security fix CVE-2016-6170

CVE-2016-6170: ISC BIND through 9.9.9-P1, 9.10.x through 9.10.4-P1, and
9.11.x through 9.11.0b1 allows primary DNS servers to cause a denial of
service (secondary DNS server crash) via a large AXFR response, and
possibly allows IXFR servers to cause a denial of service (IXFR client
crash) via a large IXFR response and allows remote authenticated users
to cause a denial of service (primary DNS server crash) via a large
UPDATE message.

External References:
https://nvd.nist.gov/vuln/detail/CVE-2016-6170

Patch from:
https://source.isc.org/cgi-bin/gitweb.cgi?p=bind9.git;a=commit;h=1bbcfe2fc84f57b1e4e075fb3bc2a1dd0a3a851f

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agobind: Security fix CVE-2016-8864
Yi Zhao [Thu, 13 Apr 2017 05:48:12 +0000 (13:48 +0800)]
bind: Security fix CVE-2016-8864

CVE-2016-8864: named in ISC BIND 9.x before 9.9.9-P4, 9.10.x before
9.10.4-P4, and 9.11.x before 9.11.0-P1 allows remote attackers to cause
a denial of service (assertion failure and daemon exit) via a DNAME
record in the answer section of a response to a recursive query,
related to db.c and resolver.c.

External References:
https://nvd.nist.gov/vuln/detail/CVE-2016-8864

Patch from:
https://source.isc.org/cgi-bin/gitweb.cgi?p=bind9.git;a=commit;h=c1d0599a246f646d1c22018f8fa09459270a44b8

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agolinux-libc-headers: fix upstream version check
Alexander Kanavin [Mon, 24 Apr 2017 13:15:51 +0000 (16:15 +0300)]
linux-libc-headers: fix upstream version check

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agolibproxy: speed up upstream version check
Alexander Kanavin [Mon, 24 Apr 2017 13:15:49 +0000 (16:15 +0300)]
libproxy: speed up upstream version check

Something in the fetched webpage made the default regex matching really slow.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agoboost: fix upstream version check
Alexander Kanavin [Mon, 24 Apr 2017 13:15:48 +0000 (16:15 +0300)]
boost: fix upstream version check

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agopython3-iniparse: fix upstream version check
Alexander Kanavin [Fri, 21 Apr 2017 12:40:01 +0000 (15:40 +0300)]
python3-iniparse: fix upstream version check

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agoacpica: fix upstream version check
Alexander Kanavin [Fri, 21 Apr 2017 12:40:00 +0000 (15:40 +0300)]
acpica: fix upstream version check

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agolsbtest: add option --ignoreos to rpm install command
Dengke Du [Fri, 21 Apr 2017 04:15:53 +0000 (12:15 +0800)]
lsbtest: add option --ignoreos to rpm install command

After change to the rpm4, the rpm packages in lsbtest, such as:

    lsb-setup-4.1.0-1.noarch.rpm
    lsb-dist-checker-5.0.0.1-1.x86_64.rpm
    ......
    lsb-cmdchk-5.0.3-1.x86_64.rpm

When install above rpm packages, the error log appears:

    package lsb-setup-4.1.0-1.noarch is intended for a different operating system
    ......

So we should add option "--ignoreos" to the rpm install command in LSB_Test.sh
in ./meta/recipes-extended/lsb/lsbtest directory. In this way we can make sure
the correct installation of those rpm packages.

The YOCTO bug #11224 didn't create logs, this is because the above test rpm
packages didn't install.

[YOCTO #11224]

Signed-off-by: Dengke Du <dengke.du@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agorpm: properly relocate additional native tools
Alexander Kanavin [Fri, 21 Apr 2017 08:55:32 +0000 (11:55 +0300)]
rpm: properly relocate additional native tools

These tools are not currently used for anything, but we should
still provide working versions of them.

[YOCTO #11400]

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agolibcap: drop obsolete attr PACKAGECONFIG option and libattr dependency
Andre McCurdy [Thu, 20 Apr 2017 23:28:02 +0000 (16:28 -0700)]
libcap: drop obsolete attr PACKAGECONFIG option and libattr dependency

In the 2.25 release, libcap dropped its dependency on an external
libattr library:

  https://git.kernel.org/pub/scm/linux/kernel/git/morgan/libcap.git/commit/?id=85f38a573fc47472ab792e813b6f6b6f0b1df112

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agocmake.bbclass: use weakest ??= assignment for default OECMAKE_SOURCEPATH
Andre McCurdy [Thu, 27 Apr 2017 23:50:29 +0000 (16:50 -0700)]
cmake.bbclass: use weakest ??= assignment for default OECMAKE_SOURCEPATH

Make it slightly easier to support situations where the default path
needs to be over-ridden more than once.

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agocmake.bbclass: Do not use bitbake variable syntax for shell variables
Peter Kjellerstedt [Wed, 19 Apr 2017 16:57:09 +0000 (18:57 +0200)]
cmake.bbclass: Do not use bitbake variable syntax for shell variables

Using bitbake variable syntax (i.e., ${FOO}) for shell variables is
bad practice. First of all it is confusing, but more importantly it
can lead to weird problems if someone actually defines a bitbake
variable with the same name as the shell variable.

Also use lower case for local shell variables.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agorunqemu: support virtio drive type
Patrick Ohly [Thu, 13 Apr 2017 20:32:51 +0000 (22:32 +0200)]
runqemu: support virtio drive type

Setting QB_DRIVE_TYPE=/dev/vd selects virtio without triggering any
warnings. Previously, that was only possible by setting an unknown
value and relying on the fallback to virtio, which caused some
warnings to be printed.

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agobitbake.conf: Add python2 to HOSTTOOLS
Diego Rondini [Thu, 27 Apr 2017 13:28:40 +0000 (13:28 +0000)]
bitbake.conf: Add python2 to HOSTTOOLS

Add python2 to HOSTTOOLS as, according to
https://www.python.org/dev/peps/pep-0394/, the command "python2" should be the
one used in scripts that are not yet ported to Python 3.

Signed-off-by: Diego Rondini <diego.rondini@kynetics.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agobitbake.conf: Add pr to list of hosttools
Khem Raj [Thu, 20 Apr 2017 18:20:26 +0000 (11:20 -0700)]
bitbake.conf: Add pr to list of hosttools

pr is used by gstreamer1.0-libav during configure

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agodevtool: Avoid touch sstates when cleaning linux-yocto environment
Jose Perez Carranza [Wed, 26 Apr 2017 05:54:00 +0000 (05:54 +0000)]
devtool: Avoid touch sstates when cleaning linux-yocto environment

sstates are cleaned when ruining  test_devtool_virtual_kernel_modify to
have a clean environment but this is affecting eSDK test that are
dependent of those sstates, hence “cleansstate” is replaced for
“clean”.

[YOCTO #11300]

Signed-off-by: Jose Perez Carranza <jose.perez.carranza@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agowic: Fix typo in help screen.
Kristian Amlie [Wed, 26 Apr 2017 13:00:16 +0000 (15:00 +0200)]
wic: Fix typo in help screen.

This was overlooked when f6a064d969f4149b was merged.

Signed-off-by: Kristian Amlie <kristian.amlie@mender.io>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agogstreamer1.0-vaapi: Fix playback breaking bug
Jussi Kukkonen [Wed, 26 Apr 2017 07:01:42 +0000 (10:01 +0300)]
gstreamer1.0-vaapi: Fix playback breaking bug

gstreamer-vaapi fails to play files with specific frame sizes
because of buffer allocation issues. Fix is a backport.

Fixes [YOCTO #11311].

Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agoselftest/bbtests: improve download rename test
Ross Burton [Sun, 23 Apr 2017 20:29:39 +0000 (21:29 +0100)]
selftest/bbtests: improve download rename test

This test was assuming the format of SRC_URI so broke when SRC_URI was changed.
Fix the test by hardcoding a complete SRC_URI instead of appending and hoping
for the best.

Signed-off-by: Ross Burton <ross.burton@intel.com>
8 years agokernel-yocto/kern-tools: fix do_validate_branches clean stage
Bruce Ashfield [Sat, 22 Apr 2017 04:36:00 +0000 (00:36 -0400)]
kernel-yocto/kern-tools: fix do_validate_branches clean stage

It was reported that do_validate_branches was failing with the following
error:

  Log data follows:
  | DEBUG: Executing shell function do_validate_branches
  | HEAD is now at fe0fb8d Merge tag 'v4.10.9' into standard/base
  | mkdir: cannot create directory .: File exists
  |
  | [ERROR] Can't find patch dir at ./patches/standard/base
  | usage: kgit s2q
  | WARNING: exit code 1 from a shell command.
  | ERROR: Function failed: do_validate_branches

This was triggered by the execution of 'kgit-s2q --clean' after forcing
the SRCREV to something other than the tip of the branch. --clean is
being run to remove any sentinel files from previous kernel builds to
ensure that the tree is in a consistent state.

There were two bugs, --clean was being executed and not exiting the
script as it was supposed to. Hence validation for applying patches
was done, and threw the error that eventually makes it to the console.

And the second bug is that since do_validate_branches actually calls
kgit-s2q --clean, the dependency on kern-tools-native needs to be on
that function (versus do_kernel_metadata which runs later).

With the tweaked kern-tool + the dependency fix, we no longer see this
error.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agooe-find-native-sysroot: don't clear OECORE_NATIVE_SYSROOT
Robert Yang [Tue, 25 Apr 2017 03:35:42 +0000 (20:35 -0700)]
oe-find-native-sysroot: don't clear OECORE_NATIVE_SYSROOT

The OECORE_NATIVE_SYSROOT may come from environment vars, so don't clear
it, otherwise it broke runqemu-extract-sdk on sdk.

[YOCTO #11409]

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agorunqemu-gen-tapdevs: fix runqemu-ifup script call
Martin Jansa [Thu, 27 Apr 2017 20:53:35 +0000 (22:53 +0200)]
runqemu-gen-tapdevs: fix runqemu-ifup script call

The tunctl binary is here:

OE @ /OE/openembedded-core # find /OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/sysroot-providers
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/sysroot-providers/qemu-helper-native
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr/bin
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr/bin/tunctl

But the script still complains that it cannot find tunctl:

OE @ /OE/openembedded-core # ./scripts/runqemu-gen-tapdevs 1026 1026 4 /OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/
Note: Destroying pre-existing tap interface tap0...
TUNSETIFF: Device or resource busy
Creating 4 tap devices for UID: 1026 GID: 1026...
Creating tap0
Error running tunctl: Error: Unable to find tunctl binary in '/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/', please bitbake qemu-helper-native

The message is actually from runqemu-ifup, which is called from runqemu-gen-tapdevs as:
++ ./scripts/runqemu-ifup 1026 1026 /OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/

But runqemu-ifup expects 3rd parameter to be STAGING_BINDIR_NATIVE directly not just SYSROOT dir
STAGING_BINDIR_NATIVE=$3
because tunctl is then used as:
TUNCTL=$STAGING_BINDIR_NATIVE/tunctl

It looks like it got broken by:
commit cc5513bf7a6114e14bb307acb88a44e9cf0aed8a
Author: Ed Bartosh <ed.bartosh@linux.intel.com>
Date:   Wed Apr 12 23:40:59 2017 +0300

    runqemu: use bindir_native property to run ifup/down scripts

    Used self.bindir_native to point out to the native sysroot
    when running runqemu-ifup and runqemu-ifdown scripts.

    [YOCTO #11266]
    [YOCTO #11193]

Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Seemingly obvious fix would be to call runqemu-gen-tapdevs with path to STAGING_BINDIR_NATIVE in 4th parameter as well, but that won't work, because runqemu-gen-tapdevs checks for TUNCTL=$SYSROOT/usr/bin/tunctl

OE @ /OE/openembedded-core # ./scripts/runqemu-gen-tapdevs 1026 1026 4 /OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr/bin/
Error: /OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr/bin//usr/bin/tunctl is not an executable

I've tested that with this change it can call tunctl:
OE @ /OE/openembedded-core # ./scripts/runqemu-gen-tapdevs 1026 1026 4
/OE/build/oe-core/tmp-glibc/sysroots-components/x86_64/qemu-helper-native/usr/bin
Note: Destroying pre-existing tap interface tap0...
TUNSETIFF: Device or resource busy
Creating 4 tap devices for UID: 1026 GID: 1026...
Creating tap0
Creating tap1
Creating tap2
Creating tap3
Note: For systems running NetworkManager, it's recommended
Note: that the tap devices be set as unmanaged in the
Note: NetworkManager.conf file. Add the following lines to
Note: /etc/NetworkManager/NetworkManager.conf
[keyfile]
unmanaged-devices=interface-name:tap*

but runqemu itself still doesn't work for me:
OE qemux86@ ~/build/oe-core $ runqemu
runqemu - INFO - Running MACHINE=qemux86 bitbake -e...
runqemu - INFO - Running ls -t /OE/build/oe-core/tmp-glibc/deploy/images/qemux86/*.qemuboot.conf...
runqemu - INFO - CONFFILE: /OE/build/oe-core/tmp-glibc/deploy/images/qemux86/core-image-sato-qemux86-20170427174052.qemuboot.conf
runqemu - INFO - Overriding conf file setting of STAGING_DIR_NATIVE to /OE/build/oe-core/tmp-glibc/work/i586-oe-linux/defaultpkgname/1.0-r0/recipe-sysroot-native from Bitbake environment
runqemu - INFO - Continuing with the following parameters:

KERNEL: [tmp-glibc/deploy/images/qemux86/bzImage--4.10.9+git0+ad2e885015_fe0fb8da3d-r0.2-qemux86-20170427085800.bin]
MACHINE: [qemux86]
FSTYPE: [ext4]
ROOTFS: [tmp-glibc/deploy/images/qemux86/core-image-sato-qemux86-20170427174052.rootfs.ext4]
CONFFILE: [/OE/build/oe-core/tmp-glibc/deploy/images/qemux86/core-image-sato-qemux86-20170427174052.qemuboot.conf]

runqemu - INFO - Running /bin/ip link...
runqemu - INFO - Acquiring lockfile /tmp/qemu-tap-locks/tap0.lock...
runqemu - INFO - Using preconfigured tap device tap0
runqemu - INFO - If this is not intended, touch /tmp/qemu-tap-locks/tap0.skip to make runqemu skip tap0.
runqemu - INFO - Network configuration: 192.168.7.2::192.168.7.1:255.255.255.0
runqemu - INFO - Running ldd tmp-glibc/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin//qemu-system-i386...
runqemu - INFO - Running tmp-glibc/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin//qemu-system-i386 -device virtio-net-pci,netdev=net0,mac=52:54:00:12:34:02 -netdev tap,id=net0,ifname=tap0,script=no,downscript=no -drive file=tmp-glibc/deploy/images/qemux86/core-image-sato-qemux86-20170427174052.rootfs.ext4,if=virtio,format=raw -vga vmware -show-cursor -usb -usbdevice tablet -device virtio-rng-pci   -cpu qemu32 -m 256 -serial mon:vc -serial null -kernel tmp-glibc/deploy/images/qemux86/bzImage--4.10.9+git0+ad2e885015_fe0fb8da3d-r0.2-qemux86-20170427085800.bin -append 'root=/dev/vda rw highres=off  mem=256M ip=192.168.7.2::192.168.7.1:255.255.255.0 vga=0 uvesafb.mode_option=640x480-32 oprofile.timer=1 uvesafb.task_timeout=-1 '
qemu-system-i386: -netdev tap,id=net0,ifname=tap0,script=no,downscript=no: could not configure /dev/net/tun (tap0): Device or resource busy
runqemu - INFO - Releasing lockfile for tap device 'tap0'
Traceback (most recent call last):
  File "/OE/build/oe-core/openembedded-core/scripts/runqemu", line 1235, in <module>
    ret = main()
  File "/OE/build/oe-core/openembedded-core/scripts/runqemu", line 1228, in main
    config.start_qemu()
  File "/OE/build/oe-core/openembedded-core/scripts/runqemu", line 1139, in start_qemu
    raise Exception('Failed to run %s' % cmd)
Exception: Failed to run tmp-glibc/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin//qemu-system-i386 -device virtio-net-pci,netdev=net0,mac=52:54:00:12:34:02 -netdev tap,id=net0,ifname=tap0,script=no,downscript=no -drive file=tmp-glibc/deploy/images/qemux86/core-image-sato-qemux86-20170427174052.rootfs.ext4,if=virtio,format=raw -vga vmware -show-cursor -usb -usbdevice tablet -device virtio-rng-pci   -cpu qemu32 -m 256 -serial mon:vc -serial null -kernel tmp-glibc/deploy/images/qemux86/bzImage--4.10.9+git0+ad2e885015_fe0fb8da3d-r0.2-qemux86-20170427085800.bin -append 'root=/dev/vda rw highres=off  mem=256M ip=192.168.7.2::192.168.7.1:255.255.255.0 vga=0 uvesafb.mode_option=640x480-32 oprofile.timer=1 uvesafb.task_timeout=-1 '

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
8 years agouseradd-statids.bbclass: Add support for -P / --clear-password option
Mark Hatle [Thu, 27 Apr 2017 19:41:04 +0000 (14:41 -0500)]
useradd-statids.bbclass: Add support for -P / --clear-password option

The commit 31dee7946340bf0f1e94e4e714191d3d6ca3bf6a added a new useradd and
groupadd option to specify a clear text password.  The parsing logic in the
useradd-staticid class did not understand this new option.  If the
meta-skeleton examples were run with the class enabled an error would be
generated, as an example uses the -P option.

Note, the code has a check that we do not attempt to set both a crypt and
clear text password.  It is not allowed that these two options are set
at the same time, so we prefer the crypt option if they happen to be.

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>