summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/utils/buildproject.py
Commit message (Collapse)AuthorAgeFilesLines
* meta/lib+scripts: Convert to SPDX license headersRichard Purdie2019-06-181-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | This adds SPDX license headers in place of the wide assortment of things currently in our script headers. We default to GPL-2.0-only except for the oeqa code where it was clearly submitted and marked as MIT on the most part or some scripts which had the "or later" GPL versioning. The patch also drops other obsolete bits of file headers where they were encoountered such as editor modelines, obsolete maintainer information or the phrase "All rights reserved" which is now obsolete and not required in copyright headers (in this case its actually confusing for licensing as all rights were not reserved). More work is needed for OE-Core but this takes care of the bulk of the scripts and meta/lib directories. The top level LICENSE files are tweaked to match the new structure and the SPDX naming. (From OE-Core rev: 3248a9e3c5a197321b1c4417509b9309cc3bae97) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa: don't litter /tmp with temporary directoriesRoss Burton2018-12-051-1/+2
| | | | | | | | | | | | | | If we need to create a temporary directory in targetbuild or buildproject use tempfile.TemporaryDirectory so that when the test case is finished, the directory is deleted. Also synchronise the logic and don't possibly store the temporary directory in self.tmpdir as nothing uses that. (From OE-Core rev: db0e658097130d146752785d0d45f46a3e0bad71) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/utils/buildproject: Only clean files if we've done somethingRichard Purdie2018-11-141-0/+5
| | | | | | | | | We should only be wiping out things on target if the tests have actually run. (From OE-Core rev: d38c3eac0a5a1a9b0eb98385832e92f48145655e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: Fix return value checks from subprocess.call()'sMikko Rapeli2017-06-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Python function subprocess.call() returns the return value of the executed process. If return values are not checked, errors may go unnoticed and bad things can happen. Change all callers of subprocess.call() which do not check for the return value to use subprocess.check_call() which raises CalledProcessError if the subprocess returns with non-zero value. https://docs.python.org/2/library/subprocess.html#using-the-subprocess-module All users of the function were found with: $ git grep "subprocess\.call" | \ egrep -v 'if.*subprocess\.call|=\ +subprocess\.call|return.*subprocess\.call' Tested similar patch on top of yocto jethro. Only compile tested core-image-minimal on poky master branch. (From OE-Core rev: 578c8205fd14c48c6d30ef2889d86f1b4aee060a) Signed-off-by: Mikko Rapeli <mikko.rapeli@bmw.de> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/utils/buildproject: create a more unique tmp dirJoshua Lock2017-04-061-2/+5
| | | | | | | | | | Rather than hardcoding /tmp as the default tmpdir make a more unique tmpdir with tempfile.mkdtemp() when the caller doesn't specify a tmpdir value. (From OE-Core rev: 9425c2658fea0b45468a04574cd77bffc6668a8d) Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/buildproject: Run gnu-configize by defaultRichard Purdie2017-02-051-1/+1
| | | | | | | | | | | | The runtime oeqa tests were failing in the on-target case, only for aarch64. This was because an old config.sub was being used. Similar to the SDK testing, call gnu-configize in the on-target case too to resolve the failing tests. (From OE-Core rev: 7918fe08d8e48f46cf2402afa66d35063eb72545) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes/oeqa: Replace subprocess.check_call() with check_output()Richard Purdie2017-01-231-1/+1
| | | | | | | | | | If you use subprocess.check_output() the traceback will contain the output when the command fails which is very useful for debugging. There is no good reason not to use this everywhere. (From OE-Core rev: ad750dd1cc9d789abe723daddd098ce41d8547f5) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/utils: {Target,SDK,}BuildProject remove dependency of bbAníbal Limón2017-01-231-24/+7
| | | | | | | | | | | | | | | | | | | Don't use bitbake references inside utils modules, in order todo that changes getVar calls for arguments in the __init__ method like dl_dir for all the classes and testlogdir, builddatetime in SDKBUildProject. Also don't export proxies inside _download_archive method, a good practice is to setup the proxies at init of the process instead of do it in this helper module. [YOCTO #10231] [YOCTO #10599] (From OE-Core rev: 581c34d1efe9839f50ef322761269b4e4d8a56a6) Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/utils: Move targetbuild to buildproject moduleAníbal Limón2017-01-231-0/+69
The new buildproject module will contain only BuildProject class a helper class for build source code. The remaining classes TargetBuildProject and SDKBuildProject was move to runtime and sdk respectively. [YOCTO #10599] (From OE-Core rev: 525fd2a5cda00890e921b63f7f608a10bc024d73) Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>