summaryrefslogtreecommitdiffstats
path: root/meta/classes
AgeCommit message (Collapse)Author
2015-04-27fontcache: allow to pass different fontconfig cache dirMartin Jansa
(From OE-Core rev: fc732ee788a254ec388cff8fe5619348014255d3) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-27postinst-intercepts/update_font_cache: fix ownership of fontconfig cacheJonathan Liu
The file ownership of the cache files in /var/cache/fontconfig needs to be set to root:root otherwise it inherits the user and group id of the build user. [YOCTO #7411] (From OE-Core rev: 0ecccc7e75f2833c4f2599ce46b6fb9a0bc06e22) Signed-off-by: Jonathan Liu <net147@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-17fontcache.bbclass: prepend to PACKAGEFUNCS instead of appendingJonathan Liu
Appending to PACKAGEFUNCS results in the font packages missing the postinst/postrm scripts and the fontconfig cache not being generated in /var/cache/fontconfig when creating images or installing font packages. This is because the package data has already been emitted by emit_pkgdata in PACKAGEFUNCS. Prepend to PACKAGEFUNCS to ensure add_fontcache_postinsts is executed before emit_pkgdata. [YOCTO #7410] (From OE-Core rev: 7c6d8054bb87e56180920d790efc25d42e25ab8c) Signed-off-by: Jonathan Liu <net147@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-17autotools: Avoid find race for S = "${WORKDIR}"Richard Purdie
For recipes with PACKAGES_remove = "${PN}", the find which removes .la files can race against deletion of other directories in WORKDIR e.g.: find: '/home/autobuilder/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/qemux86_64-poky-linux/init-ifupdown/1.0-r7/sstate-build-populate_lic': No such file or directory | WARNING: /home/autobuilder/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/qemux86_64-poky-linux/init-ifupdown/1.0-r7/temp/run.do_configure.6558:1 exit 1 from | find /home/autobuilder/yocto-autobuilder/yocto-worker/nightly-oe-selftest/build/build/tmp/work/qemux86_64-poky-linux/init-ifupdown/1.0-r7 -name \*.la -delete The simplest fix is to add the find option which ignores these kind of races. [YOCTO #7522] (From OE-Core rev: dd8099ca3092fbd5c685e5ef1b1c5a8185a6893d) (From OE-Core rev: 1334c1f78b0020855a2579cfc1f4ab077151e917) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-15toolchain-scripts: Allow the CONFIGSITE_CACHE variable to be overriddenRichard Purdie
In multilib and baremetal configurations, this variable can cause a variety of problems due to the use of TCLIBC. At least allowing it to be overriden is a start and allows various configurations to avoid the issue. (From OE-Core rev: 816a62af5181e940f4b5e5f35f6775499fad94eb) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-03-03utils.bbclass: fix create_cmdline_wrapperJavier Viguera
Similar to commit 4569d74 for create_wrapper function, this commit fixes hardcoded absolute build paths in create_cmdline_wrapper. Otherwise we end up with incorrect paths in users of this function. For example the 'file' wrapper in current released toolchain: exec -a /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-fsl-arm/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-file/5.18-r0/image//opt/poky/1.7.1/sysroots/x86_64-pokysdk-linux/usr/bin/file `dirname $realpath`/file.real --magic-file /opt/poky/1.7.1/sysroots/x86_64-pokysdk-linux/usr/share/misc/magic.mgc "$@" (From OE-Core rev: 5102848f97a1821b12e83b2c415ce730c1b35f1b) Signed-off-by: Javier Viguera <javier.viguera@digi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-13toaster.bbclass: use the openembedded-core nameAlexandru DAMIAN
Fixing the bug where the openembedded-core name was registered as "meta" in toaster. [YOCTO #7317] (From OE-Core rev: ab9f17893c4b004906ec232da300915145c125e0) (From OE-Core rev: 3cd31ef5bb5d0bd9245956d16680ba9d9668817e) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11image_types.bbclass: manage 'cpio_append' directoryEnrico Scholz
For cpio images, do_rootfs() can operate on a dirty '${WORKDIR}/cpio_append' directory which contains e.g. files from previous builds. This can cause unwanted files in the image or can break the build. E.g. when there is a cpio_append/init -> /sbin/init symlink symlink, the 'ln -sf' can fail due to SELinux restrictions: | $ ls -la cpio_append/init | lrwxrwxrwx. 1 ensc ensc 10 22. Jan 16:26 cpio_append/init -> /sbin/init | | $ strace ln -sf /sbin/init cpio_append/init | ... | stat("cpio_append/init", 0x7fffbb9ca310) = -1 EACCES (Permission denied) | exit_group(1) = ? Patch cleans up 'cpio_append' before executing the 'do_rootfs' task by adding it to 'cleandirs'. An alternative implementation (which avoids creation of this empty dir for non-cpio images) might remove it within IMAGE_CMD_cpio, but this might break builds where people rely on the existence of this directory (e.g. to add local files). (From OE-Core rev: 4db3cc2360289c062fa0df4678f2f2ef990f0c1a) (From OE-Core rev: 5a5802b15d965f62bf61697e1dbffab89702da96) Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11package.bbclass: Let PR server update PKGV, not PVMike Looijmans
PV is the package version as we need it to be during the build. PKGV is the final version as it ends up in the package, and defaults to PV. The packager handled builds without PR-server by replacing the AUTOINC string in PKGV, but when the PR-server is being used, the script replaces the contents of PKGV with the PV if the PV contains "AUTOINC". Thus the packager overrides any change to PKGV the recipe might have made. This breaks classes like gitpkgv that provide a correctly numbered PKGV, the number as calculated by that class will simply be replaced with a 0-based index from the PR-server. This patch makes the packager look at the PKGV version instead of the PV, and update the PKGV only based on the PKGV contents as set by the recipe. See also the discussion here: http://lists.openembedded.org/pipermail/openembedded-core/2015-January/100329.html From investigating the history of the code and changes in the past year, the use of "pv" instead of "pkgv" appears to be just an oversight, introduced in: commit b27b438221e16ac3df6ac66d761b77e3bd43db67 "prs: use the PRServer to replace the BB_URI_LOCALCOUNT functionality" A later commit 865d001de168915a5796e5c760f96bdd04cebd61 "package/prserv: Merge two similar functions into one" silently fixed this only for the case without PR-server by using pkgv there. (From OE-Core rev: 7895c0a67d381ff66668fca5207bd196f36c91db) (From OE-Core rev: c524c5cfdfe0395b601cb9980e0bbd69b4dc9afa) Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11package/prserv: Merge two similar functions into oneRichard Purdie
Having these two separate functions handling PR values seems pointless, and worse, there are impossible code branches mixed within them. Merge them into one function and tweak comments so at least you don't have to read both functions to figure out what is going on. This does restructure the conditionals to try and aid readability. (From OE-Core rev: 865d001de168915a5796e5c760f96bdd04cebd61) (From OE-Core rev: 508f7dfb301db30964bf77d370a9e48cb7f354f8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11image_types.bbclass: fixed 'init' creation for cpio imagesEnrico Scholz
When /init is a dangling symlink or a symlink to a file which can not be stated on the build system (e.g. due to SELinux restrictions), the '[ ! -e .../init ]' test will succeed which causes the manual creation of /init. E.g. here: | $ ls -la cpio_append/init | lrwxrwxrwx. 1 ensc ensc 10 22. Jan 16:26 cpio_append/init -> /sbin/init | | $ strace /bin/test -e cpio_append/init | stat("cpio_append/init", 0x7fff374a9db0) = -1 EACCES (Permission denied) | exit_group(1) = ? To test for the existence of a file, both '-L' and '-e' checks must be executed and to prevent SELinux noise, the '-L' should happen before '-e'. (From OE-Core rev: 2aa5d2880ee3578f4965f245addd365fb7b1c1ca) (From OE-Core rev: f8d3bee7140cade4c70a1c6583fb6d9ef4063b92) Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11fix '[[: not found' error message using dashVincent Génieux
Remove bash specific syntax '[[ test ]]' replaced with '[ test ]'. Fixes [YOCTO #7112] (From OE-Core rev: f2ff849d5936d3dc5e24301e0620da265df50fea) (From OE-Core rev: 574f27be14a0f0be6a96e097903704c3492620a7) Signed-off-by: Vincent Génieux <vincent2014@startigen.fr> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11package.bbclass: Fix support for private libsMartin Jansa
* n is a tuple since this commit: commit d3aa7668a9f001044d0a0f1ba2de425a36056102 Author: Richard Purdie <richard.purdie@linuxfoundation.org> Date: Mon Jul 7 18:41:23 2014 +0100 Subject package.bbclass: Improve shlibs needed data structure since then 'n in private_libs' was always false and private libs were always processed * this is bad when we have libfoo in private libs, but also some package providing libfoo, that way we ship own libfoo.so, but together with runtime dependency on package providing libfoo (From OE-Core rev: ec1d379683cedca4be1c252475d02c8041227142) (From OE-Core rev: c78a9246a1aae14a1598d4c801faaf27dd31f66a) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11cross-canadian/meta-environment: Allow modification of TARGET_OS to be optionalRichard Purdie
There are some cases we want the manipulation cross-canadian performance on TARGET_OS, there are also cases like meta-environment where we do not want this manipulation. We did try and use immediate expansion to avoid this problem and it works in the non multilib case. If we have a multilib that used an extension, like for example: require conf/multilib.conf MULTILIBS = "multilib:lib32 multilib:lib64" DEFAULTTUNE = "mips32r2" DEFAULTTUNE_virtclass-multilib-lib32 = "mips64-n32" DEFAULTTUNE_virtclass-multilib-lib64 = "mips64" then the n32 extension case will be misconfigured. It turns out saving an unexpanded variable is hard. The best I could come up with was: SAVEDTOS := "${@d.getVar('TARGET_OS', False).replace("{", "*")}" and then localdata.setVar("TARGET_OS", d.getVar("SAVEDOS", False).replace('*','{')) which is rather evil, I'd challenge someone to come up with a nicer way of making it work though! Rather than the above madness, we modify cross-canadian to make the problamtic code conditional. This fixes the original issue (where a linux-gnuspe target was seeing 'linux') of http://cgit.openembedded.org/openembedded-core/commit/?id=0038634ee6e2b6035c023a2702547f20f67c103a but also fixes the multilib one. (From OE-Core rev: 85ff3d6491c54aa712ed238c561742cda4f4ba07) (From OE-Core rev: 78a2eeea4e2ef867437c315337b9188e1f3fa759) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-11icecc.bbclass: properly handle disabling of iceccDmitry Eremin-Solenikov
Always use use_icc to check if IceCC should be enabled. Move ICECC_DISABLED variable checking to use_icc function. Also while we are at it, fix condition in icc_is_allarch function. (From OE-Core rev: 20b0168da47d6e30fcbaf6adab3bde0d398d0d00) (From OE-Core rev: 72ff97a2ec225bafb83be56ca1b8c3c4e68a0c55) Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-15image.bbclass: avoid boot error on read-only systemd imageChen Qi
New version of systemd implements a new feature of updating /etc or /var when needed at boot. For details, please see link below. Opointer.de/blog/projects/stateless.html For now, at boot time, the systemd-sysusers.service would update user database files (/etc/passwd, /etc/group, etc.) according to the configuration files under /usr/lib/sysusers.d. This step is necessary for other systemd services to work correctly. Examples of such services are systemd-resolved and systemd-tmpfiles-setup. The problem is that on a read-only file system, that is, if /etc is read-only, the user database files could not be updated, causing failures of services. This patch fixes this problem by adding users/groups at rootfs time. (From OE-Core rev: c7b9611ad0ead17a624fc73a60c321ff249c2214) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-08rm_work: Fix RM_WORK_EXCLUDE for image/sdk recipesRichard Purdie
A previous change meant image/sdk recipes were removed unconditionally by the class and did not respect RM_WORK_EXCLUDE. This fixes that problem. [YOCTO #7114] (From OE-Core rev: 93d79fc162bd49387958e9e4d898dc4ba50d20b0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-06image: Avoid race over directory creationRichard Purdie
There is a race over the do_package_qa task and the do_rootfs task since rootfs recreates a directory. This patch disables the task (which isn't used for images) to avoid the race: NOTE: recipe core-image-minimal-1.0-r0: task do_package_qa: Started NOTE: recipe core-image-minimal-1.0-r0: task do_rootfs: Started ERROR: Build of do_package_qa failed ERROR: Traceback (most recent call last): File "/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-mips/build/bitbake/lib/bb/build.py", line 497, in exec_task return _exec_task(fn, task, d, quieterr) File "/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-mips/build/bitbake/lib/bb/build.py", line 440, in _exec_task exec_func(func, localdata) File "/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-mips/build/bitbake/lib/bb/build.py", line 212, in exec_func exec_func_python(func, d, runfile, cwd=adir) File "/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-mips/build/bitbake/lib/bb/build.py", line 237, in exec_func_python os.chdir(cwd) OSError: [Errno 2] No such file or directory: '/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-mips/build/build/tmp/work/qemumips-poky-linux/core-image-minimal/1.0-r0/core-image-minimal-1.0' (From OE-Core rev: 0550d112ad9c2ca9f8167dcae35200210923f2c5) (From OE-Core rev: 6becebfea6695d9feb968d5cfd14c54e4da200b3) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-06report-error: Handle the case no logfile existsRichard Purdie
If the task fails early, no error log may exist. Currently we crash in that case, this handles the situation more gracefully. (From OE-Core rev: 1e6bfcab47f532677f87683ba2f5e5fb905e9ba5) (From OE-Core rev: 8e52fea95441f88ab366c3c32b869cb30cc386b7) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31package.bbclass: do variable fixups even when FILES was setPeter Seebach
A number of settings (DESCRIPTION, SUMMARY, postinst, postrm, and appends to RDEPENDS) were made only if FILES_foo was not set for a given package. If you had a modified glibc packaging setup that was defining FILES_glibc-gconv-somelocale, this would prevent the automatic append of glibc-gconv as a dependency, because extra_depends was ignored. I think the assumption may have been that if FILES_foo was set, DESCRIPTION_foo and SUMMARY_foo would also be set, but it seems to me that the right answer is probably to set them if they aren't already set, and leave them alone if they are. (From OE-Core rev: 7e59b0c7e03fc08a6eaf9c8ccb6bfa72b4604cc5) (From OE-Core rev: 860e91dd7cfca6afd08d7c3c62e4653fca2b790c) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31kernel.bbclass: Remove bashismKhem Raj
Fixes build on systems using dash for default shell e.g. errors like run.do_strip.25842: [[: not found | readelf: Error: Unable to read in 0x37 bytes of section headers | readelf: Error: Not an ELF file - it has the wrong magic bytes at the start Change-Id: I29cac15be44a02d75a3d6889b6ae9b2e19bf46af (From OE-Core rev: 6956ffdc6e9879e32360b6ee3a3d286618807485) (From OE-Core rev: 162996ed5a12786a2a5255ebafa15291bcc328cf) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31image_types.bbclass: Populate cpio /init as symlinkNathan Rossi
For cpio/ramfs the kernel will first attempt to execute /init and will emit the following error as the file is empty: Failed to execute /init (error -13) If /sbin/init exists symlink to it so the kernel can immediately start the correct init executable instead of an empty file. (From OE-Core rev: 3505558e067fdde4ab7aaaf3c50886f292d7c166) (From OE-Core rev: 40bf6d0d71bd534fadcbc07b6fbba856e50bc534) Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31kernel-yocto.bbclass: fix shell syntax errorPaul Eggleton
Spaces aren't valid around = in an assignment statement (not even with bash). (From OE-Core rev: fb419b1a3f5dbc5e5019be9d09c4acdbeb460c19) (From OE-Core rev: 47f6432dbc4e5315bed15e073c4b1359c181d227) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31compress_doc.bbclass: support update-alternativesHongxu Jia
While doc file make use of update-alternatives to fix confliction, we should reconfigure update-alternatives for doc compression. Such as util-linux-doc: ... update-alternatives --install /usr/share/man/man1/last.1 last.1 /usr/share/man/man1/last.1.util-linux 100 ... was updated by doc_compress to ... update-alternatives --install /usr/share/man/man1/last.1.bz2 last.1.bz2 /usr/share/man/man1/last.1.util-linux.bz2 100 ... (From OE-Core rev: ba4dd1afc2476259eff52f8a68fba1344e0f0474) (From OE-Core rev: 972b8a14e65c544082806d8bcc38195b27345a89) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31metadata_scm: Fix crash due to uncaught python exceptionMerten Sach
Function base_get_metadata_svn_revision was crashing due to an uncaught IndexError exception. The except notation without parentheses is legacy syntax. It is the equivalent to 'except IOError as IndexError' which is not what we want here. The change catches both exceptions. (From OE-Core rev: 33bea949bae54ddc89aa83cf07d7b1ee62e2b393) (From OE-Core rev: 4a3f37f7d004b196b9caeb558d3461452dd85edc) Signed-off-by: Merten Sach <msach@mailbox.tu-berlin.de> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31package.bbclass: Create empty key/value if not there for shlib_providerKhem Raj
When we use ASSUME_SHLIBS,e.g. ASSUME_SHLIBS = "libEGL.so.1:libegl-implementation" then we end up with errors like below when using shlibs2 (dizzy+) File: 'package_do_shlibs', lineno: 216, function: package_do_shlibs 0212: dep_pkg = dep_pkg.rsplit("_", 1) 0213: if len(dep_pkg) == 2: 0214: lib_ver = dep_pkg[1] 0215: dep_pkg = dep_pkg[0] *** 0216: shlib_provider[l][libdir] = (dep_pkg, lib_ver) 0217: 0218: libsearchpath = [d.getVar('libdir', True), d.getVar('base_libdir', True)] 0219: 0220: for pkg in packages.split(): Exception: KeyError: 'libEGL.so.1' This is because the entry which is being populated does not exist so lets create it if its not already there. Change-Id: I9e292c5439e5d1e01ea48341334507aacc3784ae (From OE-Core rev: a64f81fcef42172f788cec7a63bb4672eac99f94) (From OE-Core rev: b143340700961f916e4a21da42b859ec014dd366) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31useradd.bbclass: set PSEUDO_PASSWD consistent with root directoryPeter A. Bigot
When installing into a sysroot this class examines $D/etc/passwd for content, then invokes useradd to make changes. Under pseudo useradd attempts to look up user information in directories specified by $PSEUDO_PASSWD. For opkg multilib installs $D is not always the same as $IMAGE_ROOT, and the user might already be in the IMAGE_ROOT files, causing a failure during rootfs population. Fix this by ensuring the files pseudo looks at when doing useradd stuff are the same ones that useradd.bbclass will be manipulating. (From OE-Core rev: ec3417ad825c52f5137d38b91d8fcb4637a50f4c) (From OE-Core rev: 0b7e70aafdee68825f3c65bae89bde3e03a20de8) Signed-off-by: Peter A. Bigot <pab@pabigot.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31image.bbclass: search both rootfs and native staging for passwd filesPeter A. Bigot
When pseudo is configured to disallow fallback to the build host /etc/hosts and /etc/group, the selection of ${IMAGE_ROOT} for PSEUDO_PASSWD is insufficient as the necessary files will not be available until base-passwd has been installed and its pkg_postinst script run. Fall back to the ${STAGING_DIR_NATIVE} version of those files until the rootfs versions are available. (The native copies are never modified by the build; the ones in ${STAGING_DIR_TARGET} are updated and may contain settings not consistent with what would be created by post-install useradd/groupadd commands invoked in the image rootfs. (From OE-Core rev: 8c653bafaa32126c54400bb56b9a94f07cd33197) (From OE-Core rev: 185b38b5e9ae22e5ba66bd2edc54f3971a9c97cf) Signed-off-by: Peter A. Bigot <pab@pabigot.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31toolchain-scripts.bbclass: Export KCFLAGS to ensure sysroot is providedOtavio Salvador
When building the U-Boot the lack of a proper sysroot can trigger following error: ,---- | arm-poky-linux-gnueabi-ld.bfd: cannot find -lgcc | make[2]: *** [examples/standalone/hello_world] Error 1 | make[1]: *** [examples/standalone] Error 2 | make: *** [examples] Error 2 `---- Guillaume Fournier has posted a very complete analysis of the problem[1]. 1. https://lists.yoctoproject.org/pipermail/meta-freescale/2014-November/011270.html The use of KCFLAGS makes the build of U-Boot work out of box, now that it uses the Linux kernel build system. Reported-by: Guillaume Fournier <gfournier@brioconcept.com> (From OE-Core rev: 50437f9c187f1a884825a8d1ec12da47a5e58670) (From OE-Core rev: 68954e7e62b8b494168bf83fec517e751c679b21) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31ncurses, busybox, cml1.bbclass: Fix menuconfig display corruptionJason Wessel
Previously there was a change to the ncurses compile to make it more like the typical way it was compiled on a host system. This fixed a whole class of host machines, but masked the real underlying problem with the display corruption issues and menuconfig. The corner case that led to the discovery that the wrong curses.h file was getting used was when there was no curses libraries at all on one of the development hosts. What had happened before was that /usr/include/curses.h on the host system had to match closely enough to the curses.h in the sysroot and then linking against the sysroot version of curses.so was ok (meaning no display corruption). But on some systems with ncurses.h vs curses.h such as SuSE hosts, there were still issues. If we fix the root of the problem and force the mconf and lxdialog to use the correct headers and libraries from the sysroot there is no further issues and the menuconfig target works properly. It also means we can back out the custom compilation flags to the ncurses recipe because they are no longer needed. For the kernel part of the menuconfig / nconfig changes it will be merged separately and this is all based on: https://lkml.org/lkml/2013/3/3/103 (From OE-Core rev: 889e02659dd396feba24f0b0ee6b4043c3f3735a) (From OE-Core rev: b8bba551f96f7ff7c2eb772bbdc0b38ed2449683) Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Roy Li <rongqing.li@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31toaster.bbclass: read elapsed time from the stats fileAlexandru DAMIAN
We read the elapsed time fromt the build stats file, instead of computing it independently. [YOCTO #6833] [YOCTO #6685] (From OE-Core rev: 4f5a4ec0cdaf078463f04be4a6683816e9b78d5f) (From OE-Core rev: 9c1bc0c2e49e1e98edb17bf0f00077497dd26272) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31image_types.bbclass: Make ubi depend on ubifsPascal Bach
The ubi command assumes the ubifs file is present. This makes sure this is really the case. (From OE-Core rev: 0a947408f32d7ab10d2004e7d9332296b82191a3) (From OE-Core rev: 0fff562384670b64ed207423b7f596c99baa71c4) Signed-off-by: Pascal Bach <pascal.bach@siemens.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31systemd: don't add files and dependencies from units ConflictsRoss Burton
Adding dependencies and moving files based on Conflicts tags in unit files isn't right, mainly as it means that systemd depends on systemd-binfmt, because the latter ends up containing the shutdown.target unit. (From OE-Core rev: 02767aac492cedf6ccd02648b8e65751cc23c11c) (From OE-Core rev: 9884e4f872b9ff354832053c86842dd0d3b0c8b3) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failureHongxu Jia
There is a failure to build lib32-meta-toolchain: ... |ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base feeds (qemux86_64 x86 noarch any all). ... In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32' is used to process multilib image/toolchain. But for the build of lib32- meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is deleted. In 'bitbake lib32-meta-toolchain -e', we got: ... |# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations] |# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237 |# "x86" |# del data_smart.py:406 [finalize] |# "" |# pre-expansion value: |# "None" ... The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted it at DataSmart.finalize ... Author: Richard Purdie <richard.purdie@linuxfoundation.org> Date: Tue May 31 23:52:50 2011 +0100 bitbake/data_smart: Change overrides behaviour to remove expanded variables from the datastore ... We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting. For rpm backend in package_manager.py, we use DEFAULTTUNE_virtclass-multilib -lib32 first, if it is not available, and try to use DEFAULTTUNE_ML_<multilib> [YOCTO #6842] (From OE-Core rev: 9c59d3d8b538d3a98ff4b5e5b189a4a23a85da2d) (From OE-Core rev: e5fcc237807d064578028ecf8af51d82c5a66c18) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31multilib.bbclass: fix incorrect TARGET_VENDOR in multilib imageHongxu Jia
While building multilib extended images such as libXX-core-image-minimal, the WORKDIR has the same dir with the building of core-image-minimal. $ ls tmp/work/qemux86_64-poky-linux/ -al ... drwxrwxr-x 3 jiahongxu jiahongxu 4096 Oct 13 16:01 core-image-minimal drwxrwxr-x 3 jiahongxu jiahongxu 4096 Oct 16 11:11 lib32-core-image-minimal ... While image class is inherited, it did not assign OVERRIDES with 'virtclass-multilib-libXXX', so the reason is variable TARGET_VENDOR was not override for multilib in that situation. It refers what did for PN and MLPREFIX, and manually do the multilib override for TARGET_VENDOR in RecipePreFinalise handler. [YOCTO #6844] (From OE-Core rev: 7ca012fb3addb11ba3f899efa0619ddd8d3c6946) (From OE-Core rev: 733ae9a73704fdb1211a4e35a20f2d6337a16709) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31classes/image: remove obsolete MULTILIB_VENDORSHongxu Jia
In oe-core commit 03c5f39b4d7dd8c81e0a130b7d5884e5af039a24, it removed obsolete codes about variable MULTILIB_VENDORS. We clean up the rest obsolete codes related with MULTILIB_VENDORS (From OE-Core rev: 43a1c2dc08b4291e042b6c9ef981bd094ea2c477) (From OE-Core rev: 18be5e2400fb2ca1a46ea504967f3c3522af4fdc) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31mklibs: Fix loader for mipselKhem Raj
Additionally treat ld.so to be searched in sysroot Change-Id: I8b4acb821d9855a1163c7149bc8e369c7c438856 (From OE-Core rev: 4cf539e67333ba2c3fe924b092e104da53e68ca0) (From OE-Core rev: 2c327f75c293a68c39b46d72a27248d72ac80996) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31rm_work: Speed up rootfs/populate_sdk removalRichard Purdie
Commands like bitbake X -c rootfs or bitbake X -c populate_sdk do not trigger rm_work to clean up the directories afterwards since it traditionally hooks onto do_build. This change means those two tasks now clean up after themselves. We use the cleandirs function attribute to handle this. [YOCTO #6413] (From OE-Core rev: 6bf06d80c2ce03dfdedac5ad8cf42ef8e36b0ecb) (From OE-Core rev: 38b1f9d8e4fa9afb8644e4be55191fbe5cfd99a1) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31kernel.bbclass: Create modules directory even if there is no modules installedHe Zhe
During kernel_do_install it needs to make symbol link at ${D}/lib/modules/${KERNEL_VERSION}/build, but there will not be ${D}/lib/modules/${KERNEL_VERSION} if there is no modules installed for current image, which will result in a build failure. Add "mkdir -p ${D}/lib/modules/${KERNEL_VERSION}" here to avoid this failure and the need of similar changes in other scripts that also expect it to exist. (From OE-Core rev: f2f72f8ff623d24fffbb1b0ad40bc08f05ff31dd) (From OE-Core rev: a3dae5c091017827a293affbb8ade179a23efd6d) Signed-off-by: He Zhe <zhe.he@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-11-13meta-environment: Fix config-site with a multilib configMark Hatle
[YOCTO #6951] The TOOLCHAIN_CONFIGSITE_SYSROOTCACHE value was defaulting to the nativesdk path and not the associated target path. Set the value in toolchain-scripts to the target path. Be sure to set the MLPREFIX within the meta-environment script as multilibs are processed. Update the config_site file name to use -BPN- not PN. Otherwise the environment processing can't find the correct filename. (From OE-Core rev: 26a2f98155a867a71217e52d33f761dcc60800ca) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-11-05license.bbclass: canonicalise the licenses named with 'X+'Jackie Huang
If INCOMPATIBLE_LICENSE=GPLv3, GPLv3+ should be excluded as well but not now since there is no SPDXLICENSEMAP for licenses named with 'X+', we can add all the SPDXLICENSEMAP settings for licenses named with 'X+' in licenses.conf, but it's more like a duplication, so improve the canonical_license function to auto map for 'X+' if SPDXLICENSEMAP for 'X' is available, so GPLv3+ becomes GPL-3.0+. (From OE-Core rev: 1d6dab1dbbbfbcb32e58dba3111130157ef2b24f) (From OE-Core rev: 652008fd9dc909836819e5c6808c63643eff6db6) Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-18sstate.bbclass: Fix up white space lost in last commit.Peter Urbanec
Commit e9672387 split one long line into a multi-line string, but in the process white space between words was lost. This results in badly formatted output when this message is printed. (From OE-Core rev: b145374c0a498de0160a9b81f50ce0066ab14862) Signed-off-by: Peter Urbanec <openembedded-devel@urbanec.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-18sstate.bbclass: specify func dirs for sstate_hardcode_pathWenzong Fan
For some recipes that inhrient cmake, the ${B} may be removed by cmake_do_configure() while sstate_hardcode_path() running, this causes build errors: Exception: OSError: [Errno 2] No such file or directory: \ '/path/to/build' The function sstate_hardcode_path() called command: $SSTATE_SCAN_CMD which extended as "find ${SSTATE_BUILDDIR} ..." So the proper function dirs could be ${SSTATE_BUILDDIR}. (From OE-Core rev: a949943e622b08485fc7632a0a743bc009079c67) Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-11package_deb: skip pre/postrm scripts on upgrade, write only one shebangAndreas Oberritter
Trying to upgrade busybox removing symlinks but update-alternatives need these links (sed, cut, tail, etc) in order to work. Adding test to avoid this scripts on upgrade fix the problem, same solution are found in package_rpm class. [YOCTO #6768] (From OE-Core rev: 7b9161dd0c475cca6ea7eb507f7c3c51869eb493) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10package_do_shlibs: Look for provider in the path thats in shlib_provider ↵Khem Raj
dictionary shlib2 code puts the information about path where a provider will be found. e.g. {'/usr/lib/llvm3.3': ('libllvm3.3-llvm-3.3', '3.3')} This is obtained from new shlib2 pkgdata from llvm3.3/3.3-r0/pkgdata/shlibs2/libllvm3.3-llvm-3.3.list However when we search for NEEDED libraries we ignore the key above which is the path where the provider library is installed and instead just seach in libdir and base_libdir and hence libraries which are not in above standard search paths gets ignored even if they appear in DT_NEEDED sections and a note is emitted NOTE: Couldn't find shared library provider for libLLVM-3.3.so, used by files: .... IMO this note should actually become an error since if we do not have all DT_NEEDED libraries in image the system is dysfunctional. This patch extracts this libpath from key and add it to seach paths when looing for a provider of a shared library [YOCTO #6798] Change-Id: Ie5f08632e37ba8d3439c8aaae33bc68b8996792f (From OE-Core rev: bf8472274ac1e9a35f8cbc82357da6c95b396759) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10toolchains-scripts: Add support for target environment scriptsRichard Purdie
In a similar way to the previous script which adds support for native environment scripts, this adds support for target environment scripts too. (From OE-Core rev: 2d9466734f0c0c90724820bc36992b2800ffa4d0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10sstate.bbclass: split the too long lineRobert Yang
The too long line would cause "git send-email" report errors: patch contains a line longer than 998 characters Though we can use "--no-validate" to force the send. (From OE-Core rev: e96723879eb3352a5bdea7b3e1a576edf9550e5a) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10sstate.bbclass: the second bb.fatal not workRobert Yang
The code: bb.fatal("foo1") bb.fatal("foo2") Would make the second one not work, use bb.error for first one to fix the problem. (From OE-Core rev: 33a87187a8520e190bcade76cc965aa58faaa85a) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-10toolchain-scripts.bbclass: Allow sourcing of subscript for environmentOtavio Salvador
Sometimes we require extra environment settings to be available on the environment for proper SDK work. This were done, in past, using '_append' tasks however with the split of the environment in a canadian package this has been broken. The easier and more flexible solution is to use environment subscripts which are sources by the main script. These are now looked at: $OECORE_NATIVE_SYSROOT/environment-setup.d/*.sh and sourced. (From OE-Core rev: 457291f2ca084d1f43c0cca2175b448a22761887) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-06package_ipk.bbclass: Fix SRC_URI whitespace handlingMark Hatle
The SRC_URI may contain whitespace, but be otherwise empty. This can happen in the case: MYSRC = "" MYSRC_arm = "file://myarm.patch" SRC_URI += "${MYSRC}" Unless we strip blank spaces, to determine if it is empty, we can end up generating a "Source: " line which in invalid. This leads to the error: invalid Source: field is speified in the generated CONTROL file (From OE-Core rev: 16cedc3bce6fc37543e9ef053cd7c589e523ca1c) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>