Commit Graph

458 Commits

Author SHA1 Message Date
Ed Bartosh cc0a0614e8 package_manager.py: enable smart non-interactive mode
Added --quiet option to smart command line.
Without this option smart 1.4.1 turns into interactive mode, i.e.
start asking questions and expecting answers.

Internally within smart, this changes the default UI to one which
just prints to stderr, the naming of the parameter is a little
odd but does what we need.

(From OE-Core rev: 7a8d88b73d35ac86198a1092c49b33c378416a03)

Signed-off-by: Ed Bartosh <eduard.bartosh@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-31 23:40:47 +01:00
Peter Kjellerstedt 3b47aa11c2 lib/oe/utils: Make multiprocess_exec() return anything
The variable "results" was accidentally used for multiple different
things at the same time, which unintentionally discarded anything that
was supposed to be returned from the function...

(From OE-Core rev: abf4eb613eba0892a5f240de7aa3a9a1b2879354)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-29 23:44:37 +01:00
Richard Purdie 91375aff99 oeqa: xorg log test is being replaced by parselogs so remove
Now we have the parselogs test, this one can be removed.

(From OE-Core rev: 7977a3c28677d9a248059b0be230f345227e798a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-29 23:44:37 +01:00
Richard Purdie 09296cd292 oeqa/pasrselogs: Improve the machine/string whitelist
Currently the whitelist is imcomplete, inaccurate and suffers duplication.

These changes:
 * Add common groups of errors
 * Change to make the default whitelist clear
 * Correctly (or at least better) escape the regexp expressions
 * Add in missing machines to allow builds on the autobuilder to suceed

(From OE-Core rev: 620aa5f9022335a9166b4d47bdcdce611ff5466a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-29 23:44:37 +01:00
Lucian Musat c730c94a21 oeqa/runtime: Automatic test for parsing the logs on a machine and search for certain error keywords.
This adds a common new qa test for general processing of log files. One
significant improvement is machine dependent ignore filters.

This can be used to replace several weaker individual QA tests
that are currently used.

(From OE-Core rev: a14d076a401397b6773d5d1b99e49126261f1eb4)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-29 23:44:37 +01:00
Corneliu Stoicescu 61e3e41ad2 oeqa/sdk/buildsudoku.py: add setUpModule method to run only when gtk+ in installed.
Adding setUpModule in order to skip the module when gtk+ is not installed in the toolchain.

(From OE-Core rev: 97ac0fc33b9277825089ac36f9037d472d397b71)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-27 12:12:31 +01:00
Corneliu Stoicescu e2b4dde94c oeqa/oetest.py: enable sdk tests to use hasFeature and hasPackage methods.
In order to use the hasFeature and hasPackage methods, we need to make oeSDKTest extend oeTest and also set the test context (tc) attribute in the oeTest class when loading the tests.

(From OE-Core rev: 54436aeed5ac5e0da0779919f8524a0603e19c6a)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-27 12:12:31 +01:00
Richard Purdie c490ba0a93 sstatesig: Only squash dependencies for allarch packagegroups
The idea of squashing packagegroup dependencies was to avoid allarch
packages rebuilding upon tune/arch changes. Now that the allarch class
inclusion is conditional, we can narrow down the packagegroup squashing
to be specifically applied to allarch recipes.

(From OE-Core rev: bd8018792155ae842952432900c8431feeaffe30)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-25 08:57:44 +01:00
Richard Purdie be1b198076 lib/oe/utils: Add utils function for multiprocess execution
Our usage of multitprocessing is problematic. In particular, there is a bug
in python 2.7 multiprocessing where signals are not handled until command
completion instead of immediately.

This factors the multiprocess code into a function which is enhanced with
a workaround to ensure immediate signal handling and also better SIGINT
handling which should happen in the parent, not the children to ensure
clean exits. The workaround for the signals is being added to the core
bb.utils function so it can benefit all users.

package_manager is then converted to use the new code.

(From OE-Core rev: 72d153a3a90d31d9f4e41d77da24e44ccb33c56e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-23 09:31:41 +01:00
Richard Purdie f4786027ba oeqa/utils/httpserver: Reset SIGTERM handler
With bitbake-worker installing a SIGTERM handler, we now need to reset the one here
to ensure that when this process shuts down, it doesn't take the rest of the task
with it. This does appear to be the only place in OE that we have this problem.

(From OE-Core rev: e1ac67d6470dde70239ca0430b18ca0bffbc0295)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-23 09:31:41 +01:00
Corneliu Stoicescu abb7f5bbcc oeqa/sdk/: add sdk tests for sudoku, iptables and cvs
Add test modules for sdk tests.

NOTE: Original patch made by: Richard Purdie <richard.purdie@linuxfoundation.org>

(From OE-Core rev: 1b18a33b1053902faaa5cb242d4c1c7d1fb6b064)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-18 08:55:54 +01:00
Corneliu Stoicescu fec293be3a oeqa/utils/targetbuild.py: add support for sdk tests
- Create new abstract class BuildProject that provides basic functionality for a project/package building class
        * contains abstract method _run() that needs to be implemented by all extending classes.
- The old TargetBuildProject class now extends the abstract BuildProjct class
- Introducing new SDKBuildProject that extends the abstract BuildProjct class

NOTE: Original patch made by: Richard Purdie <richard.purdie@linuxfoundation.org>

(From OE-Core rev: bc8824fd361dbff96f5b5316ddfda36e96e8ea9b)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-18 08:55:54 +01:00
Corneliu Stoicescu 2999a7f684 oeqa/oetest.py: enable sdk testing
- add support for sdk tests in the loadTests and runTests methods
- add new oeSDKTest test object

NOTE: Original patch made by: Richard Purdie <richard.purdie@linuxfoundation.org>

(From OE-Core rev: 6c147e5c82b39773e135ca828b37905cbb31be3b)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-18 08:55:54 +01:00
Christopher Larson d7fea14b1f oe.package_manager: fix use of PACKAGE_EXCLUDE for dpkg
It was iterating over the variable character-by-character rather than
word-by-word.

(From OE-Core rev: 207f2cc0b0fc53b22e1dedfa26905ab143fb0de6)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-11 17:43:44 +01:00
Corneliu Stoicescu fe5b333e1a oeqa/runtime: add new cpp test and file
This tests out the limits header which we've noticed does have problems in
some SDK builds.

(From OE-Core rev: 63cbed337241191f33fe951662a39ce59dce6774)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-11 12:30:52 +01:00
Tyler Hall 92785a1a96 lib/oeqa/selftest: Don't match log level in output
To facilitate changing the log level of the "Fetcher failure" message,
search only for the message without the "Error:" prefix.

(From OE-Core rev: 947e6f9005abc71f499f23a4dd3a5a9f8386a369)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-11 12:30:52 +01:00
Robert Yang a9c8767a17 package_manager.py: set preferred ABI for rpm
When using the RPM packaging backend to generate a rootfs there needs to
be a way to configure the preferred ABI to resolve ELF file conflicts.

Currently RPM resolves ELF file conflicts with the last-installed wins.
Using SMART it's difficult to know what the last installed will be.

There are three specific policies that can be selected:
1: ELF32 wins
2: ELF64 wins
3: ELF64 N32 wins (mips64 or mips64el only)

Another option "0" is uncontrollable, which means that if two are being
installed at once Elf64 is preferred, but if they're being installed in
two different transactions, last in wins, so we don't document it.

Add RPM_PREFER_COLOR to let the user config the preferred ABI.

[YOCTO #4073]

(From OE-Core rev: f56d7be2c35cedcd763ba66913982aa4c425d561)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-02 09:26:16 +01:00
Corneliu Stoicescu c02d6b4c8d oeqa/utils/decorators.py: add import os
An 'import os' was omitted here while testing the previous decorators using runtime tests that import the os module before this one. Unfortunately oe-selftest fails because of this missing import.

(From OE-Core rev: 5381e6cf6bf7143074800b2949bfa5331fdb6d47)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-02 09:26:15 +01:00
Corneliu Stoicescu d738109415 selftest/buildoptions.py: fix QA_WARN test and add more output when failing
The -ccleansstate should be done before building the package for the second time.
Also printing the command output when failing.

(From OE-Core rev: 15e5661d6341004ebc4d3492acb48f73dd86b96e)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-29 09:58:27 +01:00
Richard Purdie addeef1dc9 lib/oe/rootfs: Improve error message whitespace
[YOCTO #6493]

(From OE-Core rev: 91ca6b1b2e009381d8e813906654c0958eee7efc)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-28 12:21:24 +01:00
Richard Purdie 14a7cde49f lib/oeqa: Fix accidental revert of code
(From OE-Core rev: 188545ba82119d75f80dde322a73712ce1f0f762)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-25 17:29:23 +01:00
Lucian Musat 8e26ab7d52 oeqa/rutime: Added testcase decorators for automated runtime tests. Also added LogResults decorator for oeTest class in oetest.py
(From OE-Core rev: 95b83084487d0712362ade8ac487999c3274bb96)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-25 16:54:42 +01:00
Lucian Musat 984f03457a oeqa/runtime: Added skipModule import for test modules that use it.
The modules that use skipModule should import it themselves and not rely on somebody else to import it.

(From OE-Core rev: 6a14db407d471e717f41342ac0700e6a383c32c3)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-25 15:34:00 +01:00
Lucian Musat 0c4dd0ad16 oeqa: Refactor test skipping decorators to use the unittest result object
In order to make the test skipping decorators independent of the oeTest object we rely on the unittest result object to construct skip, fail and error lists used by these decorators.
Created a new object getResults that analyses upper frames and retrieves the unittest result object instance, then return a list of failed, skipped and error tests.
Also removed the oetest import from decorators.py because it was no longer required.

(From OE-Core rev: 4d2d201158236bd4c72546cf8db88681ff921b11)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-25 15:34:00 +01:00
Richard Purdie 42470aa22d lib/oe/classextend: Avoid early expansion of PR values
Variables like RDEPENDS can contain EXTENDPKGV which in turn uses AUTOPR
based values. This gets set during do_package execution so we want to
defer expansion until then. The only way we can do this in the RDEPENDS
(and friends) mapping code is to subsitute a dummy value, then change it
back again. Horrible but I can't see any other way.

This resolves multilib build failures with inconsistent PR values.

(From OE-Core rev: 5aea553e6eaa3b9647f26944976d2a9da79cba42)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-25 15:33:58 +01:00
Roxana Ciobanu 56bfda20f4 image.bbclass/rootfs.py: add variables to rootfs[vardeps]
Added base variables and package backend specific variables to
rootfs[vardeps] in order for rootfs to rebuild when changes are made.

Set some variables as [func] to inform bitbake that they are shell
scripts, so that it invokes its shell dependency parsing. Without
marking them as functions, changes in the actual function body would
not trigger rootfs rebuilds.

[YOCTO #6502]

(From OE-Core rev: b8b6214b885a0757f0e628937f8fe21c92c45155)

Signed-off-by: Roxana Ciobanu <roxana.ciobanu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-23 21:59:13 +01:00
Saul Wold 4d2ac6f6df rootfs: Remove the extraneous install directory
The /install/tmp diectory is created during installation by
the smart package manager, we need to clean it up here

[YOCTO #6497]

(From OE-Core rev: d4f4ad5edd8914e696722c1a1c3ba7de091d4c19)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-19 00:18:21 +01:00
Lucian Musat 929e48e0af oeqs/selftest: Added test case decorators for toaster
(From OE-Core rev: 87ded649257e963e45d629679d44376d9a993ecd)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-17 12:37:00 +01:00
Chen Qi 14735be703 oeqa: fix return status in pam.py to match shadow-4.2.1
The return statuses of commands like `su --help' or `passwd --help'
in shadow 4.2.1 version are different from those in shadow 4.1.4.3
version.

Now that we've upgraded shadow to 4.2.1, we need to fix these statuses
in the pam.py to make things work as expected.

(From OE-Core rev: 6bc53438735690866358194dd9e88fa1d7435e2c)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-17 12:36:19 +01:00
Robert Yang 1cb9f7b00b lib/oe/image.py: check the rootfs size against IMAGE_ROOTFS_MAXSIZE
* Check the rootfs size against IMAGE_ROOTFS_MAXSIZE (if set)
* Add comments for IMAGE_ROOTFS_SIZE to not confuse with IMAGE_ROOTFS_MAXSIZE

[YOCTO #2610]

(From OE-Core rev: 6acd4fc8d5e642b5c6c75fcc40dd8f37caf7ddcf)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-10 17:38:35 +01:00
Lucian Musat d8364371b2 oeqs/selftest: Added test case decorators for the rest of selftest testcases except toaster
(From OE-Core rev: 3c820db4624a062644a26de1866123a10a78a006)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-10 17:38:35 +01:00
Lucian Musat ae03111791 Added testcase decorator to use in logging. Added class decorator LogResults that outputs test results in separate log file.
(From OE-Core rev: 7e2b73f1ccfe2968ef780fef2edfaa31c3dae853)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-03 17:41:17 +01:00
Mark Hatle 2c59db6318 lib/oe/package_manager.py: Fix _pkg_translate_smart_to_oe function
File: '/home/mhatle/git/oss/oe-core/meta/lib/oe/package_manager.py', lineno: 278, function: _pkg_translate_smart_to_oe
     0274:
     0275:            if found == 1 and fixed_arch == fixed_cmp_arch:
     0276:                break
     0277:        #bb.note('%s, %s -> %s, %s' % (pkg, arch, new_pkg, new_arch))
 *** 0278:        return new_pkg, new_arch
     0279:
     0280:    def _list_pkg_deps(self):
     0281:        cmd = [bb.utils.which(os.getenv('PATH'), "rpmresolve"),
     0282:               "-t", self.image_rpmlib]
Exception: UnboundLocalError: local variable 'new_arch' referenced before assignment

(From OE-Core rev: acd8bfc9378df0a2e1d6ea3858675b9fe350946d)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-03 17:41:17 +01:00
Ionut Chisanovici 9e1c86921c oeqa/selftest/_toaster.py: fix 'IndentationError' issues
There were some indentation errors when the _toaster.py was merged into master.
This patch fix those errors.

(From OE-Core rev: 173194493294574e49874858ee7003000f41b4d6)

Signed-off-by: Ionut Chisanovici <ionutx.chisanovici@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-30 10:32:51 +01:00
Ionut Chisanovici 676c1f5c67 oeqa/selftest/toaster.py: renamed to _toaster.py
In order not to run the toaster selftests by default, we renamed to _toaster.py

(From OE-Core rev: 8da2ebba10e0128938919b39c29be40b7c1d80aa)

Signed-off-by: Ionut Chisanovici <ionutx.chisanovici@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-30 10:32:51 +01:00
Mark Hatle 94dbe8515d lib/oe/package_manager.py: Add processing for alternative SDK_OS
For the meta-mingw layer, we need to process alternative SDK_OS, since this
is not a Linux based OS.

(From OE-Core rev: b31e015d2e379c24610948d345c5970545887468)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-25 13:51:47 +01:00
Mark Hatle d9cdeac6d7 populate_sdk: Fix TOOLCHAIN_TARGET_TASK_ATTEMPTONLY implementation
The variable was only partially implemented, and the part that was there
was named incorrectly to, missing the 'TASK' piece.

(From OE-Core rev: d0cb34cfe9a51fd8bc1e6e28c8eda60a25adc1ec)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-25 13:51:47 +01:00
Corneliu Stoicescu 7b453165ab oeqa/targetcontrol.py: Separate the matching of supported image fstypes from the resulting value check.
Because we used a bb.fatal call inside the get_image_fstype classmethod, this caused problems when accessed without instantiating the object with a valid bb environment.

Separating the matching part of the classmethod(that is usable by outside scripts) from the check of the resulting value.
The matching is done within a new classmethod and the latter keeps the old method name and internal functionality, this way we don't have to change any other target controllers code.

(From OE-Core rev: 50ddd5d0149666ad60133d8eb6cc789c5b97e5e4)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-24 19:54:10 +01:00
Richard Purdie 3df8773ed9 sstatesig: Add try/except around the stat calls
Its possible sstate symlinks to other sstate mirrors which then my get
removed/cleaned. If we find invalid symlinks, skip over them rather
than error with a backtrace.

(From OE-Core rev: 5ed9bb42abf93aa084dd23ca68cc996a94a51a10)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-19 17:55:11 +01:00
Corneliu Stoicescu 5456f0e58e controllers/masterimage.py: Make testimage kernel naming pattern universal
YB: #6254

The QemuTargetControl class does not specify any kernel naming but the runqemu script it uses uses the " KERNEL_IMAGETYPE + MACHINE + '.bin' " naming scheme.
Modifying the other major target controller class, MasterImageHardwareTarget, to use the same kernel naming scheme.

This is usefull also to outside scripts that want to anticipate the kernel file name for all target controllers.

(From OE-Core rev: e8666e91a9633da6a560d5a9510bb53d0251b16d)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:52:21 +01:00
Corneliu Stoicescu 4bc02066c0 oeqa/controllers/testtargetloader.py: add 'import os'
YB: #6254

This module uses os but relies on other modules to import it. Adding 'import os' in order to be self-sustained.

(From OE-Core rev: 26e4d5212ec5b2bcfdb0f42bbed31f468a17aca4)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:52:21 +01:00
Corneliu Stoicescu a5aa889d63 targetcontrol.py: Add a classmethod to get extra files needed by the target controllers
YB: #6254

Add a new classmethod that can be used by outside scripts to get the extra files needed by the target controllers.
An outside script can predict rootfs, manifest and kernel files needed by a target controller, but sometimes there are other files needed.

(From OE-Core rev: fea627022473cfb73299d0988628962ad8e80f89)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:52:21 +01:00
Corneliu Stoicescu 41d300067b masterimage.py: enable dynamical determination of rootfs type
YB: #6375

Adding support for get_image_fstype() in the MasterImageHardwareTarget and GummibootTarget classes.

(From OE-Core rev: 06ed50a2b8c311e56ac9f1c6f2145bc020d5d500)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:52:20 +01:00
Corneliu Stoicescu af38422017 targetcontrol.py: make possible dynamical determination of rootfs type
YB: #6375

Added a new method get_image_fstype() that autodetermines what fstype to use for the rootfs file.
This method uses a new list variable 'supported_image_fstypes' that contains image fstypes supported by the target controller.

This method is also a classmethod which means outside scripts can get the image fstype.

(From OE-Core rev: 39d5aa5c9f2916700f81d15adc220a30c6b120d1)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:52:20 +01:00
Chen Qi 51d450f0a7 rootfs.py: change the logic in _uninstall_unneeded
Previously, if we have 'package-management' and 'read-only-rootfs'
both in IMAGE_FEATRUES, we would meet the following error at system
start-up.

	rm: can't remove '/etc/rcS.d/S99run-postinsts': Read-only file system

However, what's really expected is that when there's no postinstall
script at system start-up, the /etc/rcS.d/S99run-postinsts should not
even be there.

Whether or not to remove the init script symlinks to run-postinsts should
not depend on whether we have 'package-management' in IMAGE_FEATURES; rather,
it should only depend on whether we have any postinstall script left to run
at system start-up.

This patch changes the _uninstall_unneeded function based on the logic
stated above.

[YOCTO #6257]

(From OE-Core rev: 6c2f7ecee754ff3f29fdde17c0363f5d138057ff)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-13 12:31:37 +01:00
Corneliu Stoicescu a934aebcb8 oeqa/utils/commands.py: add support for postconfig option
Adding support for postconfig option to the bitbake() and related methods.

This enables us to use 'bitbake -R postconfig_file <command>'.

Usage: bitbake(cmd, postconfig="some confguration")

'postconfig_file' would contain what we add in 'postconfig'

Other methods affected: get_bb_env(), get_bb_var()

(From OE-Core rev: 4fe771940a8f59a0d5f1541978d6d9ff73b222f4)

Signed-off-by: Corneliu Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-10 17:24:17 +01:00
Lucian Musat 7279de72c6 Added new test cases for bitbake modes (-e -n -p -r -R -c -k)
(From OE-Core rev: eec4976e3b22efe73e823ad4876d78ad933113f4)

Signed-off-by: Lucian Musat <georgex.l.musat@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-06 09:26:04 +01:00
Richard Purdie 3caca17be1 classextend: Fix crosssdk remapping for multilib
Multilib builds only require one crosssdk toolchain. We therefore shouldn't
be remapping crosssdk names. This resolves build failures looking for
weird multilib crosssdk toolchains.

(From OE-Core rev: aa8b93e2db06866529d20939452f81fb9e18aaab)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-01 14:29:30 +01:00
Ionut Chisanovici 6c62836d65 toaster: toaster oe-selftest support
This patch adds toaster tests using the oe-selftest infrastructure.
You need to have builds done - the tests will verify data integrity
after the toaster collection phase.

Once you have your toaster builds done, to run the automated backend
tests via oe-selftest do the followings:

1. Update builddir/conf/bblayers.conf to contain the meta-selftest
layer
2. From the builddir run:

'oe-selftest toaster'

or if you just want to run a single test:

'oe-selftest toaster.Toaster_DB_Tests.testname'

This first part adds the meta/lib/oeqa toaster file.

(From OE-Core rev: 762d425ed6f6d9046d3e3230c44b42ea6173b447)

Signed-off-by: Ionut Chisanovici <ionutx.chisanovici@intel.com>
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-05-30 10:20:24 +01:00
Richard Purdie 963c8ea99d sstatesig: Move saferecipedeps handling to be earlier
We want to use the saferecipedeps handling code to allow gcc-cross-* to
work on multiple different tunes. Its currently in target only code
so it needs to be earlier to allow it to work on native-> target
dependencies.

This change has no effect on existing uses but makes gcc-cross become
shared as desired.

(From OE-Core rev: 9e03db2dfab0b534b86fd48c9190b2d7d0d21238)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-05-29 17:53:40 +01:00