Commit Graph

45313 Commits

Author SHA1 Message Date
David Reyna b06f7cbb94 bitbake: toaster: fix SDK artifact capture
Use the TaskArtifacts event to scan the SDK and ESDK manifests
to cleanly collect the respective artifact files.

The previous method was broken when the SDK file deployment moved
from the do_populate_sdk[_ext] tasks to their sstate tasks. That
method is disabled (but not yet removed) in preparation for the
rest of refactor work for the parent #10283 work.

[YOCTO #10850]

(Bitbake rev: 1360d7b847cc01031edb2f4b289fac9560d72fa7)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
Paul Eggleton f187553b6d bitbake: bitbake-diffsigs: fix traceback with no arguments
In the move over to argparse we've made the two signature file arguments
optional and thus if -t is not in use we need to explicitly check if at
least one signature file has been specified - and if not, show an error
and the command-line help.

(Bitbake rev: 9011366689b26305281fcb2d412dcacece917e18)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
Markus Lehtonen fc6370626e bitbake: cache: prevent division-by-zero in load_cahefile()
[YOCTO 11315]

(Bitbake rev: 227c5acd4b40154bc61202e7bb67a13818a7d727)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
David Reyna 2a40a0587e bitbake: toaster: fix add layer button for Machines
Fix a missing close quote in the layer add button, and
use the layer index for the xhr_layer call.

[YOCTO #11213]

(Bitbake rev: 54d61e7c64c97799de85b3563119f0f5d051675e)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
David Reyna d8be835e28 bitbake: toaster: Toaster filters are broken
A syntax fix inadvertantly broke the Toaster filter feature.

[YOCTO #11317]

(Bitbake rev: 29c9fa31d0f03553e24391568d2a5cb588595420)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
Richard Purdie 0793c758b1 Revert "staging: Fix sysroot problem with populate_sysroot dependencies on do_fetch"
There seems to be an issue with the patch, revert for now.

This reverts commit cd5e0a32184d98beb8d81e6b5527166d3ca4fb3c.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 00:57:03 +01:00
Richard Purdie 177d4be3c1 staging: Fix sysroot problem with populate_sysroot dependencies on do_fetch
Dependencies on svn:// urls were failing as the cleandirs on do_fetch was destroying
any sysroot setup by the extend_recipe_sysroot function.

Add code so that if the task do_fetch, we move the cleandirs to the extend_recipe_sysroot
task else we'd wipe out the sysroot we just created.

This allows fetcher do_populate_sysroot dependencies to work correctly again.

(From OE-Core rev: cd5e0a32184d98beb8d81e6b5527166d3ca4fb3c)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie 684eefd7a3 scripts: Drop cleanup-workdir
This script appears broken and is actively breaking build directories.
For example, binutils-cross-i586 gets run do_fetch to do_populate_sysroot by:

$ oe-selftest -r devtool.DevtoolTests.test_devtool_virtual_kernel_modify

then:

$ oe-selftest -r oescripts.BuildhistoryDiffTests.test_buildhistory_diff

wipes out the contents of tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/
but does not wipe out the corresponding stamps, then:

$ oe-selftest -r runtime-test.Postinst.test_postinst_rootfs_and_boot

needs binutils-cross-i586:do_populate_lic and if and only if this is
unavailable from sstate, it fails since it thinks the source is already
unpacked when it isn't resulting in:

WARNING: binutils-cross-i586-2.28-r0 do_populate_lic: Could not copy license file /home/pokybuild/yocto-autobuilder/yocto-worker/nigh
tly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/git/COPYING3.LIB to /home/pokybuild/yocto-autobuilder/yocto
-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/license-destdir/binutils-cross-i586/COPYING3.LI
B: [Errno 2] No such file or directory: '/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-l
inux/binutils-cross-i586/2.28-r0/git/COPYING3.LIB'
ERROR: binutils-cross-i586-2.28-r0 do_populate_lic: QA Issue: binutils-cross-i586: LIC_FILES_CHKSUM points to an invalid file: /home/
pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/git/COPYING3 [license-checksum]

and similar errors.

Its safer for users to wipe tmp than try and maintain scripts which try
to remove pieces of tmp and get it wrong so remove the script.

(From OE-Core rev: 809b23c829f352c0eae455ea89f53e2a9ee87f06)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie 503009b831 oeqa/selftest: Don't use cleanup-workdir
cleanup-workdir isn't a partcularly good way to attempt to cleanup after
tests and in some cases is actively breaking the workdir. Whilst this is
a bug in cleanup-workdir, I'd prefer it didn't break tests, particularly
when as far as I can see, these calls are "belt and braces" and don't appear
to serve a specific purpose. If this introduces bugs, we should fix this
bugs.

For the purposes of history, binutils-cross-i586 gets run do_fetch to
do_populate_sysroot by:

$ oe-selftest -r devtool.DevtoolTests.test_devtool_virtual_kernel_modify

then:

$ oe-selftest -r oescripts.BuildhistoryDiffTests.test_buildhistory_diff

wipes out the contents of tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/
but does not wipe out the corresponding stamps, then:

$ oe-selftest -r runtime-test.Postinst.test_postinst_rootfs_and_boot

needs binutils-cross-i586:do_populate_lic and if and only if this is
unavailable from sstate, it fails since it thinks the source is already
unpacked when it isn't resulting in:

WARNING: binutils-cross-i586-2.28-r0 do_populate_lic: Could not copy license file /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/git/COPYING3.LIB to /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/license-destdir/binutils-cross-i586/COPYING3.LIB: [Errno 2] No such file or directory: '/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/git/COPYING3.LIB'
ERROR: binutils-cross-i586-2.28-r0 do_populate_lic: QA Issue: binutils-cross-i586: LIC_FILES_CHKSUM points to an invalid file: /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/x86_64-linux/binutils-cross-i586/2.28-r0/git/COPYING3 [license-checksum]

and similar errors.

(From OE-Core rev: a66857096df3f68d38271b3a6792150f009a54b1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Dmitry Rozhkov 0e138bf56d python-pycurl: create python3-pycurl recipe
The python-pycurl recipe can be used with python2 only even
though python3 is officially supported by upstream.

Create python3-pycurl recipe enabling the pycurl module for
python3.

(From OE-Core rev: 6cb9c0a4e75c647b38c81d2d7217b54b2fdfd972)

Signed-off-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Markus Lehtonen dff701ffd4 scripts/oe-build-perf-report: improve guessing of args
Search remote branches, too, when finding the latest commit.

(From OE-Core rev: 7b502702be5d484c6f1f903426ba63cf04f8ca4a)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Markus Lehtonen 182dd45f1f oe-build-perf-report-email.py: use proper fallback email address
Use properly formatted fallback email address instead of just the
username.

(From OE-Core rev: 5e07504d7a74f0641e2a374b9d12590ce9c9cc89)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Markus Lehtonen 60658499c2 build-perf-test-wrapper.sh: support extra args for email script
Make it possible to provide (extra) command line arguments to the
oe-build-perf-test-email script via a new environment variable
OE_BUILD_PERF_REPORT_EMAIL_EXTRA_ARGS.

(From OE-Core rev: 9cdd4ea5e006fe326bdf39ea437b9ba61a66b778)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie 343cc9646d uninative-flags.inc: Build binutils-native as pie
Some distros (ubuntu 16.10, debian-testing) default to gcc configured with
--enable-default-pie (see gcc -v). This breaks e.g. prelink-native on a pie
default system if binutils-native was built on a system which is not pie default
We therefore enable pie unconditionally for native recipes where static libs are
used such as libiberty from binutils, for now, until our minimum distro set is
all default pie.

(From OE-Core rev: 80b450cca746f068dd63e4546fa4c1eef2d86a0d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie dc52b27f4c ncurses: Drop incorrect option
The --disable-static option doesn't exist in ncurses. Its equivalent is
--without-normal so remove the option which does nothing.

(From OE-Core rev: 974ddd2f99be04f44978c1bce054ed75c9367631)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie bdc3ba2eb6 no-static-libs: Add entry for ncurses
Yes, the option to disable static libraries in boost really is
"--without-normal". Add this for ncurses and its variants.

(From OE-Core rev: 6b386e444e494b852b59a9f9e80426d564382139)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Richard Purdie 90c1bb7569 selftest/sstatetests: Replace glibc-initial with linux-libc-headers
The intent in these tests was to find something early in the bootstrap
process to run tests against which didn't require long build times.
This breaks with the removal of the glibc-initial do_build target.
Replacing it with linux-libc-headers seems like a good choice
and simplifies the conditionals too.

(From OE-Core rev: c37d610272f9d0a506334ff9f724c025acace137)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Ming Liu 863b6d4f80 cross-canadian.bbclass: override TARGET_* flags
Some TARGET_* flags are being exported in bitbake.conf currently, so
they are impacting all the tasks of a cross-canadian recipe even they
are not in use at all.

This can lead a lot of churn when the cross-canadian sysroot are shared
by machines while they have defined different TARGET_* flags.

Fix it by overriding with BUILDSDK_* flags.

(From OE-Core rev: 767335c92b7cc657a008722a908380a3c89c3c66)

Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Ming Liu e378c0ee4b nativesdk.bbclass: override TARGET_* flags
Some TARGET_* flags are being exported in bitbake.conf currently, so
they are impacting all the tasks of a nativesdk recipe even they are
not in use at all.

This can lead a lot of churn when the nativesdk sysroot are shared by
machines while they have defined different TARGET_* flags.

Fix it by overriding with BUILDSDK_* flags.

(From OE-Core rev: 85b69a5ec9ba9ea9ebdcd8ac18e1e147ddb1ff33)

Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Ming Liu 0ab2c6e82d crosssdk.bbclass: override TARGET_* flags
Some TARGET_* flags are being exported in bitbake.conf currently, so
they are impacting all the tasks of a crosssdk recipe even they are
not in use at all.

This can lead a lot of churn when the crosssdk sysroot are shared by
machines while they have defined different TARGET_* flags.

Fix it by overriding with BUILD_* flags.

(From OE-Core rev: 3facbe700a2f28a11620c4954686ed5d5e47a3d9)

Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Ming Liu b9f9bb443b cross.bbclass: override TARGET_* flags
Some TARGET_* flags are being exported in bitbake.conf currently, so
they are impacting all the tasks of a cross recipe even they are not
in use at all.

This can lead a lot of churn when the cross sysroot are shared by
machines while they have defined different TARGET_* flags.

And sometimes it even causes "Taskhash mismatch" errors.

Fix it by overriding with BUILD_* flags.

(From OE-Core rev: 55c83cb239df5faf5e2143fffca47f2f16931cb3)

Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Paul Eggleton 23095a6b01 lib/oe/sstatesig: avoid reporting duplicate siginfo files from sstate
In find_siginfo(), which is used by bitbake-diffsigs among other things,
avoid adding a siginfo file from the sstate-cache where we've already
collected a sigdata file from the stamps directory with the same hash.
This avoids the possibility that the top two files (as picked by default
using the bitbake-diffsigs -t option) are for the same signature and
thus the tool would report no differences. In order to do that, just use
the hashfiles dict that we already have - we just need to change the
code to populate that even if we're collecting matching files without
looking for a fixed set of hashes (i.e. taskhashlist isn't set).

This replaces previous code in bitbake-diffsigs that attempted to filter
these out with limited success.

(From OE-Core rev: 5b69eef40868180c59400624096d7ebbbbea446b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Paul Eggleton 27b7de94f0 lib/oe/sstatesig: fix finding native siginfo files in sstate-cache
When comparing signatures with bitbake-diffsigs -t or bitbake -S
printdiff, we use this find_siginfo() function implemented in this
module to find the siginfo/sigdata files corresponding to the tasks
we're looking for. However, native sstate files go into a
NATIVELSBSTRING subdirectory and there was no handling for this when
asking about native recipes.

I'm not even sure why we were walking SSTATE_DIR in order to find
this - we don't need to, we just need to run glob.glob() on the filespec
we calculate, which should be a little bit more efficient.

(From OE-Core rev: 8cb472e4ed25e56ec0d9cf6d8d101d1ab6687a5b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:44 +01:00
Martin Kelly e340af0449 qemu: use python2.7 instead of python2
meta/conf/bitbake.conf puts python2.7 into the HOSTTOOLS variable but not
python2, so only python2.7 is guaranteed. In addition, on some distros -- such
as Amazon Linux -- /usr/bin/python2 doesn't exist but python2.7 does. So, use
python2.7 for the --python= argument in the qemu configure step.

(From OE-Core rev: 88dc8b532817f4779b35422a413d5c700c130a74)

Signed-off-by: Martin Kelly <mkelly@xevo.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Leonardo Sandoval 4d1b21fd6d selftest/recipetool: skip create_git in case x11 feature is not present
The unit test requires x11 as distro feature, otherwise it will fail
while building the test requirements.

[YOCTO #10903]

(From OE-Core rev: 2fe8f39b5f5e7390cc46f8cb47c2503b3c5f78e2)

Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Ed Bartosh 88cd926de2 qemux86*.conf: changed dependency task for syslinux
Changed dependency task for syslinux from do_build to
do_populate_sysroot as do_build dependency caused conflicts in
populating image recipe sysroot using conflicting recipes. This
makes do_image_wic task to fail with FileExistsError trying to
copy the same file from two conflicting recipes.

This should also speed up image creation a bit as do_populate_sysroot
task is faster than do_build.

[YOCTO #11295]

(From OE-Core rev: b7bb02901b7002641a8e8cc3fc0b6ec31e5a21f7)

Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Joshua Lock f70179e280 gcc-6.3: backport fix of check for empty string in ubsan.c
Building gcc-cross-initial with GCC7 on the host fails due to the
comparison of a pointer to an integer in ubsan_use_new_style_p, which
is forbidden by ISO C++:

ubsan.c:1474:23: error: ISO C++ forbids comparison between pointer and
integer [-fpermissive]
       || xloc.file == '\0' || xloc.file[0] == '\xff'

Backport the fix from upstream GCC to enable the build with GCC 7

(From OE-Core rev: 7a7fcbab0365b9501c737dbc02715be14dda72a3)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Joshua Lock 5784961762 elfutils: fix building elfutils-native with GCC7
Backport a fix from upstream for a -Wformat-truncation=2 warning
and implement a simple fix for a -Wimplicit-fallthrough warning.

(From OE-Core rev: aaf4c4f3d09ac3897205417eb15e19d54e0c0d05)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Richard Purdie 34313c4047 sstate: Skip glibc do_stash_locale and gcc do_gcc_stash_builddir tasks
We never need these tasks as dependencies of other sstate tasks since
they're only ever needed to build artefacts so we can always skip them
and save some time/space.

(From OE-Core rev: 246df3df4b7da4b75de0745938438124c2b1d4a5)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Juro Bystricky 950be7ae8d license.bbclass: improve reproducibility
Two identical builds can end up having deploy/licenses folders
that differ. This is observed in cases where there are several
different license files of the same name in different folders,
i.e. "COPYING". In those case we have to differentiate the files
somehow and we do it via file expensions such as COPYING.0, COPYING.1.
However, which file will get which extension is presently random.
This means, for example, that COPYING.0 in one build is the same
as COPYING.1 in the other (and vice versa).
Although there is mothing wrong with this, for the sake of binary
reproducibility it is preferable to have a deterministic outcome.

(From OE-Core rev: 007ebc84979b1bc8b7520097793c7ab6d646c243)

Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Leonardo Sandoval f91aedf6b5 selftest/wic: skip wic unit tests in case NLS is disable
WIC test case requires wic-tools which in turn depends on intltool-native and
gettext-native. However, if NLS is disable, the gettext-minimal-native is used instead
of gettext-native causing a failure on intltool-native as seen below:

  checking for msgfmt... no
  checking for gmsgfmt... no
  configure: error: GNU gettext tools not found; required for intltool
  ERROR: Function failed: do_configure (log file is located at /home/lsandov1/poky/build/tmp/work/i586-poky-linux-musl/systemd-boot/232-r0/temp/log.do_configure.7518)
  ERROR: Task (/home/lsandov1/poky/meta/recipes-bsp/systemd-boot/systemd-boot_232.bb:do_configure) failed with exit code '1'
  NOTE: Tasks Summary: Attempted 609 tasks of which 604 didn't need to be rerun and 1 failed.

[YOCTO #10902]

(From OE-Core rev: ccd2faca99331e010badbb78d42b0ee644ca1a0a)

Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Dmitry Rozhkov e9cf698d09 python3: fix run-time deps for core python3 libraries
The http.server module from python3-netclient imports the html module
which is in python3-html. Also xmlrpc.server imports pydoc which is a
part of python3-pydoc. But those run-time dependencies are missing
from python3-netclient and python3-xmlrpc respectively.

Add the missing run-time dependencies.

(From OE-Core rev: 8e30b726c44f873e5fd9d3f36c3464a29b97abd8)

Signed-off-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Martin Jansa 57bbedcfeb eudev: set LGPL-2.1+ for libudev package
(From OE-Core rev: d9430de1b8b40b5f6cba74de20ea2bf69667e64c)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 2752d71e8d kmod: set ac_cv_path_DOLT_BASH to /usr/bin/env bash
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
  #define BINPRM_BUF_SIZE 128

So there would be errors when /path/to/hosttools/bash is longer than 128:

/bin/sh: ./doltcompile: [snip]: bad interpreter: No such file or directory

Set ac_cv_path_DOLT_BASH to "/usr/bin/env bash" to fix the problem.

(From OE-Core rev: fd2758ed26e8ed6d76c66af0275c4aafbec758ac)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 607bc59588 autogen-native: fix POSIX_SHELL and perl
The shebang's length is usually 128 as defined in /usr/include/linux/binfmts.h:
  #define BINPRM_BUF_SIZE 128

So there would be errors when /path/to/hosttools/perl is longer than 128.

This patch fixes the problem when POSIX_SHELL and perl are used as the interpreters.

(From OE-Core rev: 055838283349530e6f60f4169d9190aa5b59b190)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 7daf525d37 guile: do_configure: fix "Argument list too long"
Fixed when len(TMPDIR) =  410:
Can't exec "/bin/sh": Argument list too long at /usr/lib/perl/5.18/IO/File.pm line 65.

This is becuase it has a lot of m4 files, use relative path for them
can fix the problem.

(From OE-Core rev: 123df94f511cbaad088b25bbbae1f1137f957c7e)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 8d26272740 m4: do_configure: fix "Argument list too long"
Fixed when len(TMPDIR) =  410:
Can't exec "/bin/sh": Argument list too long at /usr/lib/perl/5.18/IO/File.pm line 65.

This is becuase it has a lot of m4 files, use relative path for them
can fix the problem.

(From OE-Core rev: 7e8fece3a09bed18bc72c529b8b471ccbc144bf5)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang af440a00c5 valgrind: set ac_cv_path_PERL to /usr/bin/env perl
The shebang's max length is usually 128 as defined in
/usr/include/linux/binfmts.h:
  #define BINPRM_BUF_SIZE 128

So there would be errors when /path/to/hosttools/perl is longer than 128.

Set ac_cv_path_PERL to "/usr/bin/env perl" to fix the problem.

(From OE-Core rev: e828223a8238d85d47e9314e1dcc30b83b7ba3da)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 7b0a757413 mc: replace "perl -w" with "use warnings"
The shebang's max length is usually 128 as defined in
/usr/include/linux/binfmts.h:
  #define BINPRM_BUF_SIZE 128

There would be errors when @PERL@ (hostools/perl) is longer than 128,
use '/usr/bin/env perl' can fix the problem, but '/usr/bin/env perl -w'
doesn't work:

/usr/bin/env: perl -w: No such file or directory

So replace "perl -w" with "use warnings" to make it work.

(From OE-Core rev: 85decf26fe580acdf072baf561418bf73b7bfca4)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Robert Yang 9356d02da0 groff: replace "perl -w" with "use warnings"
The shebang's max length is usually 128 as defined in
/usr/include/linux/binfmts.h:
  #define BINPRM_BUF_SIZE 128

There would be errors when @PERL@ (hostools/perl) is longer than 128,
use '/usr/bin/env perl' can fix the problem, but '/usr/bin/env perl -w'
doesn't work:

/usr/bin/env: perl -w: No such file or directory

So replace "perl -w" with "use warnings" to make it work.

(From OE-Core rev: f3408bcf9d2710b07f5825683931e28571de130c)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Richard Purdie 75001927cd glibc/gcc/libgcc-initial: Delete do_build tasks for -initial
We've had a lot of users running into RSS issues where -initial recipes
were being installed into sysroots alongside their counterparts and
causing overlapping files issues.

In general this was through do_build dependencies. Such dependencies are
bad in general and I'd encourage people to compare the taskgraphs with
using a more specific dependency like do_populate_sysroot, do_image_complete
or do_deploy as often the more specific dependency will result in a much
cleaner build.

Regardless, we don't want -initial dependencies getting in the way like
this and there are cases a do_build dependency could make sense.

Deleting the do_build task in these cases makes sense since this is not
a build "endpoint" we'd ever want a user to use, its a behind the scenes
piece of bootstrappping.

Unfortunately to make this work, we need a newer bitbake version which
has a bitbake bug fixed.

(From OE-Core rev: 04c053d42ab05f77b2d1ca93a0fabae44073d57e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Richard Purdie 66bd8b8247 sanity: Require bitbake 1.33.4
We need the bitbake bug in recrdeptask handling of missing tasks fixed in
order to apply a fix for OE-Core.

(From OE-Core rev: ef16288f3e1e801e5c763ed49fad8eb0c885183e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:43 +01:00
Peter Kjellerstedt 16b822509a base-files: profile: Do not assume that the tty command exists
This avoids the following error when logging in to a host that does
not have the tty command:

-sh: tty: not found

Reported-by: Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>
(From OE-Core rev: e77cdb761169e404556487ac650dc562000da406)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Peter Kjellerstedt 227ec4809d base-files: profile: Whitespace clean up
(From OE-Core rev: 479a6202236832367bb48e4e089a6d99818685e5)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Martin Balik 104dac10f2 busybox: Security fix BUG9071
(From OE-Core rev: 0354a9b7adad27b012bcd6bb6cab54dfe0297bcd)

Signed-off-by: Martin Balik <martin.balik@siemens.com>
Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Catalin Enache 6df3fde8e9 ghostscript: CVE-2017-7207
The mem_get_bits_rectangle function in Artifex Software, Inc.
Ghostscript 9.20 allows remote attackers to cause a denial
of service (NULL pointer dereference) via a crafted PostScript
document.

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

Upstream patch:
http://git.ghostscript.com/?p=ghostpdl.git;h=309eca4e0a31ea70dcc844812691439312dad091

(From OE-Core rev: 0f22a27c2abd2f2dd9119681f139dd85dcb6479d)

Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
David Vincent 77de4e58bf package.bbclass: add CONFFILES to pkgdata
Emit CONFFILES variable in pkgdata, or else the get_conffiles function
will return 'None' for some packages instead of the expected value. This
is especially true for optional module packages.

(From OE-Core rev: ee44dabc065912ac17f1ee5f06f12695c90b5482)

Signed-off-by: David Vincent <freesilicon@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Mariano Lopez 78971cee15 package_ipk.bbclass: Replace empty lines in DESCRIPTION with '.'
opkg uses empty lines as separator for next package and if an ipk file was
packaged with empty lines in DESCRIPTION opkg won't be able to handle such ipk
file, this happens at execution time.

This commit will replace empty lines in DESCRIPTION with a '.' when generating
an ipk package to avoid this issue.

[YOCTO #10677]

(From OE-Core rev: 3e678d9b6a9eaeed76ce538d7f6ecf9f423864bc)

Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Patrick Ohly 7d4fa58c5c yocto-compat-layer: limit report of signature changes
Typically a single change cascades through the entire task dependency
chain. Developers had to figure that out themselves, based on hard to
read and interpret output (not sorted, no indention, no explanations):

   $ yocto-compat-layer.py -n meta-xxxx
   ...
   AssertionError: True is not false : Layer meta-xxxx changed signatures.
   webkitgtk:do_install changed fe2edc9082bc0da98f9cb1391c52f565 -> b3a44684c5cd9aacd3f7c6ed88eefab5
   gstreamer1.0-plugins-good:do_configure changed 3b2f8211be3fe08422bf6087f3af16d1 -> 7d80e42fa1f4f01ff4dfe2ea4477d382
   pulseaudio:do_package_qa changed 5d0a58ada66ff17f5576555302ac319a -> 0e13bcb96143d1ae54c451bc3de0aa30
   epiphany:do_prepare_recipe_sysroot changed 29e1b277dbcb005bd54950594c50d91b -> d3c45527b37677a0668ce483c6db3052
   ...
   gst-player:do_packagedata changed 9ce6efdd357dd74919bc4957458b1e95 -> d0c083ce629f37adfc9c4ba9eff81f83
   gstreamer1.0-plugins-base:do_install changed 1161cd867d15bea63e5dd5d9abf0519c -> 5bf2b652a2d77fee3eedb35af2f201a0
   gstreamer1.0-rtsp-server:do_packagedata changed 6781dc3070f80b843ed1970d74dd323e -> 454620c2e3b9fea87e525d14b6ed0344
   alsa-plugins:do_packagedata changed 1808c3f737cb805b169d004e948ea19c -> 480124b7fa5eab1f73bf96440d725231

Now the tool automates the problem analysis: it retrieves the depgraph
using the tinfoil API and only reports those tasks with modified
signatures whose dependencies have not changed, i.e. those tasks which
definitely introduce a change.

>From the previous example, that just leaves two tasks that need to be
checked:

   AssertionError: False is not true : Layer meta-xxxx changed 120 signatures, initial differences (first hash without, second with layer):
      gstreamer1.0-plugins-base:do_fetch: 76973f19f2e30d282152bdd7e4efe5bb -> e6e7c6fa9f2bd59d7d8d107f7c6ca1ac
      pulseaudio:do_install: 668eb1e30af129df9806b0aa0d7c10cd -> 1196bdb88eef56eeee4613bb06b9387e

This pruning might be a bit too aggressive in the sense that tasks
which inherit a change and then add more changes themselves won't be
reported initially. They will be found when fixing the reported tasks
and re-running the check.

For a developer it seems better to have something listed which
definitely is a problem and needs fixing instead of everything,
including the tasks which don't need fixes.

(From OE-Core rev: 7ab0e09de75bfd7e7498bfa72d1f2f5d02a96747)

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00
Patrick Ohly efd3b0ee30 yocto-compat-layer: fix also other command invocations
In commit 5b9ac62ab535d, one place was fixed where a command was
invoked such that failures caused double stack traces and stderr was
lost. The same problem also occurs elsewhere, triggered for example by
a layer with parsing problems.

Now a new utility method is used instead of repeating the code.

(From OE-Core rev: b6c72c0d169473e2626938be2ee59f850624612e)

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:42 +01:00