Commit Graph

52345 Commits

Author SHA1 Message Date
Richard Purdie
dbe49d0ad1 scripts: Remove deprecated imp module usage
The imp module is deprecated, port the code over to use importlib
as recently done for bb.utils as well.

(From OE-Core rev: 24809582d4850190d87cd8eb8180d0dce215dbdf)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Chen Qi
f48d111e42 busybox: skip known bugs in ptest
Set SKIP_KNOWN_BUGS in run-ptest script to skip ptest cases which
are known to relate to some known bugs.

(From OE-Core rev: b7ab8de1e5767593d1933cf1a86b91ec2fb9d607)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Randy MacLeod
e442370f2a valgrind: update upstream patch status
Two recent patches are now marked as reported in the
valgrind bugzilla.

(From OE-Core rev: 0f8608dbdf150470f1b4e882515fe9f78f82b43a)

Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Ming Liu
20eb0733e5 wic: bootimg-efi: add a title source parameter
Sometimes the users might want to change the title showing on UEFI
booting screen, so far it's hard-coded to 'boot'.

There is not a easy way to customize it in current design, I tried
firstly with '--configfile', but that does not work with --use-uuid,
since the later option will generate a UUID and write it to boot
config, only when the former option is not enabled.

So a new source parameter 'titile' is added in this patch, it defaults
to 'boot' to be consistent with the original title.

(From OE-Core rev: 37e16188ef3b1b328eb18b3e459c051c9c9f0332)

Signed-off-by: Ming Liu <liu.ming50@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Ming Liu
e5a43f6386 image.bbclass: add a missing blank
When calling d.appendVarFlag, a blank is needed or else it could mess
up the later appended variables.

Reported-by: Stefan Agner <stefan.agner@toradex.com>
(From OE-Core rev: 8b2df6e5874b932b356847c5bde10d5b31d67213)

Signed-off-by: Ming Liu <liu.ming50@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Richard Purdie
e2af21d119 lib/oe/package_manager: Avoid race problems when calling list_pkgs()
list_pkgs() for rpm calls RpmPM() which would try and create a copy of the
package feed. This can be called for example from buildhistory whilst some
other task may be working on an SDK or image construction, causing the package
feed to disappear part way through an operation.

Avoid the need to copy the package index just to list the installed
packages, avoiding the race.

(From OE-Core rev: d05fa49e06034913e22c223803c98cb265e2ae58)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Richard Purdie
f1d0b6d296 oeqa/utils/qemurunner.py: Fix python regex warnings
Fix the warnings:

meta/lib/oeqa/utils/qemurunner.py:250: DeprecationWarning: invalid escape sequence \.
  ips = re.findall("((?:[0-9]{1,3}\.){3}[0-9]{1,3})", cmdline.split("ip=")[1])
meta/lib/oeqa/utils/qemurunner.py:343: DeprecationWarning: invalid escape sequence \-
  if re.search("root@[a-zA-Z0-9\-]+:~#", output):
poky/meta/lib/oeqa/utils/qemurunner.py:350: DeprecationWarning: invalid escape sequence \-
  if re.search("root@[a-zA-Z0-9\-]+:~#", output):
meta/lib/oeqa/utils/qemurunner.py:448: DeprecationWarning: invalid escape sequence \-
  if re.search("[a-zA-Z0-9]+@[a-zA-Z0-9\-]+:~#", data):

by correctly marking the regexs.

(From OE-Core rev: 8e6987735002560fca714f77ea8ece9d4b28f7fa)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Richard Purdie
3e9505274b oeqa/selftest/context: Replace deprecated imp module usage
Avoid the warning:

meta/lib/oeqa/selftest/context.py:8: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
  import imp

In this case importlib is a direct replacement.

(From OE-Core rev: db7a60c36a2d3eefc61ae6e1ede01680dc932035)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Changqing Li
f027576193 oepydevshell-internal.py: decode only when readdata is valid
fix below problem:
pydevshell raises exception when maximize the python shell window.
when click maximize, rlist of select return ready object, but the
pty.read is None, so throw exception of 'NoneType' object has no
attribute 'decode', change to only decode when readdata is valid.

[YOCTO #11875]

(From OE-Core rev: d598f8d48e9b094af99effa7471d613b16ffa817)

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Wes Lindauer
10270f4222 module.bbclass: Add INSTALL_FW_PATH for out-of-tree modules
This same variable was added to the make line in kernel.bbclass in
0decf1cc1c. With the addition of the
usrmerge feature, out-of-tree modules could use this same variable.

(From OE-Core rev: 1d24d1ac5b9c772d84104396438e5d1308332785)

Signed-off-by: Wes Lindauer <wesley.lindauer@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Wes Lindauer
2ce3efc6a6 busybox: Provide /bin/ash when usrmerge is enabled
When usrmerge is enabled, scripts that were explicitly using #!/bin/ash
will cause a QA Error like the following:

QA Issue: bar.sh contained in package foo requires /bin/ash,
but no providers found in RDEPENDS_foo? [file-rdeps].

It seems perfectly acceptable for scripts to use /bin/ash so provide
it along with /bin/sh.

(From OE-Core rev: cc8d54521aa79c1ca88c801e89c3ade6c17ae7a2)

Signed-off-by: Wes Lindauer <wesley.lindauer@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Changqing Li
bfe2255172 checklayer: generate locked-sigs.inc under builddir
yocto-check-layer will find locked-sigs.inc under builddir,
but locked-sigs.inc is generated under current bitbake working
dir. if run yocto-check-layer outside builddir, we will met error
like "No such file or directory: *locked-sigs.inc". change to
run bitbake -S under builddir to fix this problem.

[YOCTO #12973]

(From OE-Core rev: 2ec0bc0b038bc6413978c8f34ef5c0d22b4bc3e7)

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Kai Kang
6da5d5b324 gettext: fix CVE-2018-18751
Backport patch to fix CVE-2018-18751 for gettext. Because po-gram-gen.y
has been modified by fix-CVE-2018-18751.patch, it requires yacc which
provided by bison-native to re-create po-gram-gen.c. Please remove
bison-native from DEPENDS* when next upgrade.

Ref:
https://security-tracker.debian.org/tracker/CVE-2018-18751

(From OE-Core rev: 4b3a085d6c63fd8459bb084aaa277dd2e8949594)

Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-16 11:46:07 +00:00
Richard Purdie
be1c84a91e poky.conf: Update the distros we test against on the autobuilder
(From meta-yocto rev: e2bad29f075d668d70b55f85aec4fd6039e7c119)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Richard Purdie
5078c262e4 poky.conf: Update to post release versioning
(From meta-yocto rev: 5f3083593d7d0bb537d861fd7b995b97a4fee921)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Heiko Schocher
81e48b24dd meta-yocto-bsp: beaglebone-yocto.conf: support 8250 serial driver
it is possible to use the beagleboneblack with the 8250 serial
driver or with the deprecated omap serial driver.

Unfortunately serial console get different names (ttyS0 with
8250 driver and ttyO0 with omap driver)

So set SERIAL_CONSOLES to
SERIAL_CONSOLES ?= "115200;ttyS0 115200;ttyO0"

(intentionally with "?=" so it is overwriteable)
and activate

SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"

with that on the first boot the correct value is picked up
automatically.

(From meta-yocto rev: ffd224382af6fe1f5eeae32d7b28cc975acdde05)

Signed-off-by: Heiko Schocher <hs@denx.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Richard Purdie
490bca81c3 bitbake: utils: Avoid regex value escape warnings
Avoid warnings such as:
bitbake/lib/bb/utils.py:72: DeprecationWarning: invalid escape sequence \d
  numeric_regexp = re.compile('^(\d+)(.*)$')
bitbake/lib/bb/utils.py:1165: DeprecationWarning: invalid escape sequence \(
  var_res[var] = re.compile('^(%s%s)[ \\t]*\([ \\t]*\)[ \\t]*{' % (var[:-2].rstrip(), override_re))

(Bitbake rev: bbf3cbae775383265292a778cd522d4e2f69a3a0)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Richard Purdie
54bbe35eab bitbake: utils: Avoid warnings about deprecated imp module
The imp module is deprecated, port the code over to use importlib.

bitbake/lib/bb/utils.py:30: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
  import imp

(Bitbake rev: 3c2cb35588e91fbd7b136e5e2c78eeb77e126c84)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Richard Purdie
57e290371b bitbake: lib/bb/server: Avoid UnboundLocalError traceback
Traceback (most recent call last):
  File "/home/pokybuild/yocto-worker/nightly-oe-selftest/build/bitbake/lib/bb/main.py", line 464, in setup_bitbake
    server_connection = bb.server.process.connectProcessServer(sockname, featureset)
  File "/home/pokybuild/yocto-worker/nightly-oe-selftest/build/bitbake/lib/bb/server/process.py", line 490, in connectProcessServer
    if command_chan_recv:
UnboundLocalError: local variable 'command_chan_recv' referenced before assignment

(Bitbake rev: ad79fadd855f5c10242ed17e9e0f3eb0274f26d2)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:18:18 +00:00
Andreas Müller
1c7bc2ff9d scons.bbclass: fix indention
(From OE-Core rev: ae12c5f86601a81f4208fd371ce8803464aedaa0)

Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Andreas Müller
11af905ac7 scons.bbclass: Force rebuild if necessary
(From OE-Core rev: dd462c3b3f449805e104be402b23fbfabcaefe8f)

Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Alexey Brodkin
4fd6797319 tcf-agent: Disable architecture-specific features for ARC
There's no support of architecture-specific features for ARC
in tcf-agent, so disable non-generic stuff for now.

(From OE-Core rev: 49b376b84bcb321eac9787957be2c94ec59e0a95)

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Mingli Yu
99956aa33a x264: Disable asm on x86
The previous commit as below only fixes the
textrel issue with musl on x86, update it also to
fix the issue such as with glibc on x86.
74ea4f280c x264: Disable asm on musl/x86

[YOCTO #11770]

(From OE-Core rev: 521af79d1d7635b4bd0ee2cc45b96729285bf469)

Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
a5de19553e rpcbind: 0.2.4 -> 1.2.5
- Drop backport fixes
  0001-rpcbind-pair-all-svc_getargs-calls-with-svc_freeargs.patch
  pmapproc_dump-Fixed-typo-in-memory-leak-patch.patch
  rpcbproc_callit_com-Stop-freeing-a-static-pointer.patch

- Do not manually move binaries from bindir to sbindir,
  the upstream already moved rpcbind from bin_PROGRAMS
  to sbin_PROGRAMS in Makefile.am
  https://git.linux-nfs.org/?p=steved/rpcbind.git;a=commitdiff;h=9afccfcd5ab350d6bc72622f3d1ccfb9e54652b0

(From OE-Core rev: 3df591cd914a4f060f0a178a59c93b464192d80d)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Peter A. Bigot
a97bfad798 bluez5: add mesh dependency on ell
Introduced at or before 5.50.

(From OE-Core rev: aec2020cec8a21ac85797cb049961d9cfcf8b4f1)

Signed-off-by: Peter A. Bigot <pab@pabigot.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
df63ae7edd oeqa/utils/commands: Avoid unclosed file warnings
Avoid warnings such as:

meta/lib/oeqa/utils/commands.py:213: ResourceWarning: unclosed file <_io.BufferedReader name=4>
  return runCmd(cmd, ignore_status, timeout, output_log=output_log, **options)

(From OE-Core rev: 6a68c42de08cffbadb59ebda63fa5e19f6e5acef)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
629c9f1cac oeqa/core/runner: Correctly markup regexs
Avoid the warning "DeprecationWarning: invalid escape sequence \(" by marking
the regexs correctly.

(From OE-Core rev: cb49980fa4a158d5529902df731dec61a8c9b3d4)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
66effe5765 oeqa/loader: Fix deprecation warning
Clean up the warning:
meta/lib/oeqa/core/loader.py:27: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  _failed_test_args = inspect.getargspec(unittest.loader._make_failed_test).args

(From OE-Core rev: d2deb66830be2d44532fea3d5db763b57778252a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
5c590a3733 oeqa/runner: Sort the test result output by result class
We want to see failures/errors listed last since this is the most easily
visible part of the log on consoles or autobuilder output and makes
human processing easier rather than having to scroll up and scan for
a single failure.

(From OE-Core rev: 7954b19020c28a4120bc1671aa81b9e1e2b05fa2)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
cc08d4bad2 oeqa/runner: Always show a summary of success/fail/error/skip counts
Its useful to have the counts of success/failure/error/skipped at the end of the
results to allow for easier human reading of what happened.

(From OE-Core rev: 080d8900d470a8e7f929b0c5c2765ad461744fbb)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
0577d02fae license_image: Fix rootfs file ownership issues with COPY_LIC_DIRS
We need to set ownership of the license files after copying into the rootfs.
We also need to ensure we don't overwrite the rootfs files outside rootfs
generation, hence only write there when the new rootfs function parameter
is True.

[YOCTO #12961]

(From OE-Core rev: 6aa0eeaa4d31a440700f7695174de2a1dcc54866)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Alexey Brodkin
ef63723965 locale: Allow usage of cross-localedef for ARC
With this it's possible to build locale data for ARC
and not do it instead on the first boot.

(From OE-Core rev: f13c303491dc8850126ea14baedc7b63b7b5ecf4)

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Alexey Brodkin
aae2c1ad96 packagegroup-core-sdk: Disable SANITIZERS for ARC
Sanitizers are not yet supported on ARC.

(From OE-Core rev: 1b7b2d2ab887f1c169bb4d3298404549948d1b32)

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Niko Mauno
f00b998ef2 opkg-utils: Fix update-alternatives link relocation
Recently Debian-style support for link relocation was added to
'update-alternatives' script, but it fails under circumstances where
host rootfs root directory differs from target rootfs root directory
and two alternative packages provide a symbolic link with source
located in different directories.

An example of the case is busybox provided /bin/rev (symlinking to
/bin/busybox.nosuid) and util-linux provided /usr/bin/rev (symlinking
to /usr/bin/rev.util-linux) in which case following failure occurs
during image recipe's do_rootfs() task:

  ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of ['util-linux'] have failed. If the intention is to defer them to first boot,
  then please place them into pkg_postinst_ontarget_${PN} ().
  Deferring to first boot via 'exit 1' is no longer supported.
  Details of the failure are in .../tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
  ERROR: core-image-minimal-1.0-r0 do_rootfs: Function failed: do_rootfs

Looking in log.do_rootfs file, following relevant lines can be observed:

  update-alternatives: renaming rev link from /bin/rev to /usr/bin/rev
  mv: cannot stat '/bin/rev': No such file or directory

Mitigate issue by applying patch which adds target root filesystem root
directory path prefix to failing 'mv' calls relevant variable references

(From OE-Core rev: f0912e23629758fe4303284e7db8f4089bb7b4cb)

Signed-off-by: Niko Mauno <niko.mauno@iki.fi>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
8291cd25d8 testimage: Further cleanup DEFAULT_TEST_SUITES
Now the test markup of the development tools tests is complete, this
can be further tweaked to auto run the correct tests.

(From OE-Core rev: bd4f8d12fe1f9f2643ee9e68fa2bb981134294fb)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
cd81cd155b oeqa/runtime/cases: Improve dependencies of kernel/gcc/build tests
Mark up these tests as needing a compiler, make and kernel source code
as appropriate, the image feature requirements can then be retired.

(From OE-Core rev: 9f64e6c25abdf494fb511e9cd401f8dcaa08be2a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
8c4ba1afdd testimage: Simplfy DEFAULT_TEST_SUITES logic
Now that the tests have correct markup to automatically determine which images
they can run against, clean up the default test suites logic to be simpler
and not image specific.

Some cleanup of the compiler tests still needs to be completed but this
is a good first step.

The only downside to this is more noise during testing as we now see
many skipped messages for simple images like core-image-minimal.

The auto type is being removed since it currently breaks badly due to the
socat mandatory inclusion from the meta-selftest layer which is a problem
which needs to be addressed seperately.

(From OE-Core rev: 4966bc33845752eb0aeae54b72e8ba0146a7ed52)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
633bd85270 oeqa/runtime/cases: Improve test dependency information
Add the OEHasPackage decorator to a variety of tests so they determine
automatically if they should run against a given image.

To ensure tests can do this we need to move target operations such
as scp commands into the tests and out of the class startup/teardown.

(From OE-Core rev: 60d6580b85714b8960a964e775d76a7f937f5e5a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
4c034810e5 rng-tools: fix typo of unrecognised options: --disable-jitterntropy
- Fix typo of `--disable-jitterntropy' in both of PACKAGECONFIG and configure --help

- Enable jitterntropy for musl

(From OE-Core rev: c3b96aaa40413d66d8fc4252235e6fa27dd8db53)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Richard Purdie
3eae7a84b2 maintainers.inc: Add entry for libjitterentropy (copied from rng-tools)
(From OE-Core rev: 9a24e79aea2fb3c60803cb265c1d03a1873cfe9d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
9a124f6539 libjitterentropy: add 2.1.2
>From the following kernel commit we know: Fedora has integrated the jitter
entropy daemon to work around slow boot problems, especially on VM's that
don't support virtio-rng

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=81e69df38e2911b642ec121dec319fad2a4782f3

Do the same thing for Yocto.

(From OE-Core rev: fb85c1b420b86b8420785334a3a18afbb013b238)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
b39fca9d45 rng-tools: 5 -> 6.6
- Update SRC_URI, previously upstream is dead, latest update is 2014

- Drop read_error_msg.patch

- Rework do_configure and do_compile

- Enable jitterentropy

License-Update: Upstream changed, but license is still gplv2

(From OE-Core rev: 0d5fb24babec69b653f582acdf47fa22fcdeed2e)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
bc0d9a1a5e machine/qemu*: fix kernel finish crng init more and more slowly
Just adding `-device virtio-rng-pci' to the QEMU invocation will
add the device with a default host backend. As of QEMU 1.3+,
the default backend is to use the host's /dev/random as a
source of entropy. [1]

When the entropy pool is empty, reads from /dev/random will
block until additional environmental noise is gathered. [2]

For Yocto, if call runqemu frequently, it will consume lots
of host's /dev/random, and kernel finish crng init in guest get
more and more slowly.

Here are 4 times runqemu boot test:

[    3.464432] random: crng init done
[   20.874030] random: crng init done
[   23.583589] random: crng init done
[   23.858945] random: crng init done

Modify entropy source to /dev/urandom device on the host which
returns random bytes using a pseudorandom number generator seeded
from the entropy pool. Reads from this device do not block and
kernel finish crng init in guest will not delay.

Of course, the side effect is obviously, we lost the quality of
randomness, but the modification is only on runqemu script
rather than real embedded device, and it benefits oeqa efficiency
in which many cases call runqemu especially multiple oeqa builds
on one host.

After apply the fix:

[    3.364670] random: crng init done
[    4.619061] random: crng init done
[    3.403897] random: crng init done
[    3.450717] random: crng init done

[1] https://wiki.qemu.org/Features/VirtIORNG
[2] http://man7.org/linux/man-pages/man4/random.4.html

(From OE-Core rev: 853644f82eb3205ef3efc1ea3959c7225dfacf61)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
81fc280bae rng-tools: Fix crazy defaults
Since commit [f1dc9ac rng-tools: Fix crazy defaults] fixed
init based on sysvinit, this fix rngd.service based on systemd.

(From OE-Core rev: 078630b7bf8599ea2b3717ce33d2da0f7f26b0e2)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:40 +00:00
Hongxu Jia
d40767ac83 testsdk: fix skipped testcase output "UNKNOWN" status while multiprocess execution
Usually skipped testcase output "SKIPPED"
[snip serial execution]
|RESULTS - buildgalculator.GalculatorTest.test_galculator - Testcase -1: SKIPPED (0.01s)
|RESULTS - python.PythonTest.test_python3 - Testcase -1: SKIPPED (0.01s)
[snip serial execution]

But if enable multiprocess execution, skipped testcase output "UNKNOWN" status
[snip enable multiprocess execution]
|RESULTS - buildgalculator.GalculatorTest.test_galculator - Testcase -1: UNKNOWN
|RESULTS - python.PythonTest.test_python3 - Testcase -1: UNKNOWN
[snip enable multiprocess execution]

Here is my investigation:

There is a class pairs TestProtocolClient and TestProtocolServer
provided by python3-subunit. The TestProtocolClient generates a
subunit stream of TestResult from a test run, and TestProtocolServer
parses the stream of subunit TestResult.

The class ProtocolTestCase is a unittest.TestCase adapter and it
uses TestProtocolServer to parse the stream of subunit TestResult.

In Yocto testsdk, it forks multiple processes to execute testcases
and use TestProtocolClient to generate TestResult stream; and then
it creates multiple threads to use ProtocolTestCase to parse stream
of subunit TestResult through pipe; finally it passes multiple
ProtocolTestCase as TestCase instance to main process and output
status result.

The problem point is TestProtocolServer parses `skip:' directive
after reading a `test:' directive. Without `test:' directive,
`skip:' directive will be ignored. All above requires SkipTest should
be raised inside a test method rather than setUpClass method.

Throwing SkipTest inside setUp works correctly

(From OE-Core rev: 4828a88556d59e4d06933164c2ebeb9361b7450e)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00
Peter Kjellerstedt
6b7227b68a libaio: Extend to native
lvm2 currently requires libaio. So building lvm2-native will result in
the following error.

  ERROR: Required build target 'lvm2-native' has no buildable providers.
  Missing or unbuildable dependency chain was: ['lvm2-native', 'libaio-native']

Extend libaio to native to fix this issue.

(From OE-Core rev: fe871d23c2714e66a1f5e2428a16e742ca40fc62)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00
Mingli Yu
e4263671a3 libsm: extend to nativesdk
After enable tk via PACKAGECONFIG for python3,
there comes below error:
Missing or unbuildable dependency chain was: ['buildtools-tarball', 'nativesdk-python3-testtools', 'nativesdk-python3-pbr', 'nativesdk-python3', 'nativesdk-tk', 'nativesdk-libxt', 'nativesdk-libsm']

Extend libsm to nativesdk to fix this issue.

(From OE-Core rev: 5a527e381705ed8a3e2caba98205c8c8172a347a)

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00
Mingli Yu
b0e6452137 libice: extend to nativesdk
After enable tk via PACKAGECONFIG for python3,
there comes below error:
Missing or unbuildable dependency chain was: ['buildtools-tarball', 'nativesdk-python3-git', 'nativesdk-python3-gitdb', 'nativesdk-python3-async', 'nativesdk-python3', 'nativesdk-tk', 'nativesdk-libxt', 'nativesdk-libsm', 'nativesdk-libice']

Extend libice to nativesdk to fix this issue.

(From OE-Core rev: 46f39d402fbf5487d7a1036fbeec6726ba49334b)

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00
Mingli Yu
c1b27dd347 fontconfig: extend to nativesdk
After enable tk via PACKAGECONFIG for python3,
there comes below error:
Missing or unbuildable dependency chain was: ['nativesdk-packagegroup-sdk-host', 'nativesdk-opkg', 'nativesdk-libsolv', 'nativesdk-rpm', 'nativesdk-python3', 'nativesdk-tk', 'nativesdk-xft', 'nativesdk-fontconfig']

Extend fontconfig to nativesdk to fix this issue.

(From OE-Core rev: f15120430914582f0889ddc442de1055e6c5dca9)

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00
Mingli Yu
ca2e5ccfa0 libxft: extend to nativesdk
After enable tk via PACKAGECONFIG for python3,
there comes below error:
Missing or unbuildable dependency chain was: ['buildtools-tarball', 'nativesdk-python3-testtools', 'nativesdk-python3-pbr', 'nativesdk-python3', 'nativesdk-tk', 'nativesdk-xft']

Extend libxft to nativesdk to fix this issue as
PROVIDES = "xft" in libxft recipe.

(From OE-Core rev: 2709062a47b86bb86b2768f04f97f00af1bb9b47)

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-14 11:14:39 +00:00