aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes
AgeCommit message (Collapse)Author
2016-02-28populate_sdk_ext: Add images to SDK_INSTALL_TARGETSRandy Witt
When running ext-sdk-prepare.py during sdk installation a check is done to make sure no tasks would run that aren't provided by the "leaf" recipes specified in SDK_INSTALL_TARGETS. However sometimes an image recipe can cause other images to be created such as an initramfs. So make sure those additional images are recognized by ext-sdk-prepare.py and don't flag an error. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28boot-directdisk.bbclass: drop IS_VM chechkingRobert Yang
The IS_VM was used for making menus for vmdk, vdi and qcow2, except hddimg, there is no reason to not make menus for hddimg, so drop it. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28image-live/boot-directdisk.bbclass: remove AUTO_SYSLINUXCFGRobert Yang
No one uses it. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28testimage.bbclass: reuse generic test suitesAlex Franco
Modify existing default test suites to reuse the new generic test suites. Related to [YOCTO #8410] Signed-off-by: Alex Franco <alejandro.franco@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28testimage.bbclass: add generic, image test suitesAlex Franco
Add generic test suites MINTESTSUITE, NETTESTSUITE, DEVTESTSUITE to group common test suites. Add DEFAULT_TEST_SUITES_pn- variables for: * core-image-minimal-dev * core-image-full-cmdline * core-image-x11 * core-image-lsb * core-image-lsb-dev New default test suites use generic test suites. Existing default test suites not modified. [YOCTO #8410] Signed-off-by: Alex Franco <alejandro.franco@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28uninative.bbclass: if the loader can't be found disable instead of failingRoss Burton
Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28uninative: use check_output instead of Popen directlyRoss Burton
Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28lib/oe/qa: add explicit exception for 'file isn't an ELF'Ross Burton
Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28buildstats.bbclass: Don't assume /proc/<pid>/io presentJuro Bystricky
It is not guaranteed Linux kernel was configured with process I/O statistics enabled. If process I/O statistcs are not present, issue a one time warning and do not attempt to read the non-existing stats counters. [YOCTO#9025] Signed-off-by: Juro Bystricky <juro.bystricky@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28package: check inherit instead of PN to decide if a recipe is a packagegroupRoss Burton
Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28mirrors/own-mirrors/sanity: Updates after npm fetcher additionRichard Purdie
Update the classes after the addition of the npm fetcher to match the other fetcher additions. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-28npm.bbclass: Add npm class to match fetcherBrendan Le Foll
npm class supports the npm fetcher, helping doing the basic compile/install stages of an npm package Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-28base: Add nodejs-native dependency for npm:// urlsRichard Purdie
With the addition of the npm fetcher, we add the native dependency handling too. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-28sanity: Improve configuration upgrade capabilities (support meta-yocto -> ↵Richard Purdie
poky transition) Right now, only one configuration file can be processed (conf/bblayers.conf) and it can only have one version number. This is a cause of immense friction between OE-Core and Poky since if one needs a version change, it shouldn't be forced on the other. We'd like to rename the meta-yocto layer (within the meta-yocto repository) to meta-poky. To do this, we need to correct the bblayers.conf file and that means changing the sanity version. After the pain this caused the last time, Paul made me promise never to have them out of sync between OE-Core and Poky, equally, having every distro changing config update OE-Core isn't scalable either. This patch changes the sanity upgrade method to list a more generic format: <config file>:<current version variable name>:<required version variable name>:<upgrade function> This in theory allows us to support upgrades to any of the core configuration files, and allow layers to extend them as needed. Files with the same name can be handled in different layers by setting a unique version name variable in the file itself. The upgrade code is only called if the version variable is set. To allow us to make the poky name change and use a new configuration file name, one last version bump is included for poky to handle the transition. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-28image: Run do_rootfs_wicenv after do_imageRichard Purdie
do_image can modify the content of the rootfs directory so we need to run do_rootfs_wicenv after do_image compeltes or the command can fail. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-26signing-keys: Make signing keys the only publisher of keysRandy Witt
Previously the keys were put into the os-release package. The package indexing code was also deploying the keys rather than only using the keys. This change makes signing-keys.bb the only publisher of the keys and also uses standard tasks that already have sstate. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21classes/populate_sdk_ext: add a better config extension mechanismPaul Eggleton
The sdk_extraconf() method of setting the configuration was awkward since you needed to set it in a class and then inherit that class since function definitions aren't allowed in conf files. It seemed to me the a neater way to do this was to read the extra lines from an additional conf file sdk-extra.conf (which can be located in a conf/ directory anywhere along BBPATH as with other configuration files). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21staging.bbclass: remove trail slash from SYSROOT_DESTDIRRobert Yang
Fixed path: QA Issue: <foo> sysroot-destdir//usr/lib/ <foo> Note the 2 slashes "//". Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21terminal.bbclass: import oe.terminal for oe.terminal.prioritized()Robert Yang
Fixed: INHERIT += "typecheck" $ bitbake -p ERROR: Failure expanding expression auto none ${@" ".join(o.name for o in oe.terminal.prioritized())} which triggered exception AttributeError: 'module' object has no attribute 'terminal' Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21recipe_sanity.bbclass: skip DataSmart in recipe_sanity_eh()Robert Yang
Fixed: $ bitbake quilt -crecipe_sanity File "/path/to/poky/bitbake/lib/bb/siggen.py", line 261, in dump_sigtask p = pickle.dump(data, stream, -1) PicklingError: Can't pickle <COWDict Level: 1 Current Keys: 0>: attribute lookup bb.COW.C failed This is because of: cfgdata[k] = d.getVar(k, 0) If d.getVar(k, 0) is a DataSmart (for example, BB_ORIGENV), it won't have the attribute of bb.COW.C, so the error happend. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21image.bbclass: fix circular dependency when IMAGE_FSTYPES append hddimgRobert Yang
Fixed: IMAGE_FSTYPES_append = " hddimg" $ bitbake -g core-image-minimal-initramfs NOTE: Resolving any missing task queue dependencies NOTE: Preparing RunQueue ERROR: Task /path/to/core-image-minimal-initramfs.bb (do_bootimg) has circular dependency on /path/to/core-image-minimal-initramfs.bb (do_image_complete) ERROR: Command execution failed: Exited with 1 This is because IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}", and if IMAGE_FSTYPES append hddimg, then core-image-minimal-initramfs.bb would be circular dependency: do_bootimg -> do_image_complete -> do_bootimg. Now we check and error out. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21toolchain-scripts.bbclass: add three other path to PATH in env.shJun Zhang
in sdk,there are some utils in sysroot/host-os/bin, sysroot/host-os/sbin/,sysroot/host-os/usr/bin need to use, so add these three paths to PATH in env.sh. Signed-off-by: Jun Zhang <jun.zhang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21populate_sdk_ext.bbclass: Add SDK_RECRDEP_TASKS variableRandy Witt
Currently there isn't a way for the extensible sdk to know all the tasks that will need sstate for an image. This is because a layer can add it's on custom tasks that are required for an image to be generated. The extensible sdk solved this for poky by using recrdeptask and specifying the tasks known to be required for the image as well as for building new recipes. So the SDK_RECRDEP_TASKS variable allows a user to specify additional tasks that need to be pulled in. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-21populate_sdk_ext: Don't ignore SDK_TARGETS valueRandy Witt
This fixes a problem where SDK_INSTALL_TARGETS wouldn't pick up the value in SDK_TARGETS. It also removes the inline python to make the code more readable. Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-19cml1/sstate: Fix missing getVar parameterRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-19waf.bbclass: Remove --disable-static from EXTRA_OECONFFabio Berton
As of commit OE-Core:773c9e18071d71454473dd81aff911104a2e9bc6 EXTRA_OECONF is appended with the option --disable-static on DISABLE_STATIC variable and this cause the error: waf: error: no such option: --disable-static So, we need to disable this option. Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18sstate.bbclass: use oe.gpg_sign for gpg signingMarkus Lehtonen
[YOCTO #9006] Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18sign_rpm.bbclass: do not store key details in signer instanceMarkus Lehtonen
Refactor the LocalSigner class. Do not store keyid or passphrase file in the signer object as they are only needed for some of the methods. For example, the newly added verify() method does not need any key parameters and export_pubkey only uses keyid. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18insane.bbclass: print more info for build-deps and file-rdepsRobert Yang
This is useful for oe newbie: * build-deps: print recipe name, and suggest fixing from DEPENDS or PACKAGECONFIG, for example: WARNING: QA Issue: patch rdepends on libattr, but it isn't a build dependency, missing attr in DEPENDS or PACKAGECONFIG? [build-deps] * file-rdeps: print RDEPENDS_pkg rather than RDEPENDS, for example: WARNING: QA Issue: /sbin/osd_login contained in package nfs-utils requires /bin/bash, but no providers found in RDEPENDS_nfs-utils? [file-rdeps] Fix a bug in file-rdeps, there was "@underscore@" in file-rdeps: WARNING: QA Issue: /sbin/osd@underscore@login_nfs-utils contained in [snip] [YOCTO #8922] [YOCTO #8847] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18cml1.bbclass: fix do_menuconfigMarkus Lehtonen
The functionality got broken after bitbake commit 8bf33a8e92c0e188fa392030025756196c96fcbb which disabled the (bitbake) variable expansion inside python functions. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18image/populate_sdk: seprate variables to fix dependencyChen Qi
Previously, do_rootfs depends on variables like SDK_OS, SDK_OUTPUT, etc. And changing variables like POPULATE_SDK_POST_HOST_COMMAND doesn't cause do_populate_sdk to rerun. This patch separates variables so that do_rootfs and do_populate_sdk could correctly depend on their related variables. [YOCTO #8670] Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18insane: wrap autotools checks in inherits_class(autotools) checksRoss Burton
There's no point doing the autotools sanity checks if a recipe didn't inherit autotools, so check the inherits before doing the checks. Also pass -F (fixed strings) and -q (quiet) to grep. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-18cmake: don't inherit autotoolsRoss Burton
autotools was inherited for some functions some time ago, but now all it's using it for explicitly is autotools_do_install(), which is basically just "make install". Invoke that directly and we can remove the inherit autotools. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-16lib/qa.py: raise ValueError if file isn't an ELFRoss Burton
Instead of raising a generic Exception that can't be handled specifically, raise a ValueError. Also update the callers so any unexpected exceptions are not ignored. Also, rename isBigEngian() to isBigEndian(). Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-16sstate: Add ca-certificates-native to postinst recipes listMing Liu
Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-15buildhistory.bbclass: remove out-dated information on requestPatrick Ohly
buildhistory.bbclass by design is incremental: each build adds or updates information. Information is never removed. Sometimes it can be useful to reduce the information only to those recipes that were build during a specific bitbake invocation, for example when the invocation does a full world build. This is now possible by setting BUILDHISTORY_RESET as explained in the modified class. The comment on the variable also mentions the caveats associated with using this mode. In this mode, buildhistory.bbclass first moves all existing information into a temporary directory called "old" inside the build history directory. There the information is used for the "version going backwards" QA check. Then when the build is complete and before (potentially) committing to git, the temporary directory gets deleted. Because information that has not changed during the build will be reconstructed during full world rebuilds, a git log will then only show real updates, additions and removals. Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-15classes/buildhistory: fix for python function parsing changePaul Eggleton
Variable expressions are no longer expanded in python functions as of BitBake commit 8bf33a8e92c0e188fa392030025756196c96fcbb, so we've now got to do this explicitly here. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-15insane: Add --disable-static to UNKNOWN_CONFIGURE_WHITELISTRichard Purdie
With the addition of a common class passing in this option, add it to the list of standard "unknown" configure options which are known about. Its not interesting/productive to go and update every recipe to handle this flag. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-13buildhistory: Fix regex to handle versions without spacesRichard Purdie
Its valid to have dependencies like XXX (=2.1) without spaces, as injected by debian.bbclass. The code was breaking these into separate components and destroying them so improve the regex to handle them. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-13debian: Fix superfluous setting for RPROVIDESRichard Purdie
PKG_ can be set to something like ${MLPREFIX}<name> and the lack of expansion here means the case where MLPREFIX is empty leads to a bogus RPROVIDES. Use expansion of the variable to avoid this. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-13autotools: Fix interaction with bitbake -bRichard Purdie
If you run bitbake -b on something using autotools with dependencies on m4 files, it currently fails as the TASKDEPDATA is incomplete for bitbake -b and this means the relevant macros aren't found. Work around this by adding *all* m4 files for the -b case (and show a warning). [YOCTO #8890] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-13autotools: Correct dependency search logic errorRichard Purdie
We go to the effort of finding the value of start, we should then use it rather than relying on the value of dep being preserved from the previous loop. Took me far too long to notice this issue when changing the code. Also drop an unused variable. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-12base.bbclass: fix support for gitsm://Patrick Ohly
Before the "Improve handling of SRCPV" change, gitsm SRC_URI entries were merely missing a dependency on git for do_fetch. But after that change, the special handling for "needsrcrev" was not applied, leading to a fetcher error (older bitbake) or even a parse error (recent bitbake). Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11classes/testsdk: do_testsdkext avoid STAGING_DIR/BASE_WORKDIR in PATHAníbal Limón
The inclusion of STAGING_DIR/BASE_WORKDIR in PATH is contaminating the environment, i.e. when try to sanity check perl (check_perl_modules) it takes perl from STAGING_DIR causing eSDK install to fail. Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11classes/sanity: check_perl_modules provide output when failAníbal Limón
When check_perl_modules fail is a good idea to print perl interpeter output for debug purposes. Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11classes/externalsrc: create symlinks for workdir and logsPaul Eggleton
Auto-create symlinks in the source directory to the work directory (${WORKDIR}) and logs directory (${T}) so that they are easier for the user to find. This is particularly useful within the extensible SDK where the user is less likely to be familiar enough with the structure of the build system to know where to find these things, but otherwise they are a useful shortcut for anyone. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11classes/externalsrc: disable rm_work when activePaul Eggleton
If you're using externalsrc, it's very likely that you're going to want to examine the intermediate build results even if the recipe builds successfully; therefore you won't want rm_work to delete those. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11uninative.bbclass: capture stdout/err from patchelf-uninativePatrick Ohly
When patchelf-uninative fails, reporting only the exit code as done by subprocess.check_call() is not enough to understand the problem. We also need to capture and report the output of the command. Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-11image_types_uboot: add cpio.gz.uboot to supported IMAGE_TYPESArnold Csorvasi
U-Boot needs the U-Boot header in a ramdisk image to boot it. Add this header to the cpio.gz image, so that it can be booted with U-Boot. Signed-off-by: Arnold Csorvasi <arnold.csorvasi@ni.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-02-11insane.bbclass: Support MicroBlaze with muslNathan Rossi
MicroBlaze is supported by musl, add entries for the 3 variants. Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Ross Burton <ross.burton@intel.com>