aboutsummaryrefslogtreecommitdiffstats
path: root/meta/lib
AgeCommit message (Collapse)Author
2015-02-26lib/oe/terminal: fix konsole terminal support for KDE 4.xPaul Eggleton
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]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-26lib/oe/terminal: fix regressionsPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-24terminal.py: No --disable-factory for gnome-terminal >= 3.10Sven Ebenfeld
--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. Signed-off-by: Sven Ebenfeld <sven.ebenfeld@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23copy_buildsystem.py: Add methods to copy shared state.Randy Witt
Added the helper functions necessary to copy the sstate from the current build, and generate the file to "lock" it. 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-23copy_buildsystem.py: Add a way to copy buildsystem to a directory.Randy Witt
This file provides a way to take bitbake and the layers in the current build and copy them to a target specified. 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-23sstatesig: Add ability to filter list of tasks for locked-sigs.incPaul Eggleton
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23devtool: fix broken clones of git recipesPaul Eggleton
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.) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23devtool: update-recipe: add handling for git recipesPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23lib/oe/recipeutils: minor improvements to patch_recipe()Paul Eggleton
* Ensure it knows where to put SRCREV and S * Handle prepend/append and functions in general Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23devtool: build: run do_populate_sysroot instead of do_installPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23devtool: reset: run bitbake -c clean on recipePaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-23lib/oe/patch: fix PATCHTOOL = "git" with source in a subdirectoryPaul Eggleton
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}. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21machine/qemu: Switch from ext3 to ext4Richard Purdie
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). Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21lib/oeqa/selftest/bblayers: use dashed subcommandsPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21lib/oe/package_manager: Performance tweak in regex usageRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-21oeqa/parselogs: Add exception for new mips error messageRichard Purdie
The 3.19 kernel introduces this error, ignore it for now. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-19oeqa/ptest: Fixed complementary package install detection and added ↵Lucian Musat
ptest-runner exit code check Signed-off-by: Lucian Musat <george.l.musat@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-17package_manager.py: use 'purge' instead of 'remove' in case of debChen Qi
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. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-17lib/oe/package_manager: support exclusion from complementary glob process by ↵Paul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-02-15oeqa/ptest: Removed buildhistory as requirement for ptestLucian Musat
Signed-off-by: Lucian Musat <george.l.musat@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-14oeqa/smart: Added some new test casesLucian Musat
Signed-off-by: Lucian Musat <george.l.musat@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-14oe-pkgdata-util: add some QA testsPaul Eggleton
Test each of the subcommands that this utility provides. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2015-02-14oe-pkgdata-util: improve command-line usagePaul Eggleton
* 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 Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2015-02-14lib/oe/lsb.py: Fix up for dashSaul Wold
Remove the leading -e when using dash which does not use -e with echo Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-14rootfs.py: ignore "NOTE:" when catching warningsRicardo Neri
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:" Signed-off-by: Ricardo Neri <ricardo.neri-calderon@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-07terminal.py: add tmux new window optionDan McGregor
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. Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-07classes/license: tweak license format messagesPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-03lib/oe/terminal: add support for Terminology terminal emulatorRodrigo Chiossi
Terminology is the default Enlightenment terminal emulator Signed-off-by: Rodrigo Chiossi <rodrigo.chiossi@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-03package_manager.py: fix rootfs failure with multilib enabledChen Qi
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. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-03terminal.py: fixes launching multiple windows of gnome-terminalAlejandro Hernandez
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] Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-03image.bbclass: make kernel depmod data optionalDan McGregor
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. Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-02-03lib/oe/image.py: add error checking for missing IMAGE_CMDPaul Eggleton
An invalid value in IMAGE_FSTYPES was triggering a traceback. Add a check and a reasonable error message instead. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2015-02-03classes/image: ensure uninstalled packages do not appear in manifestsPaul Eggleton
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]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2015-02-03lib/oe/rootfs.py: rename _uninstall_uneeded to fix spelling errorPaul Eggleton
Rename it to _uninstall_unneeded. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2015-01-29kernel: Fix depmod for multilibRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23kernel/image/depmodwrapper: Fixups for depmodRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23lib/oe/package: Ensure strip breaks hardlinksRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-01-23oeqa/utils/decorators: Try and improve ugly _ErrorHandler tracebacksRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-01-23lib/oe/sdk.py: Add SDKIMAGE_INSTALL_COMPLEMENTARY capabilities to DpkgSdkPau Espin Pedrol
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) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-16lib/oe/rootfs.py: Fix reference to abiversion file locationRichard Purdie
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. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-07oeqa/parselogs: Added a check in case the folder location does not contain ↵Lucian Musat
any log files Signed-off-by: Lucian Musat <george.l.musat@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31oeqa/selftest: fix test_incremental_image_generation for changes in log outputYi Zhao
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 Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-31oeqa/parselogs: Add harmless failure warning introduced by new qemu version ↵Richard Purdie
on qemuppc Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-25oeqa/selftest: fix test_force_task so it doesn't taint the entire buildPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/selftest: populate pkgdata/shlibs in test_recipetool_create_gitPaul Eggleton
Build some recipes so that we have the needed data in the sysroot for recipetool to refer to when scanning for dependencies. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/selftest: improve failure messages for devtool testsPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/selftest: skip test_incremental_image_generation if not using rpmPaul Eggleton
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. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/selftest: fix test_event_handler for changes in bitbake outputPaul Eggleton
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/utils: fix testcase decorator to allow calling tests individuallyPaul Eggleton
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 Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-12-25oeqa/utils: replace some tabs with spacesPaul Eggleton
Python code should use spaces only for indentation. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>