Commit Graph

548 Commits

Author SHA1 Message Date
Paul Eggleton 6d7cf8e9dd lib/oe/terminal: fix konsole terminal support for KDE 4.x
It seems that the --nofork option genuinely stops konsole from going
into the background now; I'm not sure when this changed but it does seem
to be working so we can use it. (Tested with Konsole 2.10 and 2.14.2).

Fixes [YOCTO #4934].

(From OE-Core rev: 49b21abf1020b2eefbbec98415c3d7de8827c993)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-26 07:47:50 +00:00
Paul Eggleton f160730bbd lib/oe/terminal: fix regressions
Fix up some issues introduced by OE-Core commit
818c94f5b9882c2028ef9f056714a0a3c9045551:

* If we want to support versions with more than two parts, versions with
  only one part, or versions with non-integer parts, then we have to
  stay with strings. We can use distutils.version.LooseVersion() to help
  with comparisons.
* We don't want a warning when launching gnome-terminal 3.10+ and
  logger.warn() doesn't take a first integer parameter anyway
  (logger.debug() does).
* Also clean up tabs.

(From OE-Core rev: 565d4a144ab3b8fe04950392497de1e0cf1152a5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-26 07:47:50 +00:00
Sven Ebenfeld 43afafeffa terminal.py: No --disable-factory for gnome-terminal >= 3.10
--disable-factory has been disabled in earlier versions of gnome-terminal
but from version 3.10 it raises an error and quits. This makes devshell
unusable with gnome-terminal >= 3.10. This patch checks for the version and
removes --disable-factory if you have the terminal version 3.10 or higher.

(From OE-Core rev: 818c94f5b9882c2028ef9f056714a0a3c9045551)

Signed-off-by: Sven Ebenfeld <sven.ebenfeld@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-24 23:34:19 +00:00
Randy Witt 1118c12bdf copy_buildsystem.py: Add methods to copy shared state.
Added the helper functions necessary to copy the sstate from the
current build, and generate the file to "lock" it.

(From OE-Core rev: f704b0ad26bbca868c4ac40addb92dcd212f586f)

Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com>
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-24 17:41:43 +00:00
Randy Witt d5d4b70a5d copy_buildsystem.py: Add a way to copy buildsystem to a directory.
This file provides a way to take bitbake and the layers in the
current build and copy them to a target specified.

(From OE-Core rev: 3dc52164fb560ccbe5c203a4587f6286c8fc0389)

Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com>
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-24 17:41:43 +00:00
Paul Eggleton 91a9b3f114 sstatesig: Add ability to filter list of tasks for locked-sigs.inc
(From OE-Core rev: ed4287a60b33cb597eb7fa13b3855a528315b3b0)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-24 17:41:42 +00:00
Paul Eggleton 122ee11bd1 devtool: fix broken clones of git recipes
Because we move the workdir when extracting source, then move the source
and delete the temporary workdir, you lose the indirection symlink
pointed to by the alternates file (which is created when the fetcher
clones it from DL_DIR with -s) and the resulting repository is broken.
In any case, for a source repo that the user may put their own changes
into, we can't really rely on a clone made with -s in case the
original goes away - because of cleanall, DL_DIR disappearing, etc. So
repack the repository so that it is a complete, non-shared clone after
unpacking.

(While I'm at it, add a test for devtool modify with a git recipe which
verifies that this works.)

(From OE-Core rev: dccdde4321c48a571677995a4e1dfc583e899cbe)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:29 +00:00
Paul Eggleton efedd4323b devtool: update-recipe: add handling for git recipes
When updating git-based recipes, in a lot of cases what you want is to
push the changes to the repository and update SRCREV rather than to
apply patches within the recipe. Updating SRCREV is now the default
behaviour for recipes that fetch from git, but this can be overridden
in both directions using a new -m/--mode option.

(From OE-Core rev: 654792bb87610ee3569d02a85fa9ec071bf8ab6d)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:29 +00:00
Paul Eggleton 6015deb9f3 lib/oe/recipeutils: minor improvements to patch_recipe()
* Ensure it knows where to put SRCREV and S
* Handle prepend/append and functions in general

(From OE-Core rev: a770c3764efa857a8b1f0ce4b398277cd483a6af)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:29 +00:00
Paul Eggleton e5bf4ed333 devtool: build: run do_populate_sysroot instead of do_install
If you want to be able to make use of libraries in conjunction with
devtool then we need to install them into the sysroot for other recipes
to use. Make it a configuration option in case it needs to be changed at
runtime.

(From OE-Core rev: 94f517ad8e55edfbe6f06afd963bcfeb849626ff)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:28 +00:00
Paul Eggleton 845efa450c devtool: reset: run bitbake -c clean on recipe
If you've added a new recipe, you want the output cleaned when you do
devtool reset, otherwise cruft from building the recipe may remain which
could interfere with future builds.

(From OE-Core rev: 664d1a7fe8f8288fabc582d00f6e36ab29496ec5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:28 +00:00
Paul Eggleton f205ccaf48 lib/oe/patch: fix PATCHTOOL = "git" with source in a subdirectory
For recipes that have their actual source in a subdirectory of what is
fetched (e.g. mkelfimage), we need to find the root of the repository
within the GitApplyTree code that attempts to set up the required git
hooks and use that, rather than expecting the root to be the same as
${S}.

(From OE-Core rev: d820303f64ea610338ec11ffd79269e7831d1da9)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23 17:35:27 +00:00
Richard Purdie 7dcf6c9d45 machine/qemu: Switch from ext3 to ext4
There is no good reason not to use ext4 at this point, it has advantages
and few drawbacks. Therefore switch the qemu machines over (and the default
runqemu script options).

(From OE-Core rev: 430b9ae71b1aa76f8421127d17e0e0723d4818d3)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21 22:05:37 +00:00
Paul Eggleton f1daefbf52 lib/oeqa/selftest/bblayers: use dashed subcommands
bitbake-layers subcommands with underscores are the old syntax; the
dashed form has been supported (and displayed in the help text) for
quite a while now, and the old syntax is about to be unsupported, so use
the dashed form in the tests.

(From OE-Core rev: ab2efd82b2c3419e0139b91c79a9993b257970c9)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21 22:05:36 +00:00
Richard Purdie e011e92e8c lib/oe/package_manager: Performance tweak in regex usage
Profiling a core-image-sato-sdk rootfs, we're spending over 40s
compiling the same regex over and over again, roughly around 5 million
times.

This is suboptimal, fix for a 40s improvement on a 18.5minute task execution
time.

(From OE-Core rev: d0244702752f54fb74be427af1663e46bfff9a5d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21 22:05:36 +00:00
Richard Purdie b3e92f4b46 oeqa/parselogs: Add exception for new mips error message
The 3.19 kernel introduces this error, ignore it for now.

(From OE-Core rev: 2a0a14275ca00b2d3ca867c82548a41e3bb10986)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21 22:05:34 +00:00
Lucian Musat 26be755cb5 oeqa/ptest: Fixed complementary package install detection and added ptest-runner exit code check
(From OE-Core rev: b214c7b901fe0fad081d7a97f9e91cc218c66bd6)

Signed-off-by: Lucian Musat <george.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-19 07:51:38 +00:00
Chen Qi aa48c4ff4a package_manager.py: use 'purge' instead of 'remove' in case of deb
We need to use 'purge' instead of 'remove' for debian package backend when
removing packages at rootfs time. This is because that 'remove' command for
'dpkg' and 'apt-get' does not remove configuration files.

(From OE-Core rev: 14e8d826c4a5231ef331d8064d150737fe3ed656)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-17 22:35:02 +00:00
Paul Eggleton fdb5639e90 lib/oe/package_manager: support exclusion from complementary glob process by regex
Sometimes you do not want certain packages to be installed when
installing complementary packages, e.g. when using dev-pkgs in
IMAGE_FEATURES you may not want to install all packages from a
particular multilib. This introduces a new PACKAGE_EXCLUDE_COMPLEMENTARY
variable to allow specifying regexes to match packages to exclude.

(From OE-Core rev: d4fe8f639d87d5ff35e50d07d41d0c1e9f12c4e3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-17 14:20:45 +00:00
Lucian Musat 4c00256dd9 oeqa/ptest: Removed buildhistory as requirement for ptest
(From OE-Core rev: 990c0048fc7fe363b679943fe0ed0434645711d9)

Signed-off-by: Lucian Musat <george.l.musat@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-15 21:58:28 +00:00
Lucian Musat 6cac3ad6fa oeqa/smart: Added some new test cases
(From OE-Core rev: 945cdab87ed247524059183e1376923a8655069c)

Signed-off-by: Lucian Musat <george.l.musat@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-15 21:58:28 +00:00
Paul Eggleton 1920ef31f3 oe-pkgdata-util: add some QA tests
Test each of the subcommands that this utility provides.

(From OE-Core rev: 725526139debf12d115fada6bd465a297e169080)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-14 08:41:01 +00:00
Paul Eggleton 9f03969994 oe-pkgdata-util: improve command-line usage
* Use argparse instead of optparse for standardised help output, options
  and a much cleaner code structure
* Look up pkgdata directory automatically so the user doesn't have to
  specify it
* Use standard logging

NOTE: this does mean a slight change in syntax - if you do want to
specify the pkgdata directory (usually only necessary if you're calling
it from within the build process) you need to use the parameter -p (or
 --pkgdata-dir) and specify this before the command, not after it.

Examples:

oe-pkgdata-util find-path /sbin/mke2fs
oe-pkgdata-util lookup-recipe libelf1
oe-pkgdata-util read-value PKGSIZE libc6
oe-pkgdata-util -p /home/user/oe/build/tmp/sysroots/qemux86-64/pkgdata read-value PKGSIZE libc6

(From OE-Core rev: 04dc571ac7c26f0dcf1a1fcd466482e22519998d)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-14 08:41:01 +00:00
Saul Wold af7fc22af0 lib/oe/lsb.py: Fix up for dash
Remove the leading -e when using dash which does not use -e with echo

(From OE-Core rev: 105280d58f7be50e5aee6a33ef1aa89dd6485cbf)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-14 08:41:00 +00:00
Ricardo Neri 4870290ee5 rootfs.py: ignore "NOTE:" when catching warnings
The script looks for any warn|Warn pattern in the log. However,
it may happen that the warn|Warn pattern appears as part of the name
of the objects described in the NOTE lines of the log. Thus, to avoid
false positives, ignore the line if it contains the word "NOTE:"

(From OE-Core rev: 0387d0957909a9977efd8b2008e4d1c6d81ceb2a)

Signed-off-by: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-14 08:40:57 +00:00
Dan McGregor 7c3b9a9a9f terminal.py: add tmux new window option
Add a new terminal type that makes a new window in the running tmux
session instead of splitting the window. 80x25 is not enough to run
menuconfig inside a split window, so add the option to create a new
window instead.

Use the new window option by default when the split window would be
less than 19 lines high.

(From OE-Core rev: d7ef9e49b1c687279f6eb2c7abc32ff915714177)

Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-08 08:00:26 +00:00
Paul Eggleton 30a5c9edc6 classes/license: tweak license format messages
Strictly speaking not all of these characters are operators, so reword
the message to describe them as separators. Also use the standard
"recipename: message" format.

(From OE-Core rev: 9e5da3e83f2a5d43620e07a31728b7427329d8f4)

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>
2015-02-08 08:00:25 +00:00
Rodrigo Chiossi da35877db8 lib/oe/terminal: add support for Terminology terminal emulator
Terminology is the default Enlightenment terminal emulator

(From OE-Core rev: f3da8570a977809fadb08315f384726b80f5ee01)

Signed-off-by: Rodrigo Chiossi <rodrigo.chiossi@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:54 +00:00
Chen Qi 4385b3cc9d package_manager.py: fix rootfs failure with multilib enabled
With the current code, if we use debian package backend and enable
multilib support, the do_rootfs process would always fail with error
messages like below.

    E: Unable to locate package packagegroup-core-boot

This patch fixes the above problem.

(From OE-Core rev: d140d556ae30b6dbd0ffce8882c3e22b17050820)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:54 +00:00
Alejandro Hernandez 57647c9cbb terminal.py: fixes launching multiple windows of gnome-terminal
When resolving a patch, a new process of gnome-terminal
is created for every patch to be resolved, it "waits"
for the previous one to end, instead of launching
multiple windows at the same time.

[YOCTO #7254]

(From OE-Core rev: b457e0b028418260aee25858b8af8938dd038fac)

Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:53 +00:00
Dan McGregor 491d1db8d1 image.bbclass: make kernel depmod data optional
This allows an image to skip the creation of kernel depmod
data. It is useful for creating an image that will run as a
container image inside a host with no knowledge of the parent's
kernel.

(From OE-Core rev: ca641aedff5f6bd155796ead02cb2eb871f8c17a)

Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:53 +00:00
Paul Eggleton ca232b5c7b lib/oe/image.py: add error checking for missing IMAGE_CMD
An invalid value in IMAGE_FSTYPES was triggering a traceback. Add a
check and a reasonable error message instead.

(From OE-Core rev: f38c35b925d6eab0d5a41b8592b0eb8b0a3b7b72)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:51 +00:00
Paul Eggleton 26e5b0f7b9 classes/image: ensure uninstalled packages do not appear in manifests
Since the rewrite of the image construction code in python a few
releases ago, we remove a couple of packages from the image as one of
the final steps when constructing the image (notably update-rc.d and
run-postinsts).  However, because of the order of operations, these
packages are still listed both in the buildhistory
installed_package*.txt files and in the manifest file created next to
the image, which is wrong.

There were two possible solutions to this: (1) change the order such
that the uninstallation occurs before calling ROOTFS_POSTPROCESS_COMMAND
or (2) add another hook variable in such that we can have the
package list collection code run at the right time. Because it's
currently possible (but very much not recommended) to install additional
packages within ROOTFS_POSTPROCESS_COMMAND, which may have postinstall
scripts and thus require the packages we would otherwise uninstall if we
were to take option 1, option 2 is really the least likely to cause
problems. Therefore, add ROOTFS_POSTUNINSTALL_COMMAND and make the image
and buildhistory classes use it.

Fixes [YOCTO #6479].

(From OE-Core rev: b198a189228648057c3be7d068598f50841b3bf9)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:50 +00:00
Paul Eggleton 124f0419b9 lib/oe/rootfs.py: rename _uninstall_uneeded to fix spelling error
Rename it to _uninstall_unneeded.

(From OE-Core rev: cb217f442b8143d88112bebe4011051efbd905a3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-03 14:53:50 +00:00
Richard Purdie 3f15d8a807 kernel: Fix depmod for multilib
Using populate_sysroot for this data was a nice idea but flawed as it
doesn't work in multilib builds. Instead we can use PKGDATA_DIR since
this is consistent over multilib builds. It also turns out to be
slightly neater code too. Hopefully this resolves the problem once and
for all.

(From OE-Core rev: 6cccae3ca54c1177a1d91d23c3e151d74e735ee9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-29 15:36:52 +00:00
Richard Purdie 11ef55a93b kernel/image/depmodwrapper: Fixups for depmod
With the rpm package backend enabled, running:

bitbake <image>
bitbake virtual/kernel -c clean
bitbake <image> -c rootfs -f

results in an image with incorrect kernel module dependency information.
The problem is that the System.map and kernel-abiversion files are needed
for depmod and after the recent kernel changes, these are no longer in
sstate.

Its reasonable to require the kernel to unpack/build if you're
about to build a module against it. It is not reasonable to require this
just to build a rootfs.

Therefore stash the needed files specifically for depmod.

Also fix some STAGING_KERNEL_DIR references which were incorrect, found
whilst sorting through his change.

(From OE-Core rev: b851504dcf5e147c9efb1c7b6a4d22c1a1a87cd7)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23 14:32:02 +00:00
Richard Purdie 8bab098c36 lib/oe/package: Ensure strip breaks hardlinks
Normally, strip preserves hardlinks which in the case of the way our hardlink
rather than copy functionality works, is a disadvantage and leads to non-deterministic
builds. This adds a move into place after the strip operation to ensure hardlinks
are broken and we bring back build determinism.

(From OE-Core rev: 7c0fd561bad0250a00cef63e3d787573112a59cf)

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>
2015-01-23 11:36:31 +00:00
Richard Purdie 5b985fd364 oeqa/utils/decorators: Try and improve ugly _ErrorHandler tracebacks
Currently, if one module is skipped, any other module calling skipModule
causes tracebacks about _ErrorHandler not having a _testMethodName
method.

This reworks the code in a way to avoid some of the problems by using
the id() method of the objects. It also maps to the correct name
format rather than "setupModule" or just skiping the item entirely.

(From OE-Core rev: 78d3bf2e4c88779df32b9dfbe8362dc24e9ad080)

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>
2015-01-23 11:36:29 +00:00
Pau Espin Pedrol 6f196670e8 lib/oe/sdk.py: Add SDKIMAGE_INSTALL_COMPLEMENTARY capabilities to DpkgSdk
Creating an SDK by means of do_populate_sdk, complementary packages
(SDKIMAGE_FEATURES = "dev-pkgs dbg-pkgs") are not installed when using
the deb packaging system.

The reason is that the call to install the complementary packages is missing
from the deb backend. This patch fixes that.

[YOCTO #7160]

(From OE-Core rev: 0bcca69ea97ac51acf290f8f1da1bde715ab51c4)

(From OE-Core rev: 6755935e58b0414870adb7c7abab1aa331596209)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23 11:36:25 +00:00
Richard Purdie 1dfb9033e0 lib/oe/rootfs.py: Fix reference to abiversion file location
With the changes to kernel layout, we need to refer to the correct
location of the kernel abiversion file.

Thanks to Saul, Randy, Darren and Bruce to figuring out the issue.

(From OE-Core rev: 6541799c2e9a5a1586676c207d62f885c70e24dc)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-16 23:16:15 +00:00
Lucian Musat 19399d5d29 oeqa/parselogs: Added a check in case the folder location does not contain any log files
(From OE-Core rev: affa3a126ba214f4d9b9a770e51323a6a5863bf2)

Signed-off-by: Lucian Musat <george.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-08 09:24:49 +00:00
Yi Zhao 8c9fb9dbe7 oeqa/selftest: fix test_incremental_image_generation for changes in log output
test_incremental_image_generation case failed because the log output
chanaged:

FAIL: test_incremental_image_generation (oeqa.selftest.buildoptions.ImageOptionsTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File
  "/buildarea3/yzhao1/poky-build/meta/lib/oeqa/utils/decorators.py", line 90, in wrapped_f
    return func(*args)
  File
  "/buildarea3/yzhao1/poky-build/meta/lib/oeqa/selftest/buildoptions.py", line 25, in test_incremental_image_generation
    self.assertEqual(0, res.status, msg="No match for openssh-sshd in log.do_rootfs")
AssertionError: 0 != 1 : No match for openssh-sshd in log.do_rootfs
----------------------------------------------------------------------

Using re search instead grep

(From OE-Core rev: 1872a9430cec0c61f1ec349df198160addd430de)

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31 17:04:46 +00:00
Richard Purdie 4477069b64 oeqa/parselogs: Add harmless failure warning introduced by new qemu version on qemuppc
(From OE-Core rev: d9f49e0e6b377c402e01de631edca73bb6537ab9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31 17:04:43 +00:00
Paul Eggleton 93ba8e0f91 oeqa/selftest: fix test_force_task so it doesn't taint the entire build
Using -C sets a taint on the specified task, and m4-native is in the
dependency chain for just about everything, which means that everything
gets forced to rebuild. We don't need the influence of this test to
extend outside of the test itself, so ensure that the taint gets cleared
at the end of the test.

(From OE-Core rev: 24b41a1e3f2496e38a6ae9c47dfe85887f3d7d6e)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:13 +00:00
Paul Eggleton 5268d8ab1d oeqa/selftest: populate pkgdata/shlibs in test_recipetool_create_git
Build some recipes so that we have the needed data in the sysroot for
recipetool to refer to when scanning for dependencies.

(From OE-Core rev: 67bf1dac68d76c7e6a4d95e5bdd1eba468331f01)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:13 +00:00
Paul Eggleton 9c93079795 oeqa/selftest: improve failure messages for devtool tests
assertTrue prints "False is not True" if it fails, which is pretty much
useless. Use a more appropriate assertion test where practical and add a
message where it isn't.

(From OE-Core rev: 0e0dd2575bb2a1b6f6c5eba1f8cfb0d81cc1b091)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:13 +00:00
Paul Eggleton 41f3dd1d33 oeqa/selftest: skip test_incremental_image_generation if not using rpm
We have just implemented incremental ipk image generation, but at the
moment this test doesn't support that, so skip it if not using rpm.

(From OE-Core rev: e920c1a62705524be71dc5f9e4527b396ca83dca)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:12 +00:00
Paul Eggleton 8bb5dccedb oeqa/selftest: fix test_event_handler for changes in bitbake output
(From OE-Core rev: 3b3c6aa09301c0c19e7fc8720cd3d1b036c5b103)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:12 +00:00
Paul Eggleton 7d9b5fb69a oeqa/utils: fix testcase decorator to allow calling tests individually
Without this, running tests individually failed with a traceback:

$ oe-selftest --run-test
buildoptions.ImageOptionsTests.test_incremental_image_generation
2014-12-23 14:40:37,636 - selftest - INFO - Checking that everything is in order before running the tests
2014-12-23 14:40:38,408 - selftest - INFO - Running bitbake -p
2014-12-23 14:40:40,235 - selftest - INFO - Loading tests from:
oeqa.selftest.buildoptions.ImageOptionsTests.test_incremental_image_generation
Traceback (most recent call last):
  File "/home/user/poky/scripts/oe-selftest", line 179, in <module>
    ret = main()
  File "/home/user/poky/scripts/oe-selftest", line 164, in main
    suite.addTests(loader.loadTestsFromName(test))
  File "/usr/lib64/python2.7/unittest/loader.py", line 91, in loadTestsFromName
    module = __import__('.'.join(parts_copy))
  File "/home/user/poky/meta/lib/oeqa/selftest/buildoptions.py", line 12, in <module>
    class ImageOptionsTests(oeSelfTest):
  File "/home/user/poky/meta/lib/oeqa/selftest/buildoptions.py", line 14, in ImageOptionsTests
    @testcase(761)
NameError: global name 'func' is not defined

(From OE-Core rev: 8e3fbb0bb2c0eabfb39752c25e7c3f5d77881f64)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:12 +00:00
Paul Eggleton d4d73b0139 oeqa/utils: replace some tabs with spaces
Python code should use spaces only for indentation.

(From OE-Core rev: a1e22121e521aabf454a850cd7c8be60b7b1adc3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25 08:27:12 +00:00