Saul Wold [Mon, 27 Nov 2017 19:01:54 +0000 (11:01 -0800)]
kernel.bbclass: Add cleandirs for do_shared_workdir
We add the kernel-build-artifacts to the cleandirs list to ensure
that there are no remaining artificats in the kernel-build-artifacts
directory which is STAGING_KERNEL_BUILDDIR. Without this change
multiple System.map files are visiable in the STAGING_KERNEL_BUILDDIR,
which could cause problems for some tools.
[YOCTO #11880]
Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Ross Burton [Wed, 29 Nov 2017 12:31:55 +0000 (12:31 +0000)]
bash: fix build race under musl
Under musl bash uses its own libintl clone but there are some missing
dependencies so it is possible for pathexp.o to be built whilst libintl.h is
being written, leading to compile errors.
Signed-off-by: Ross Burton <ross.burton@intel.com>
This is the cache variable used by AC_FUNC_MMAP, which is possibly one of the
worst autoconf macros to exist.
Apart from being a runtime test which silently claims that mmap() is broken when
cross-compiling, this is basically to verify that mmap() actually works, because
SVR4.0 (released 1988) was broken. Thirty years later, everyone has a working
mmap().
common-glibc already has an assignment, so add a corresponding assignment to
common-musl and remove it from the machine-specific files.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Ross Burton [Tue, 28 Nov 2017 14:45:36 +0000 (14:45 +0000)]
bash: disable aclocal
Bash hand-maintains their aclocal.m4, so stop autoreconf from invoking aclocal
and overwriting it. This means we can remove the kludge to copy aclocal.m4 to
acinclude.m4.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Rebased autotools.patch and makefile_no_gtk.patch.
Dropped 0001-as10k1-Make-output_tram_line-static-inline.patch with the
assumption that it's not needed any more. The patch added a "static"
qualifier to a function. According to the commit message, this was done
to improve optimization. Upstream removed the "inline" qualifier from
that same function, because it caused some trouble with clang. My guess
is that the patch author actually ran into the same clang problem as
upstream, but came up with a different fix. It doesn't seem like a
function whose optimization anyone would really be interested in.
Dropped all patches. The poll.h patch is included in the release, and
the wordexp patch is not needed any more, because the wordexp function
is replaced by an internal reimplementation.
It would still be possible to enable the use of wordexp with the
--with-wordexp configure option. The option exists, because the internal
reimplementation covers only part of what wordexp can do, so not using
wordexp can in theory cause regressions. However, it seems that
regressions are quite unlikely in practice. Here's some discussion about
the topic:
http://mailman.alsa-project.org/pipermail/alsa-devel/2017-July/122667.html
Signed-off-by: Tanu Kaskinen <tanuk@iki.fi> Signed-off-by: Ross Burton <ross.burton@intel.com>
Dropped patches that are included in the release:
- lame-3.99.5_fix_for_automake-1.12.x.patch
- CVE-2017-13712.patch
The CACHED_CONFIGUREVARS thing to disable SSE code on x86 isn't needed
anymore. The build system now correctly detects when SSE isn't
available.
Note for stable branch maintainers: This release includes several fixes
for bugs that have a CVE number associated with them. The bugs (or at
least most of them) are crashes that seem to be considered "remote DoS"
vulnerabilities, probably because it's easy to imagine lame being used
with untrusted audio files from remote sources. If you want to backport
"all sercurity fixes" to the stable brances, that task seems pretty
difficult. The release notes explicitly mention three CVE numbers, but
there are more: for example, OE had a fix for CVE-2017-13712, which is
not mentioned in the release notes but is fixed in the release. The
commit log doesn't keep any track of CVE numbers either. Maybe it would
be best to just upgrade lame to 3.100 also in the stable branches.
Signed-off-by: Tanu Kaskinen <tanuk@iki.fi> Signed-off-by: Ross Burton <ross.burton@intel.com>
Additional changes in 11.1:
* Fix a crash in filter modules related to flat volumes and volume
sharing
* Fix a crash when the bluetooth adapter reports weird MTU size
* Disable bluetooth MTU autodetection by default
* Add mixer handling back for hardware that doesn't have any alsa-lib
configuration
* Prioritize USB devices over built-in sound cards (11.0 was supposed
to have this feature, but the implementation turned out to be
incomplete)
Patrick Ohly [Mon, 27 Nov 2017 15:56:42 +0000 (16:56 +0100)]
rootfs-postcommands.bbclass: ensure that rootfs gets mounted ro
When read-only-rootfs is active, we need to ensure that the rootfs
does not get mounted read/write by the kernel or initramfs. Adding
"ro" to the boot parameters achieves that.
Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Patrick Ohly [Mon, 27 Nov 2017 15:56:41 +0000 (16:56 +0100)]
connman.inc: do not check IMAGE_FEATURES
Recipes can't rely on IMAGE_FEATURES to determine whether the
resulting packages will be used in an image with read/write or
read-only rootfs because IMAGE_FEATURES is a per-image recipe
variable.
The connman.inc code checked IMAGE_FEATURES to determine whether
/var/run/connman needs to be created via tmpfiles.d when booting a
read-only rootfs. In my tests that is not necessary (anymore?),
something (connman itself?) creates the missing directory.
Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Chen Qi [Fri, 24 Nov 2017 04:57:24 +0000 (12:57 +0800)]
templates/layer.conf: remove backslash to enable bbappend setting
Remove the redundant backslash in template layer.conf file, otherwise,
the bbappend line setting wouldn't have effect, causing bbappend files
in these created layers not having any effect.
Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Martin Hundebøll [Thu, 23 Nov 2017 12:24:10 +0000 (13:24 +0100)]
systemd: allow dots in arguments to template units
When installing systemd template units with an argument, the current code
removes characters between the '@' and the '.' from service names in
SYSTEMD_SERVICE_${PN}, e.g.:
getty@tty1.service -> getty@.service
This fails for services with dots in the argument (which is perfectly
legal in systemd), since the code searches only until the first dot.
E.g.:
vlan@eth0.1.service -> vlan@1.service
This is obviously wrong, and fails in systemd_populate_packages(), where
it fails to find the unit file.
Fix this by reworking the removal of the argument part of the service
name, so that parts before '@' and after teh last '.' are used as base
name.
Signed-off-by: Martin Hundebøll <mnhu@prevas.dk> Signed-off-by: Ross Burton <ross.burton@intel.com>
Ross Burton [Mon, 27 Nov 2017 17:14:50 +0000 (17:14 +0000)]
package_manager: force dnf to refresh the cache
DNF has a time-based cache policy (and a great sense of humour) so it's possible
that 'dnf makecache' won't actually refresh any caches. Force the cache updates
by passing --refresh.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Chen Qi [Thu, 23 Nov 2017 05:55:40 +0000 (13:55 +0800)]
util-linux: fix register location for rfkill to avoid conflict
If we have 'wifi' in distro feature, then busybox would have rfkill
enabled. And we would have the following do_rootfs failure if we
install both busybox and util-linux-rfkill.
Error: cannot register alternative rfkill to /usr/bin/rfkill since
it is already registered to /usr/sbin/rfkill.
There's another provider of rfkill in OE, that is rfkill recipe in meta-oe.
And it also registers rfkill to ${sbindir}/rfkill.
So change the register location of rfkill in util-linux to avoid
conflict with busybox and rfkill recipes.
Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Alistair Francis [Wed, 22 Nov 2017 00:43:57 +0000 (16:43 -0800)]
runqemu: Allow the user to override the device tree option
Update the runqemu script to allow the user to specify a device tree
to boot when calling runqemu.
This involves creating a seperate check_dtb() function incase the user
has specified 'none' for the kernel but still wants a device tree.
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com> Reviewed-by: Ben Levinsky <ben.levinsky@xilinx.com> Cc: Ben Levinsky <ben.levinsky@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Alistair Francis [Wed, 22 Nov 2017 00:43:56 +0000 (16:43 -0800)]
runqemu: Allow the user to override the Kernel option
Update the runqemu script to allow the user to specify a Kernel to boot
when calling runqemu.
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com> Cc: Ben Levinsky <ben.levinsky@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Matt Madison [Tue, 14 Nov 2017 17:20:15 +0000 (09:20 -0800)]
go: ensure use of BUILD_CC when building bootstrap tools
For cross-canadian builds, we were accidentally using
the crosssdk C compiler when building the Go compiler
bootstrap. Add a patch to the make script to let us
use BUILD_CC, and prepend do_compile to set it in
the local environment to ensure that the trailing
blank gets stripped, since that confuses Go.
[YOCTO #12341]
Signed-off-by: Matt Madison <matt@madison.systems> Signed-off-by: Ross Burton <ross.burton@intel.com>
override correctly busybox's applet when CONFIG_FLASH_ERASEALL=y is set
Error: update-alternatives: not linking /builds/image/1.0-r0/rootfs/usr/
sbin/flash_eraseall to /bin/busybox.nosuid since /builds/image/1.0-r0/
rootfs/usr/sbin/flash_eraseall exists and is not a link
Signed-off-by: Andrej Valek <andrej.valek@siemens.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Juro Bystricky [Wed, 22 Nov 2017 21:58:29 +0000 (13:58 -0800)]
ltp: improve reproducibility
ltp package contains several gzipped files.
Improve reproducibility of the build by ensuring the gzipped files
do not contain timestamps in their headers.
initramfs-live-boot-tiny: Create the initramfs-live-boot-tiny recipe
The original initramfs-live-boot recipe RDEPENDS on udev, which is ok since
the init script relies some of its functionality on udevadm and such,
but on core-image-tiny-initramfs the init script simply drops to shell
after a basic setup, so udev is not needed.
This patch splits up an initramfs-live-boot-tiny recipe which does not
use udev, but uses busybox-mdev instead, eudev installed about 600
extra Kilobytes to core-image-tiny-initramfs userspace, by avoiding to
install eudev we achieve an even smaller footprint (almost 40% smaller).
Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
For these reasons:
1) Upstream website has been dead for quite a while now;
2) Nothing is actually using neon in oe-core, except one gstreamer plugin in gst-plugins-bad
(and I couldn't find evidence of that plugin being used anywhere)
However, the recipe is still required by libmusicbrainz in meta-oe and so it will be moved there
(with the tarball taken from debian).
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
install*.sh: add short sleep after parted commands
I wasn't able to install to my Optane SSD due to the following error:
Formatting /dev/nvme0n1p1 to vfat...
mkfs.fat 4.1 (2017-01-24)
mkfs.vfat: unable to open /dev/nvme0n1p1: No such file or directory
Target install-efi failed
A couple lines later I see:
[ 10.265401] nvme0n1: p1 p2 p3
Then looking at the device itself after booting from a USB stick:
root@intel-corei7-64: ~# ls /dev/nvme0n1*
/dev/nvme0n1 /dev/nvme0n1p1 /dev/nvme0n1p2 /dev/nvme0n1p3
So it looks like the parted commands return before the device node is
actually created.
Work around this issue by waiting for device nodes for a short duration.
Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Markus Lehtonen [Wed, 7 Dec 2016 10:08:25 +0000 (12:08 +0200)]
initscripts: don't use update-alternatives
Stop using update-alternatives for managing /etc/init.d/functions. Also,
make the initscripts-functions subpackage to (runtime) conflict with
lsbinitscripts.
[YOCTO #10944]
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Markus Lehtonen [Fri, 18 Nov 2016 12:08:28 +0000 (14:08 +0200)]
sysklogd: don't use update-alternatives
Using update-alternatives for managing init scripts has proved to be
problematic. And, sysklogd rconflicts with other syslog daemons so there
is no point in using update-alternatives from this perspective, either.
[YOCTO #10944]
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Update the packages and file names to reflect the new postinst recipe.
Fix a sh syntax error in the run_serial file exists test which was hidden by a
logic problem in the status code.
Remove the older test_verify_postinst as it's effectively a subset of
test_postinst_rootfs_and_boot, and doesn't work: when booting under systemd the
strings it searches for are not output to the console, but the test still
passes.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Ross Burton [Thu, 15 Jun 2017 16:48:58 +0000 (17:48 +0100)]
bin_package: fail if ${S} doesn't actually contain anything
If the user is trying to use bin_package but the SRC_URI hasn't extracted
anything into ${S}, which is easily done when writing a recipe by hand, instead
of silently shippping an empty package abort the build.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Stefan Agner [Sat, 18 Nov 2017 08:53:57 +0000 (09:53 +0100)]
openssl: fix runtime errors with Thumb2 when using binutils 2.29
When compiling OpenSSL with binutils 2.29 for ARM with Thumb2 enabled
crashes and unexpected behavior occurs. E.g. connecting to a OpenSSH
server using the affected binary fails with:
ssh_dispatch_run_fatal: Connection to 192.168.10.171 port 22: incorrect signature
Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
Stefan Agner [Sat, 18 Nov 2017 08:53:56 +0000 (09:53 +0100)]
openssl: Upgrade 1.1.0f -> 1.1.0g
Deals with two CVEs:
* bn_sqrx8x_internal carry bug on x86_64 (CVE-2017-3736)
* Malformed X.509 IPAddressFamily could cause OOB read (CVE-2017-3735)
Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
Stefan Agner [Sat, 18 Nov 2017 08:53:55 +0000 (09:53 +0100)]
openssl10: fix runtime errors with Thumb2 when using binutils 2.29
When compiling OpenSSL with binutils 2.29 for ARM with Thumb2 enabled
crashes and unexpected behavior occurs. E.g. connecting to a OpenSSH
server using the affected binary fails with:
ssh_dispatch_run_fatal: Connection to 192.168.10.171 port 22: incorrect signature
Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
Stefan Agner [Sat, 18 Nov 2017 08:53:54 +0000 (09:53 +0100)]
openssl10: Upgrade 1.0.2l -> 1.0.2m
Deals with two CVEs:
* bn_sqrx8x_internal carry bug on x86_64 (CVE-2017-3736)
* Malformed X.509 IPAddressFamily could cause OOB read (CVE-2017-3735)
Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
Amanda Brindle [Tue, 21 Nov 2017 00:40:25 +0000 (16:40 -0800)]
scripts/contrib/bbvars.py: Remove dead code
Removed the -m option since this script now searches through all
recipes in the configuration. Also removed dead code, which includes
the functions recipe_bbvars() and collect_bbvars().
Signed-off-by: Amanda Brindle <amanda.r.brindle@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Tom Hochstein [Sat, 18 Nov 2017 15:02:20 +0000 (09:02 -0600)]
libepoxy: Fix build break for EGL_CAST dependency
This is a backport [1] to fix the following build error:
| In file included from /home/r60874/upstream/xwayland/tmp/work/armv7at2hf-neon-mx6qdl-fslc-linux-gnueabi/gtk+3/3.22.17-r0/recipe-sysroot/usr/include/epoxy/egl.h:46:0,
| from ../../../gtk+-3.22.17/gdk/wayland/gdkglcontext-wayland.h:32,
| from ../../../gtk+-3.22.17/gdk/wayland/gdkglcontext-wayland.c:24:
| ../../../gtk+-3.22.17/gdk/wayland/gdkglcontext-wayland.c: In function 'gdk_wayland_gl_context_realize':
| ../../../gtk+-3.22.17/gdk/wayland/gdkglcontext-wayland.c:179:43: error: expected expression before 'EGLContext'
| : EGL_NO_CONTEXT,
| ^
Markus Lehtonen [Mon, 20 Nov 2017 12:15:32 +0000 (14:15 +0200)]
python3: remove two setup.py cross-compile hacks
Remove two unneeded hacks. The first hack ("setup.py: no host headers
libs" patch) is not needed because we use cross-compiler (e.g.
i586-oe-linux-gcc) which has not been configured with any host system
include or library directories, and thus, we don't get any host system
directories when running "gcc -E -v".
The second hack becomes useless after the first hack has been removed
and we get the standard include and lib directories normally from gcc.
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Hongxu Jia [Fri, 17 Nov 2017 06:08:03 +0000 (01:08 -0500)]
systemd: fix formatting IDE storage does not trigger "change" uevents
Formatting IDE storage does not trigger "change" uevents. As a result
clients using udev API don't get any updates afterwards and get outdated
information about the device.
...
root@qemux86-64:~# mkfs.ext4 -F /dev/hda1
Creating filesystem with 262144 4k blocks and 65536 inodes
Filesystem UUID: 98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
root@qemux86-64:~# ls /dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
ls: cannot access '/dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2': No such file or directory
...
Include hd* in a match for watch option assignment.
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Yi Zhao [Fri, 17 Nov 2017 02:17:13 +0000 (10:17 +0800)]
ppp: include netinet/in.h before linux/in.h in pppoe.h
The patch ppp-fix-building-with-linux-4.8.patch tries to fix build error
with 4.8 or newer linux headers, but it would break building with kernel
< 4.8. There is a better solution to fix this issue in upstream.
Backport the upstream patch and replace the old one.
Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
LGPL version has been updated from 2.0 to 2.1, adjust the checksums accordingly.
Rebase various patches.
A few tools have been rewritten from perl (or C) to python, so
add a patch that avoids hardcoding the python path in the shebang,
and remove previous patching with sed.
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
distrodata.bbclass: make upstream version check more useful for git upstreams
Specifically:
1) remove +git${SRCPV} stuff from comparison and output; it's just
unnecessary clutter;
2) write the commit id of the latest version tag into the output;
this saves quite a bit of trouble of manually checking what that
commit id is when doing version updates;
3) when UPSTREAM_CHECK_COMMITS is set, ignore the tags altogether;
instead check if the latest commit is different to the one we use,
and if so, report that the recipe can be updated to said commit
(which is also written into the output, as in 2). Multiple
recipes are failing the upstream check because they never
issue tags, now we can fix them.
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Juro Bystricky [Thu, 16 Nov 2017 19:48:50 +0000 (11:48 -0800)]
sudo: improve reproducibility
Delete various build host references from the internally
generated file sudo_usage.h. The references get compiled into
executables, which leads to non-reproducible builds.
The removed references (configure options) were only used as part
of the sudo "usage", and even then only when ran as root.
Signed-off-by: Juro Bystricky <juro.bystricky@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Jackie Huang [Thu, 16 Nov 2017 07:41:36 +0000 (15:41 +0800)]
libnsl2: fix installed-vs-shipped QA issue
Fix the installed-vs-shipped QA issue:
| WARNING: libnsl2-1.0.5+gitAUTOINC+dfa2f31352-r0 do_package: QA Issue:
libnsl2: Files/directories were installed but not shipped in any package:
/usr/lib64/nsl/libnsl.a
Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Patrick Vacek [Wed, 15 Nov 2017 12:40:41 +0000 (13:40 +0100)]
ca-certificates: Add /etc to SYSROOT_DIRS
For recipes that depend on native ca-certificates.crt, /etc should be
added to the list of directories that automatically populate the
sysroot, otherwise the file may not be there.
Signed-off-by: Patrick Vacek <patrick@advancedtelematic.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
The non-EFI counterpart for installation was previously missing for
initramfs-framework. This simply puts the normal install script in the
correct location for initramfs-framework to make use of it.
Partial fix for [YOCTO #12346].
Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Andre McCurdy [Tue, 14 Nov 2017 19:39:23 +0000 (11:39 -0800)]
systemd: use consistent indenting and coding style in do_install()
Make the polkit fixup etc at the end of do_install() more consistent
with the rest of the function. Also indent do_install_ptest() with
tabs instead of spaces to make do_install_ptest() consistent with
do_install().
Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>