aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2016-11-23OpenSSL: CVE-2004-2761 replace MD5 hash algorithmT.O. Radzy Radzykewycz
Use SHA256 as default digest for OpenSSL instead of MD5. CVE: CVE-2004-2761 The MD5 Message-Digest Algorithm is not collision resistant, which makes it easier for context-dependent attackers to conduct spoofing attacks, as demonstrated by attacks on the use of MD5 in the signature algorithm of an X.509 certificate. Upstream-Status: Backport Backport from OpenSSL 2.0 to OpenSSL 1.0.2 Commit f8547f62c212837dbf44fb7e2755e5774a59a57b Reviewed-by: Viktor Dukhovni <viktor@openssl.org> Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com> Signed-off-by: T.O. Radzy Radzykewycz <radzy@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23lib/oe/lsb: better handle missing fieldsJoshua Lock
Some rolling release distros, such as Arch Linux, don't include a VERSION_ID field in their os-release file. Change release_dict_osr() to better handle this optional field being absent. Further improve the resilience of the release_dict_*() methods by always returning a dict and using dict.get() in distro_identifier() to supply a default, empty string, value when then key is missing. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23scripts: Specify the stats to take into accountLeonardo Sandoval
There are many more stats on buildstats that 'Elapsed time', so make the script more flexible to support all stats. Some cmd line examples: $ buildstats.sh -s 'utime' Buildstats' data covers proc's stats in different areas, including CPU times, IO, program system resources and child program system resources. In order to print values on each of these sets from command line, one can use the following: $ buildstats.sh -H -s 'TIME' | less $ buildstats.sh -H -s 'IO' | less and 'RUSAGE' and 'CHILD_RUSAGE' for program and program's child system resources. Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23buildstats: Place 'Elapsed Time' stat into a single lineLeonardo Sandoval
All lines except one (the one containing the 'Elapsed Time') follows the format 'stat: value'. Fix that so post parsing the stats is simpler. Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23devtool: modify: support recipes with only local files as sourcePaul Eggleton
The hello-mod recipe is unusual in that it has only local files in SRC_URI and builds these out of ${WORKDIR}. When you use devtool modify on it, devtool puts all of those files in an "oe-local-files" subdirectory of the source tree, which is not ${S} (or ${B}) any more and thus building the recipe afterwards fails. It's a bit of a hack, but symlink the files in oe-local-files into the source tree (and commit the symlinks with an ignored commit so that the repo is clean) to work around the problem. We only do this at time of extraction, so any files added to or removed from oe-local-files after that won't be handled, but I think there's a limit to how far we should go to support these kinds of recipes - ultimately they are anomalies. I initially tried a hacky workaround where I set effectively set B = "${WORKDIR}" and that allowed it to build, but other things such as the LIC_FILES_CHKSUM checks still broke because they expected to find files in ${S}. Another hack where I set the sourcetree to point to the oe-local-files subdirectory works for hello-mod but not for makedevs since whilst that is similar, unlike hello-mod it does in fact have files in the source tree (since it has a patch that adds COPYING) and thus the same issue occurred. Also tweak one of the tests that tries devtool modify / update-recipe on the makedevs recipe to try building it since that would have caught this issue. Fixes [YOCTO #10616]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23licenses.conf: Fix variable name in comments (FOSS_NO_COPYRIGHT)Olof Johansson
A FOSSology related variable was renamed from FOSS_COPRYIGHT to FOSS_NO_COPYRIGHT, but the comment block describing the variable in licenses.conf was missed. Besides fixing this, this change also removes a redundant comment about where the variable is defined (it's right there! ;-)). Signed-off-by: Olof Johansson <olofjn@axis.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23webkitgtk: move recommends on ca-certificates from epiphany to webkitgtk.Carlos Alberto Lopez Perez
* The webkitgtk package should recommend the ca-certificates one, because any program usign webkit (and not only epiphany) would expect that the CAs certificates are available and that https validation works as expected. * For example, webkitgtk includes a MiniBrowser program that would fail to proper verify https sites if the ca-certificate package is not installed * Instead of making each one of the webkitgtk consumers care about the certificate package, do this in webkit itself. Signed-off-by: Carlos Alberto Lopez Perez <clopez@igalia.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23recipetool: add postinst to .deb importStephano Cetola
The .deb import feature did not import postinst, postrm, preinst, or prerm functions. This change checks to see if those files exist, and if so, adds the appropriate functions. [ YOCTO #10421 ] Signed-off-by: Stephano Cetola <stephano.cetola@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23rpm: fix multilib macro installationChen Qi
For now, the rpm macro for multilib is not installed correctly. For example, in x86-64 lib32 situation, the macro is installed under tmp/work/x86-pokymllib32-linux/rpm/5.4.16-r0/image/usr/lib/rpm/poky/i686-linux/. The directory is even not under WORKDIR. And it will of course not be packaged. We need to save necessary values before updating the localdata and restore them so that the macros could be installed into the correct directory. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23oe-selftest: enforce en_US.UTF-8 localeMaciej Borzecki
Replicate bitbake and eforce en_US.UTF-8 locale so that ouptut of locale-aware tools remains stable. Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23devshell: list commands when throwing NoSupportedTerminalsStephano Cetola
When attempting to run devshell, if no terminal is available, the error being thrown was not very specific. This adds a list of commands that failed, informing the user of what they can install to fix the error. [ YOCTO #10472] Signed-off-by: Stephano Cetola <stephano.cetola@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23systemd: systemd should not depend on systemd-containerMax Krummenacher
Currently systemd depends on systemd-container due to a dangling symlink deployed with systemd. Move the symlink to systemd-container. | DEBUG: systemd contains dangling link /lib/systemd/system/systemd-machined.service | DEBUG: target found in systemd-container Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23sanity.bbclass: fix check_connectivity() for BB_NO_NETWORK = "0"Robert Yang
The old code: network_enabled = not d.getVar('BB_NO_NETWORK', True) It is True only when BB_NO_NETWORK is not set (None), but BB_NO_NETWORK = "0" should also be True while "1" means no network, "0" means need network in a normal case. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23sanity.bbclass:check_connectivity(): print more error messagesRobert Yang
This can help fix the problem when the error happens. Now the error message is: Fetcher failure for URL: 'https://www.example.com/'. URL https://www.example.com/ doesn't work. Please ensure your host's network is configured correctly, or set BB_NO_NETWORK = "1" to disable network access if all required sources are on local disk. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23testsdk.bbclass: print which file is not foundRobert Yang
This is helpful when debug. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23populate_sdk_ext.bbclass: use weak assignment for TOOLCHAINEXT_OUTPUTNAMERobert Yang
The TOOLCHAINEXT_OUTPUTNAME is different from TOOLCHAIN_OUTPUTNAME, it is used for eSDK only, so that it doesn't mix with SDK, use "?=" for it so that other conf file can define it. If we don't use "?=" here, then we need use forcevariable to redfine it: TOOLCHAINEXT_OUTPUTNAME_forcevariable = "foo" Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23glib: remove obsolete gi-exclude patchRoss Burton
This patch has been superseded by 2907b1 in gobject-introspection, which we're now shipping. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23sysvinit-inittab: make TERM=vt102 on serial consolesAndré Draszik
This makes more sense than the default TERM=linux (as set by the linux kernel). In addition, when using busybox init, it tries to achieve the same (in a different way). Both agetty, and busybox getty support the terminal type as the last argument. Signed-off-by: André Draszik <adraszik@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23opkg-utils: clear update-alternatives database on uninstallAndré Draszik
When uninstalling update-alternatives, it doesn't seem to make much sense to keep the update-alternatives database around. In particular when removing packaging data, e.g. due to read-only rootfs, update-alternatives is removed from the target file system. Leaving its database around serves no purpose in that case as there is no way to use it afterwards anyway. This frees close to 700KB of (uncompressed) space in a busybox based environment. Signed-off-by: André Draszik <adraszik@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23oe-selftest: devtool: test that updating a file with subdir= worksPaul Eggleton
If you have a file:// entry in SRC_URI with a subdir= parameter that makes it extract into the source tree, then when you update that file in oe-local-files and run devtool update-recipe then you want the original file to be updated. This was made to work by OE-Core commit 9069fef5dad5a873c8a8f720f7bcbc7625556309 together with 31f1bbad248c36a8c86dde4ff57ce42efc664082, however until now there was no oe-selftest test to verify it. Note that in order to succeed this test also requires the fix "lib/oe/recipeutils: ignore archives by default in get_recipe_local_files()" since the test recipe uses a local tarball. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23lib/oe/recipeutils: ignore archives by default in get_recipe_local_files()Paul Eggleton
By default, have get_recipe_local_files() not return any archive files. This prevents a local tarball from being erroneously removed from SRC_URI if you run "devtool modify" on a recipe followed by "devtool update-recipe". It doesn't actually help you to directly update the contents of such tarballs, but at least now it won't break the recipe. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23devtool: update-recipe: support replacing remote patchesPaul Eggleton
If you have a patch remotely fetched in a recipe (e.g. from an http server) that needs updating then add a local version and substitute the entry in SRC_URI to point to it. One can argue about how desirable it is to be modifying patches fetched in this way, but then one can argue about how desirable it is to have such patches in the recipe in the first place - and in any case if devtool update-recipe is to correctly transfer changes to such patches made in the git repository within the source tree to the recipe then there isn't much choice but to do it this way. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23devtool: update-recipe: fix handling of compressed local patchesPaul Eggleton
It is possible to use gzip or bzip2 to compress patches and still refer to them in compressed form in the SRC_URI value within a recipe. If you run "devtool modify" on such a recipe, make changes to the commit for the patch and then run devtool update-recipe, we need to correctly associate the commit back to the compressed patch file and re-compress the patch, neither of which we were doing previously. Additionally, add an oe-selftest test to ensure this doesn't regress in future. Fixes [YOCTO #8278]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23lib/oe/patch: fix handling of patches with no headerPaul Eggleton
If a patch applied by a recipe has no header and we turn the recipe's source into a git tree (when PATCHTOOL = "git" or when using devtool extract / modify / upgrade), the commit message ends up consisting only of the original filename marker ("%% original patch: filename.patch"). When we come to do turn the commits back into a set of patches in extractPatches(), this first line ends up in the "Subject: " part of the file, but we were ignoring it because the line didn't start with the marker text. The end result was we weren't able to get the original patch name. Strip off any "Subject [PATCH x/y]" part before looking for the marker text to fix. This caused "devtool modify openssl" followed by "devtool update-recipe openssl" (without any changes in-between) to remove version-script.patch because that patch has no header and we weren't able to determine the original filename. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23oe-selftest: devtool: test update-recipe with only local filesPaul Eggleton
Add a test to ensure devtool update-recipe works properly on recipes that contain only local files (since the other tests we have didn't test that). Relates to [YOCTO #10563]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23devtool: update-recipe: check output before treating it as a stringPaul Eggleton
As of the move to Python 3 and the fixes we applied at that time, bb.process.run() will return a byte array of length 0 rather than an empty string if the output is empty. That may be a bug that we should fix, but for now it's easiest to just check the result here before treating it as a string. This fixes running "devtool update-recipe" or "devtool finish" on a recipe which has no source tree, for example initramfs-framework. Fixes [YOCTO #10563]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23cmake.bbclass: Set CXXFLAGS and CFLAGSKhem Raj
We strip the TOOLCHAIN_OPTIONS and HOST_CC_ARCH from CC/CXX in cmake.bbclass whereas CFLAFS and CXXFLAGS assume that TOOLCHAIN_OPTIONS are part of CC/CXX variables, this causes compile failures when cmake is running compiler tests during configure on some architectures especially armhf, because hf ABI information -mfloat-abi is part of TOOLCHAIN_OPTIONS, so what happens is that testcase gets compiled without hard-float, howver, during linking the float ABI option is passed via LDFLAGS, now linker rejects this and fails like /mnt/a/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/6.2.0/ld: error: cmTC_27947 uses VFP register arguments, CMakeFiles/cmTC_27947.dir/src.cxx.o does not mnt/a/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/6.2.0/ld: failed to merge target specific data of file CMakeFiles/cmTC_27947.dir/src.cxx.o collect2: error: ld returned 1 exit status This means that CMake now fails the configure time test too which is not right, e.g. it might disable features which actually do exist and should be enabled e.g. in case above it is resulting as below Performing C++ SOURCE FILE Test HAS_BUILTIN_SYNC_SUB_AND_FETCH failed with the following output: Its actually a bug in CMake see https://gitlab.kitware.com/cmake/cmake/issues/16421 CMake is ignoring CMAKE_CXX_FLAGS when using CHECK_CXX_SOURCE_COMPILES function. Until it is fixed upstream, we add HOST_CC_ARCH and TOOLCHAIN_OPTIONS to CFLAGS and CXXFLAGS, so that we can ensure that compiler invocation remains consistent. Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23tiff: Security fix CVE-2016-3658Zhixiong Chi
The TIFFWriteDirectoryTagLongLong8Array function in tif_dirwrite.c in the tiffset tool allows remote attackers to cause a denial of service (out-of-bounds read) via vectors involving the ma variable. External References: https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-3658 http://bugzilla.maptools.org/show_bug.cgi?id=2546 Patch from: https://github.com/vadz/libtiff/commit/45c68450bef8ad876f310b495165c513cad8b67d Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23systemd: Reload configuration on package installLinus Wallgren
When a systemd service file has changed it is required to reload systemd's configuration. Otherwise changes to a service file will not be picked up during package upgrade. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23qemu: update run-ptest scriptKai Kang
The Makefile in directory tests has been renamed, then update script run-ptest to follow the change. Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23qemu: fix CVE-2016-7909Kai Kang
Backport patch to fix CVE-2016-7909 of qemu. Ref: https://security-tracker.debian.org/tracker/CVE-2016-7909 Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23glibc: fix CVE-2016-6323Kai Kang
Backport patch to fix CVE-2016-6323 of glibc. And remove the section of file ChangeLog which can't be applied. Ref: https://sourceware.org/bugzilla/show_bug.cgi?id=20435 Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23openssh: fix CVE-2016-8858Kai Kang
Backport patch to fix CVE-2016-8858 of openssh. Ref: https://bugzilla.redhat.com/show_bug.cgi?id=1384860 Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23openssl: fix bashism in c_rehash shell scriptAndré Draszik
This script claims to be a /bin/sh script, but it uses a bashism: from checkbashisms: possible bashism in meta/recipes-connectivity/openssl/openssl/openssl-c_rehash.sh line 151 (should be 'b = a'): if [ "x/" == "x$( echo ${FILE} | cut -c1 -)" ] This causes build issues on systems that don't have /bin/sh symlinked to bash: Updating certificates in ${WORKDIR}/rootfs/etc/ssl/certs... <builddir>/tmp/sysroots/x86_64-linux/usr/bin/c_rehash: 151: [: x/: unexpected operator ... Fix this by using POSIX shell syntax for the comparison. Signed-off-by: André Draszik <adraszik@tycoint.com> Reviewed-by: Sylvain Lemieux <slemieux@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23webkitgtk: Add an option to disable opengl supportCarlos Alberto Lopez Perez
Signed-off-by: Carlos Alberto Lopez Perez <clopez@igalia.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23swig: 3.0.8 -> 3.0.10Wang Xin
Upgrade swig from 3.0.8 to 3.0.10. Signed-off-by: Wang Xin <wangxin2015.fnst@cn.fujitsu.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23ltp: Reduce duplication in MIPS variants.Zubair Lutfullah Kakakhel
Reduce duplication in MIPS variants now that the MACHINEOVERRIDES variable is defined Signed-off-by: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23glib-networking: remove intltool dependencyRoss Burton
glib-networking 2.50 moved away from intltool to modern gettext, so remove the build dependency. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23readline: Update to version 7.0Fabio Berton
Remove readline 6.3 patches and config-dirent-symbols.patch already apply on upstream. Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23lib/oe/package_manager: .deb pre/postinst argsLinus Wallgren
The debian policy manual and MaintainerScripts wiki page states that the postinst script is supposed to be called with the `configure` argument at first install, likewise the preinst script is supposed to be called with the `install` argument on first install. https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html https://wiki.debian.org/MaintainerScripts Signed-off-by: Linus Wallgren <linus.wallgren@scypho.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-16binconfig: Use d.getVarRichard Purdie
The bb.data API is deprecated, use d.getVar instead. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-11-15sanity.bbclass: fix logging of an errorMarkus Lehtonen
Fixes a crash in exception handler. All bb logging functions need an string instances as arguments. Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15oe-selftest: fix handling of test cases without ID in --list-tests-byMaciej Borzecki
Running `oe-selftest --list-tests-by module wic` will produce the following backtrace: Traceback (most recent call last): File "<snip>/poky/scripts/oe-selftest", line 668, in <module> ret = main() File "<snip>/poky/scripts/oe-selftest", line 486, in main list_testsuite_by(criteria, keyword) File "<snip>/poky/scripts/oe-selftest", line 340, in list_testsuite_by ts = sorted([ (tc.tcid, tc.tctag, tc.tcname, tc.tcclass, tc.tcmodule) for tc in get_testsuite_by(criteria, keyword) ]) TypeError: unorderable types: int() < NoneType() The root cause is that a test case does not necessarily have an ID assigned, hence its value is None. Since Python 3 does not allow comparison of heterogeneous types, TypeError is raised. Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15wic: fix function comment typosMaciej Borzecki
Fix typos in documentation of Image.add_partition() and Image.__format_disks(). Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15wic: check that filesystem is specified for a rootfs partitionMaciej Borzecki
We explicitly check for --fstype if no source was provided for a partition. However, this was not the case for rootfs partitions. Make sure to raise an error if filesystem was left unspecified when preparing a rootfs partition image. Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15wic: use partition size when creating empty partition filesMaciej Borzecki
It seems that prepare_empty_partition_ext() and prepare_empty_partition_btrfs() got broken in commit c8669749e37fe865c197c98d5671d9de176ff4dd, thus one could observe the following backtrace: Backtrace: File "<snip>/poky/scripts/lib/wic/plugins/imager/direct_plugin.py", line 93, in do_create creator.create() File "<snip>/poky/scripts/lib/wic/imager/baseimager.py", line 159, in create self._create() File "<snip>/poky/scripts/lib/wic/imager/direct.py", line 290, in _create self.bootimg_dir, self.kernel_dir, self.native_sysroot) File "<snip>/poky/scripts/lib/wic/partition.py", line 146, in prepare method(rootfs, oe_builddir, native_sysroot) File "<snip>/poky/scripts/lib/wic/partition.py", line 325, in prepare_empty_partition_ext os.ftruncate(sparse.fileno(), rootfs_size * 1024) NameError: name 'rootfs_size' is not defined Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15wic: make sure that partition size is always an integer in internal processingMaciej Borzecki
The size field of Partition class is expected to be an integer and ought to be set inside prepare_*() method. Make sure that this is always the case. Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15lib/oe/lsb: attempt to ensure consistent distro id regardless of sourceJoshua Lock
The LSB Distributor ID and os-release NAME differ for most of the distributions tested by the Yocto Project (CentOS, Debian, Fedora, openSUSE and Ubuntu) however for all but openSUSE the os-release ID matches the LSB Distributor ID when both are lowered before comparison. Therefore, in order to improve the consistency of identification of a distribution, switch to using the os-release ID and converting the ID value to lowercase. Table showing comparison of LSB Distributor ID to os-release fields NAME and ID for current Yocto Project supported host distributions: Distribution | Version | Distributor ID | NAME | ID | ------------------------------------------------------------------------- CentOS | 7 | CentOS | CentOS Linux | centos | Debian | 8 | Debian | Debian GNU/Linux | debian | Fedora | 23 | Fedora | Fedora | fedora | Fedora | 24 | Fedora | Fedora | fedora | openSUSE | 13.2 | openSUSE project | openSUSE | opensuse | openSUSE | 42.1 | SUSE LINUX | openSUSE Leap | opensuse | Ubuntu | 14.04 | Ubuntu | Ubuntu | ubuntu | Ubuntu | 16.04 | Ubuntu | Ubuntu | ubuntu | [YOCTO #10591] Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15lib/oe/lsb: prefer /etc/os-release for distribution dataJoshua Lock
os-release(5) is an increasingly standard source of operating system identification and more likely to be present on modern OS deployments, i.e. many container variants of common distros include os-release and not the lsb_release tool. Therefore we should favour parsing /etc/os-release in distro_identifier(), try lsb_release when that fails and finally fall back on various distro specific sources of OS identification. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-15lib/oe/lsb: make the release dict keys consistent regardless of sourceJoshua Lock
Rather than have the distro_identifier method look for different keys in the dict depending on the source ensure that each function for retrieving release data uses the same key names in the returned dict. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>