Age | Commit message (Collapse) | Author |
|
This reverts commit b08976456c8ab7f29efd83644ce42746c0d6501b.
|
|
This switches the code to build pkgdata specific to the current recipe
which means that its filtered to the recipes dependencies and can perform
better as we can drop the lockfile.
It uses a similar method to the staging code to do this, using BB_TASKDEPDATA
to construct a list of packagedata task output which this recipe should "see".
The original pkgdata store is left unaltered so existing code works.
The lock file was there to prevent files disappearing as they were read or as
directories were listed. Since we have a copy of the data and only access output
from completed tasks (as per their manifests), we can remove the lock.
The lock was causing starvation issues on systems with parallelism.
There was also a potential determinism problem as the current code could "see"
data from recipes which it doesn't depend upon.
[YOCTO #13412]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
multiconfig dependencies no longer appear in BB_TASKDEPDATA so we can drop
this code.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Changes to the sysroot are just as interesting during development, so write the
file listing for the sysroot to buildhistory too.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
populate_packages relies on ``mkdir`` to both create a directory and set
its permissions. However, ``mkdir`` honors the ``umask`` value.
Therefore, some bits may be lost in the operation. In our case, the
setgid bit on the directories were lost.
This commit fixes this by having a distinct call to create the directory
and to set the permissions.
Signed-off-by: Jean-Tiare Le Bigot <jean-tiare.le-bigot@easymile.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Fixed:
MACHINE = "qemux86-64"
require conf/multilib.conf
MULTILIBS = "multilib:lib32"
DEFAULTTUNE_virtclass-multilib-lib32 = "x86"
$ bitbake core-image-minimal
update-alternatives: libtool has multiple providers with the same priority,
please check
/path/to/rootfs/usr/lib/opkg/alternatives/libtool for details
Both libtool and lib32-libtool have the same priority (as they're the same
recipe), so update-alternatives won't deterministically pick a provider. This
means you could end up with an image using a 32-bit pkgconfig and 64-bit
libtool, for example.
Make extended recipes reduce priority by 1 (or 2, 3 ... when there are multiple
variants in MULTILIB_VARIANTS) to fix the problem.
[YOCTO #13418]
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Recipes like postfix run command newaliases in postinst, but newaliases is
installed as newaliases.postfix, it needs run update-alternatives to update it
to newaliases, so there was an error when installed postinst on target.
Fixed:
$ opkg install postfix
Configuring postfix.
///var/lib/opkg/info/postfix.postinst: line 4: newaliases: command not found
Run update-alternatives firstly will fix the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
KERNEL_VERSION gets expanded at runtime to contain the real kernel
version. There is code to ensure the signatures are determinisic but
the multilib expansion code breaks this.
Exclude the variable from the datastore used for expansion to avoid this.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Building lttng-modules for a "lib32" multilib, then changing to a "lib64"
multilib with "lib32" removed doesn't rebuild lttng-modules.
This is due to the multilib pieces in RPROVIDES being added after RecipeParsed
which is after the signatures are generated.
Changing this to RecipeTaskPreProcess allows the multilib components to be
accounted for correctly in the task hashes.
This addresses failures on the autobuilder seen in lib64-core-image-sato-sdk
builds where lttng-modules was being reused from qemux86 world build's lib32
version.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The intercept is called update_icon_cache which is vague: rename to
update_gtk_icon_cache to make it clearer what it is for, and add a comment
explaining what class caused it to be used.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Instead of generating a series of indexes via range(len(list)), just iterate the
list.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
By default GOCACHE is set to $HOME/.cache.
Fixes:
ERROR: go-cross-dbfp4-1.12.1-r0 do_compile: Function failed: do_compile (log file is located at /workdir/build/tmp/work/x86_64-linux/go-cross-dbfp4/1.12.1-r0/temp/log.do_compile.8120)
ERROR: Logfile of failure stored in: /workdir/build/tmp/work/x86_64-linux/go-cross-dbfp4/1.12.1-r0/temp/log.do_compile.8120
Log data follows:
| DEBUG: Executing shell function do_compile
| Building Go cmd/dist using /workdir/build/tmp/work/x86_64-linux/go-cross-dbfp4/1.12.1-r0/recipe-sysroot-native/usr/lib/go.
| failed to initialize build cache at /home/pokyuser/.cache/go-build: mkdir /home/pokyuser/.cache: permission denied
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /workdir/build/tmp/work/x86_64-linux/go-cross-dbfp4/1.12.1-r0/temp/log.do_compile.8120)
ERROR: Task (/workdir/repo/poky/meta/recipes-devtools/go/go-cross_1.12.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 23 tasks of which 16 didn't need to be rerun and 1 failed.
Signed-off-by: Ricardo Ribalda Delgado <ricardo@ribalda.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
* update-rc.d has added support of enable/disable options, which are
expected to keep the previous configuration even after upgrade the packages.
With support for these options, it will only create start/stop link
when there are none, or it will keep the previous configuration.
Our preinst uses "-f remove" to remove any links under the /etc/rcrunlevel.d
which is conflicting behavior with disable/enable options, so remove it.
For example, if a user disabled one service before upgrade,
then after upgrade the service could be started. This happens because during preinst,
all links have been deleted, then postinst may create the link to start service.
With this change, we remove preinst and therefore keep the previous links
so that after upgrade, if a link existed for the package, then the postinst
will not create new start/stop links.
* remove '-f' for postinst. Previously, the keepalived recipe used 'remove'
during postinst, so we needed the -f, but now the keepalived recipe has fixed
this problem, so it's safe to remove '-f'.
[Yocto #12955]
Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The comment is misleading and there was confusion in a bug report. In the native
case STAGING_DATADIR would be equal to the native value so there isn't any issue
but tweak the comment.
[YOCTO #12761]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
In the NVD json CVE feed, affected versions can be strictly matched to a
version, but they can also be matched with the operator '<='.
Add a new condition in the sqlite query to match affected versions that
are defined with the operator '<='. Then use LooseVersion to discard all
versions that are not relevant.
Signed-off-by: Pierre Le Magourou <pierre.lemagourou@softbankrobotics.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
In some rare cases (eg. curl recipe) the CVE_PRODUCT contains more than
one name.
Signed-off-by: Pierre Le Magourou <pierre.lemagourou@softbankrobotics.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Use the new update-cve-db recipe to update database.
Signed-off-by: Pierre Le Magourou <pierre.lemagourou@softbankrobotics.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
to it
* just to make sure it's expaned by bitbake before it gets
executed in shell
* e.g. with cmake.bbclass and cmake recipe (any recipe without
PACKAGECONFIG options have this issue) it looks like this:
bitbake -e cmake | grep EXTRA_OECMAKE=
EXTRA_OECMAKE=" -DCMAKE_DOC_DIR=share/doc/cmake-3.14
-DCMAKE_USE_SYSTEM_LIBRARIES=1 -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0
-DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0
-DCMAKE_USE_SYSTEM_LIBRARY_LIBRHASH=0 -DKWSYS_CHAR_IS_SIGNED=1
-DBUILD_CursesDialog=0 -DKWSYS_LFS_WORKS=1
\${PACKAGECONFIG_CONFARGS}"
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
If we're going to clean buildpaths from installed .la files then we should do it
globally, not in a class that only six recipes in oe-core use.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Instead of reporting large chunks of the work directory and not the package
name:
"File /work/corei7-64-poky-linux/libidn2/2.2.0-r0/packages-split/libidn2-dev/usr/lib/pkgconfig/libidn2.pc in package contained reference to tmpdir"
We can clean up the paths and be more useful:
"File /usr/lib/pkgconfig/libidn2.pc in package libidn2-dev contains reference to TMPDIR"
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
sanitize fitImage hash algorithm selection with FIT_HASH_ALG
switch default hash algorithm from sha1 to sha256
Signed-off-by: Ayoub Zaki <ayoub.zaki@embexus.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
* especially when pushing longer history to slow remote git server or when
it timeouts during the push, it's useful to see where the time was actually
spent
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
AArch64 images are not self-decompressing, thus usually much larger.
Boot times can be reduced by compressing them in FIT and uImages.
Signed-off-by: Laurent Bonnans <laurent.bonnans@here.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Previously the subprocess command to run dtc was not properly displaying
the error on console. Combining stderr into stdout for the dtc subprocess
so the actual error can be seen on console without having to open the
do_compile log.
For example, previously on a dtc error, just the following stack trace
and dtc command was being shown on console:
File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
0001:
*** 0002:devicetree_do_compile(d)
0003:
File:
function: devicetree_do_compile
0127: if not(os.path.isfile(dtspath)) or
not(dts.endswith(".dts") or devicetree_source_is_overlay(dtspath)):
0128: continue # skip non-.dts files and non-overlay
files
0129: except:
0130: continue # skip if can't determine if overlay
*** 0131: devicetree_compile(dtspath, includes, d)
...
Exception: subprocess.CalledProcessError: Command '['dtc', '-R', '8',
'-b', '0', '-p', '0x1000', '-i', '${INCLUDES}, '-o', 'system-top.dtb',
'-I', 'dts', '-O', 'dtb', 'system-top.dts.pp']' returned non-zero exit
status 1
with this patch, the actual error from the dtc command will be appended
like the following:
Subprocess output:
Error: Label or path not found
FATAL ERROR: Syntax error parsing input tree
Signed-off-by: Jaewon Lee <jaewon.lee@xilinx.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
scons tries to get build time vars by loading sysconfigdata. Inherit
python3native instead of using host python and unset
_PYTHON_SYSCONFIGDATA_NAME to avoid the need to depend on target
python3 for sysconfigdata when using scons to build.
Avoids build errors on still supported CentOS 7:
| DEBUG: Executing shell function do_compile
| scons: *** SCons version 3.0.5 does not run under Python version
3.4.8.
| Python 2.7 or >= 3.5 is required.
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Since UBOOT_DTB_BINARY empty means we don't need to inject signatures
into the U-Boot DTB, we can remove the dependencies between consumers of
these two classes and resolve a circular dependency between u-boot and
kernel.
Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
MACHINE set to qemux86-64
for lib32-core-image-sato, during do_rootfs, it will run
install_complementary, which will get localedir by
d.getVar("libdir"), without override, libdir will still be
lib64. add override to fix it.
Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
With meta-micro, ${prefix} is the empty string. This means that
CMAKE_INSTALL_BINDIR:PATH and friends end up containing paths starting with
many instances of "../", presumably due to os.path.relpath attempting to
find its way to the current directory.
Let's avoid this by ensuring that the root path always ends in a slash. If
it already ends in a slash then adding another one shouldn't cause any
problems.
Signed-off-by: Mike Crowe <mac@mcrowe.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The package 'make-mod-scripts' creates files in 'kernel-build-artifacts/include/config'
which are removed by 'cleanall/cleansstate' of 'virtual/kernel'. And this causes the
below error while building out of tree kernel module:
ERROR: Kernel configuration is invalid.
include/generated/autoconf.h or include/config/auto.conf are missing.
Run 'make oldconfig && make prepare' on kernel src to fix it.
Suggested-by: Jun Nie <jun.nie@linaro.org>
Signed-off-by: Haiqing Bai <Haiqing.Bai@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
A non-SPDX license (which is not an alias to an SPDX license) cannot
currently be marked as incompatible in INCOMPATIBLE_LICENSE.
In the current state, we take all INCOMPATIBLE_LICENSE and pass them
through expand_wildcard_licenses which is only adding SPDX licenses that
match the glob regexp of what is in INCOMPATIBLE_LICENSE (be it a direct
match to an SPDX license or via an alias).
This does not work well with custom licenses.
E.g.:
foo.bb:
LICENSE = "FooLicense"
conf/local.conf:
INCOMPATIBLE_LICENSE = "FooLicense"
`bitbake foo`
Gives no warning, no error, builds and packages successfully, because
INCOMPATIBLE_LICENSE is basically empty since FooLicense is neither in
SPDXLICENSEMAP nor in SRC_DISTRIBUTE_LICENSES.
Let's add the original licenses to the list returned by
expand_wildcard_licenses to be able to handle the aforementioned case.
INCOMPATIBLE_LICENSE = "FooLicense GPLv2 GPLv3+" used to "resolve" to
"GPLv2 GPLv3". It now resolves to "FooLicense GPLv2 GPLv3 GPLv3+" which
fixes the issue with custom licenses not being in SPDXLICENSEMAP or
SRC_DISTRIBUTE_LICENSES and thus being left out of the blacklisted
licenses.
I needed to pass a list to expand_wildcard_licenses from the
license_image class instead of the current output of map() because the
operator [:] does not work on this kind of type, and list(map()) or
anything that iterates over map() actually moves the iterator and breaks
the forloop right after in expand_wildcard_licenses.
Signed-off-by: Quentin Schulz <quentin.schulz@streamunlimited.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
OE_IMPORTS is not intended to be touched by users, but there are cases
in which layers might want to make additional Python modules available
to Python functions. For example, Python modules defined in the layer
themselves (under meta-layer/lib).
Signed-off-by: Chris Laplante <chris.laplante@agilent.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
testimage.bbclass starts qemu with the first image type found in
the IMAGE_FSTYPES list. It's weird: this ['wic', 'tar'] works but
this ['tar'. 'wic'] does not. If QB_DEFAULT_FSTYPE is defined,
this fstype is booted.
Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
SCons has supported python3 since 3.0.0 release, use it.
[YOCTO #13381]
Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
This introduces a variable, PKGDATA_VARS, that contains the names of
the variables that are to be output in the runtime pkgdata files.
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Sorts the list of detected ELF files by path before processing. This
ensures that when multiple files are hardlinked together the first one
found is always the same. This is required to have reproducible builds.
Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The do_populate_sysroot task doesn't rerun if you change any of the USERADD_PARAM
or GROUPADD_PARAM variables, only do_package will.
If another task depends on the recipe, this means it won't see any updated changes.
This patch adds in the missing vardeps ensuring the code is deterministic.
[YOCTO #13232]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
When mixing aarch64 and x86_64 host builds with common sstate, useradd failures
were found. This was due to references to:
/home/pokybuild/yocto-worker/qemuarm/build/build/tmp/sysroots-components/aarch64/pseudo-native/usr/bin/pseudo
or
/home/pokybuild/yocto-worker/qemuarm/build/build/tmp/sysroots-components/x86_64/pseudo-native/usr/bin/pseudo
on the wrong architecture within the useradd postinst files.
Instead of using COMPONENTS_DIR as the FIXME, use PSEUDO_SYSROOT which contains
the arch component as well to avoid this.
Add extra comments to cause the relavent sstate to be rebuilt.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
As of commit 898490c010b [moduleparam: Save information about built-in
modules in separate file] (kernels v5.2-rc1+), modules.builtin.modinfo
is generated as part of the kernel build process.
We package it along with the other module artifacts, so it can be used
by scripts/other build steps.
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
This reverts commit a559ffab30b7b45849ace023808c1fb20811d43d.
This is not needed now that pigz has been marked as a drop-in
replacement.
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Several fetchers support named sources that require setting a SRCREV with
the source name as a suffix. These named SRCREV variables are not captured
in the sstate hash calculation because they're only referenced within the
bitbake fetcher function. Several recipes avoid this bug by adding the
different SRCREVs to their packaging versioning but this is not enforced so
it is very trivial to trip this bug case.
Add a snippet to the base.bbclass anonymous python to add all named SRCREV
variables to the vardeps of do_fetch to capture them in the sstate hash
calculation.
Testing of the bug can be shown by running the following bitbake commands
with this patch set not applied:
bitbake vulkan-demos | tee
sed -i 's/SRCREV_gli = ".*"/SRCREV_gli = "xxx"/' \
../meta/recipes-graphics/vulkan/vulkan-demos_git.bb
bitbake vulkan-demos | tee;
The above results in no errors despite a broken SRCREV because the recipe is
considered unchanged by the bitbake sstate hash.
After applying this patch the above commands instead result in a fetcher
error which is correct.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Setting the CMAKE_C{,XX}_COMPILER_LAUNCHER variables is the recomended way to
deal with ccache in CMake. It allows build scripts to optionally opt-out of
ccache, which is especially useful when the pre-processed GCC output is required.
Signed-off-by: Philippe Normand <philn@igalia.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
(From OE-Core rev: 29fc9210b973be68de474e75068e4c72371afe5a)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Whilst this may take longer to compress, it reduces network transfer and potentially
extraction time so is worthwhile.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The API between lttng-tools and lttng-modules is safe, whitelist it as
the dependency fixes tools failures. This needs a hack in the multilib
class as right now there is no way to know if a given recipe is a kernel
module or not. This needs to be revisited.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Added aarch64_be into cpu family.
Signed-off-by: Lei Maohui <leimaohui@cn.fujitsu.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
The SRC_URI almost definitely shouldn't be using ${PN}, and GitHub */archive/*
tarballs are dynamically generated so the checksums will change over time.
Detect both of these, and emit a QA warning if found.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Fixes [YOCTO #11028]
When dealing with node modules which use "node-gyp" [1] to build native
addons to node. Some temporary build files stay in the image: object
files, static library files, dependency files, ...
This commit does not keep only the required files, but remove the files
which can leads to QA issues (staticdev with static library files).
[1]: https://github.com/nodejs/node-gyp
Signed-off-by: Jean-Marie LEMETAYER <jean-marie.lemetayer@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|