Added canned wks and testcase to create multi-rootfs images referring
bitbake image recipes.
Signed-off-by: Ed Bartosh
create mode 100644 scripts/lib/image/canned-wks/directdisk-multi-rootfs.wks
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index 5385562..3cfc2ff
un only once and results are parsed
only once per requested set of variables.
get_bitbake_var became the only API call. It replaces find_artifacts,
find_artifact, find_bitbake_env_lines, get_bitbake_env_lines,
set_bitbake_env_lines and get_line_val calls making API much more clear.
Signed-off-by: Ed
Added --uuid option to the configuration of wks parser.
This option specifies partition UUID. The code to process
it is already in place. It was implemented for --use-uuid
option.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index c8b2fab..0666d80
Moved code out of prepare_roots* methods to avoid code duplication.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 324ea69..489ebe3 100644
--- a/scripts/lib/wic/kickstart
Renamed partition images into .p
This should make output directory look more organized and easier
to understand.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/partitionedfs.py
b/scripts/lib/wic/utils/partitionedfs.py
index e093ec5..d61087a 100644
--- a/scripts/lib/wic/utils
Wic tries to find plugins in every layer and prints a message
'Plugin dir is not a directory or does not exist' if layer
doesn't have plugin dir. It causes a lot of duplicated
messages in the debug output, which makes it hard to find
useful info there.
Signed-off-by: Ed Bartosh
Hi,
This patchset includes usability fixes, new functionality,
code cleanup, refactoring and 2 new test cases for wic.
The work was done during verification of multi-rootfs EFI images.
Fixes YOCTO #7854 and #7912
Ed Bartosh (20):
wic: Fix misleading message
wic: Test rootfs plugin using
Shortened code by using getattr to obtain a method to call for
prepare_empty_partition_* and prepare_rootfs_* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index e3ae3ce..0741bb2
Fixed pylint warnings bad-continuation, bad-continuation and
line-too-long.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py
index 92dcc5a..0dc7920 100644
--- a/scripts/lib/image/engine.py
+++ b/scripts/lib/image/engine.py
@@ -236,7 +236,10 @@ def
Fixed pylint warning unused-import
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py
index 0dc7920..73e8f8b 100644
--- a/scripts/lib/image/engine.py
+++ b/scripts/lib/image/engine.py
@@ -30,18 +30,10 @@
import os
import sys
-from abc import
Moved code of __write_partition to 'assemble' method.
This way it should be more readable.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/partitionedfs.py
b/scripts/lib/wic/utils/partitionedfs.py
index d61087a..ca4b1f0 100644
--- a/scripts/lib/wic/utils/partitionedf
issed artifacts.
Now the message looks like this:
The following build artifacts are not specified:
bootimg-dir, kernel-dir, native-sysroot
[YOCTO #7912]
Signed-off-by: Ed Bartosh
diff --git a/scripts/wic b/scripts/wic
index b75d122..ac272c6 100755
--- a/scripts/wic
+++ b/scripts/wic
@@ -1
Made the code to backup and restore fstab only if it's modified.
Cleaned up the code. Made it more pythonic.
Improved code readability by moving code from several tiny
methods into one place.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/i
Moved duplicated code of geting rootfs size
out of prepare_rootfs* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 4e8a6a8..72f617a 100644
--- a/scripts/lib/wic/kickstart
Image file name is not unique for the partitions without label.
This causes image being rewritten and used as a source for all
partitions without label. Wic produces broken or incorrect result
images because of that.
Added wks line number to the image name to make it unique.
Signed-off-by: Ed
Moved code out of prepare_empty_partition* methods
to avoid code duplication.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 0741bb2..4e8a6a8 100644
--- a/scripts/lib/wic/kickstart
Removed useless variable 'image_rootfs' from 4 prepare_rootfs_* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 489ebe3..e3ae3ce 100644
--- a/scripts/lib/wic
Switched debug level to 'normal' to prevent huge 'bitbake -e'
output to go into wic debug output. This should help to make
wic debug info much more clean and easier to read.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/oe/misc.py b/scripts/lib/wic/utils/oe/m
Hi Cristopher,
On Mon, Jun 29, 2015 at 02:48:30PM -0700, Christopher Larson wrote:
> On Mon, Jun 29, 2015 at 12:10 PM, Ed Bartosh
> wrote:
>
> > +global _BITBAKE_VARS
> > +
> > +if image not in _BITBAKE_VARS:
> >
>
> In general, I’d suggest
Added canned wks and testcase to create multi-rootfs images referring
bitbake image recipes.
Signed-off-by: Ed Bartosh
create mode 100644 scripts/lib/image/canned-wks/directdisk-multi-rootfs.wks
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index 5385562..3cfc2ff
un only once and results are parsed
only once per requested set of variables.
get_bitbake_var became the only API call. It replaces find_artifacts,
find_artifact, find_bitbake_env_lines, get_bitbake_env_lines,
set_bitbake_env_lines and get_line_val calls making API much more clear.
Signed-off-by: Ed
Wic doesn't show any information for the partition if label is not set.
Fixed this by adding mount point to the report.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/imager/direct.py
index 2ea7e4e..58a9e9d 100644
--- a/scripts/lib/wic/imager/dire
Wic tries to find plugins in every layer and prints a message
'Plugin dir is not a directory or does not exist' if layer
doesn't have plugin dir. It causes a lot of duplicated
messages in the debug output, which makes it hard to find
useful info there.
Signed-off-by: Ed Bartosh
Removed useless variable 'image_rootfs' from 4 prepare_rootfs_* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 489ebe3..e3ae3ce 100644
--- a/scripts/lib/wic
Renamed partition images into .p
This should make output directory look more organized and easier
to understand.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/partitionedfs.py
b/scripts/lib/wic/utils/partitionedfs.py
index e093ec5..d61087a 100644
--- a/scripts/lib/wic/utils
Christopher Larson to
point that out to me
- added one indentation fix
Ed Bartosh (20):
wic: Fix misleading message
wic: Test rootfs plugin using image recipes
wic: Test rootfs plugin using rootfs paths
wic: Refactor getting bitbake variables
wic: Include mount point into image report
wic
Added testcase to create multi-rootfs images using rootfs plugin
with paths to rootfs directories in wic command line.
Signed-off-by: Ed Bartosh
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index 3cfc2ff..0c503ef 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b
Moved code out of prepare_roots* methods to avoid code duplication.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 324ea69..489ebe3 100644
--- a/scripts/lib/wic/kickstart
Switched debug level to 'normal' to prevent huge 'bitbake -e'
output to go into wic debug output. This should help to make
wic debug info much more clean and easier to read.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/oe/misc.py b/scripts/lib/wic/utils/oe/m
Due to usage of incorrect variable wic produces strange message
"No image named None found, exiting." when specified canned .wks
doesn't exist.
Fixed by replacing wks_file -> argv[0]
Signed-off-by: Ed Bartosh
diff --git a/scripts/wic b/scripts/wic
index f9be972..a39ec95 10
Fixed pylint warnings bad-continuation, bad-continuation and
line-too-long.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py
index 92dcc5a..0dc7920 100644
--- a/scripts/lib/image/engine.py
+++ b/scripts/lib/image/engine.py
@@ -236,7 +236,10 @@ def
Fixed pylint warning unused-import
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py
index 0dc7920..73e8f8b 100644
--- a/scripts/lib/image/engine.py
+++ b/scripts/lib/image/engine.py
@@ -30,18 +30,10 @@
import os
import sys
-from abc import
Moved duplicated code of geting rootfs size
out of prepare_rootfs* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 4e8a6a8..72f617a 100644
--- a/scripts/lib/wic/kickstart
Added --uuid option to the configuration of wks parser.
This option specifies partition UUID. The code to process
it is already in place. It was implemented for --use-uuid
option.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index c8b2fab..0666d80
issed artifacts.
Now the message looks like this:
The following build artifacts are not specified:
bootimg-dir, kernel-dir, native-sysroot
[YOCTO #7912]
Signed-off-by: Ed Bartosh
diff --git a/scripts/wic b/scripts/wic
index b75d122..ac272c6 100755
--- a/scripts/wic
+++ b/scripts/wic
@@ -1
Made the code to backup and restore fstab only if it's modified.
Cleaned up the code. Made it more pythonic.
Improved code readability by moving code from several tiny
methods into one place.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/i
Moved code out of prepare_empty_partition* methods
to avoid code duplication.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 0741bb2..4e8a6a8 100644
--- a/scripts/lib/wic/kickstart
Shortened code by using getattr to obtain a method to call for
prepare_empty_partition_* and prepare_rootfs_* methods.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py
b/scripts/lib/wic/kickstart/custom_commands/partition.py
index e3ae3ce..0741bb2
Image file name is not unique for the partitions without label.
This causes image being rewritten and used as a source for all
partitions without label. Wic produces broken or incorrect result
images because of that.
Added wks line number to the image name to make it unique.
Signed-off-by: Ed
Moved code of __write_partition to 'assemble' method.
This way it should be more readable.
Signed-off-by: Ed Bartosh
diff --git a/scripts/lib/wic/utils/partitionedfs.py
b/scripts/lib/wic/utils/partitionedfs.py
index d61087a..ca4b1f0 100644
--- a/scripts/lib/wic/utils/partitionedf
Set default set of bitbake variables to the set of variables
for the first parsed image.
This allows wic to find proper bitbake varibale values
if it's called with '-e ' even without specifying
image in the call of get_bitbake_var.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/u
=)
ValueError: too many values to unpack
Fixed by changing delimiter ':' -> '::'
Signed-off-by: Ed Bartosh
---
meta/classes/toaster.bbclass | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/meta/classes/toaster.bbclass b/meta/classes/toaster.bbclass
i
Hi Mihaly,
The code looks ok to me.
Can you please fix the following:
1. Pylint is reporting a lot of long lines, indentation and other
issues, so it would be nice if you run it and fix at least some of them?
2. Docstring of plugin class is shown in 'wic help plugins' output. Some
lines of your
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 16
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/scripts/create-pull-request b/scripts/create-pull-request
index 97ed874..216edfd 100755
--- a/scripts/create-pull-request
+++ b/scripts/create-pull-request
flashed a lot faster with bmaptool than
with traditional tools like "dd" or "cp".
This package provides Python API, which can be used to generate
bmaps for Yocto images produced by bitbake and wic.
Signed-off-by: Ed Bartosh
---
meta/recipes-extended/bmap-tools/bm
Included full console output and example of the .wks file
into the 'wic help overview' content.
Used qemux86-64 machine instead of crownbay to make example
working without cloning additional layers.
[YOCTO #7940]
Signed-off-by: Ed Bartosh
---
scripts/lib/image/he
Fixed pylint warnings.
Increased pylint score from 8.02 to 9.40.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 40 +---
1 file changed, 21 insertions(+), 19 deletions(-)
diff --git a/scripts/lib/wic/utils/oe/misc.py b/scripts/lib/wic/utils
+0100)
are available in the git repository at:
git://git.yoctoproject.org/poky-contrib ed/wic/0.2.0
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=ed/wic/0.2.0
Ed Bartosh (6):
wic: improved usage text
wic: Improve 'wic help overview' content
wic: Report recipe name
exec_native_cmd was modified to report recipe to build
native programs.
Pairs executable->recipe are hardcoded as it's not possible
to obtain this information automatically.
[YOCTO #7631]
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 29 ++---
Removed unused global variable wks_vars and 2 unused functions
get_wks_var and add_wks_var.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 11 ---
1 file changed, 11 deletions(-)
diff --git a/scripts/lib/wic/utils/oe/misc.py b/scripts/lib/wic/utils/oe/misc.py
index
documentation fixes
- code clenup
Signed-off-by: Ed Bartosh
---
scripts/wic | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/wic b/scripts/wic
index 9435ce0..c1d3003 100755
--- a/scripts/wic
+++ b/scripts/wic
@@ -29,7 +29,7 @@
# Tom Zanussi
#
-__version__ = "
Made command line specification less confusing.
Reformatted usage output.
[YOCTO #7938]
Signed-off-by: Ed Bartosh
---
scripts/lib/image/help.py | 12 +---
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index 0666d80
g directory and running
git format-patch in it with --relative, without specifying
relative path as a parameter.
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/scripts/create-pull-request b/scripts/create-pull-reques
g directory and running
git format-patch in it with --relative, without specifying
relative path as a parameter.
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/scripts/create-pull-request b/scripts/create-pull-reques
On Thu, Aug 06, 2015 at 09:38:16AM +0100, Paul Eggleton wrote:
> On Wednesday 05 August 2015 20:33:48 Khem Raj wrote:
> > On Wed, Aug 5, 2015 at 2:01 AM, Ed Bartosh
> wrote:
> > > create-pull-request -d path creates empty patches if directory
> > > is specifie
Hi Mihaly,
Great work! Thank you!
Acked-by: Ed Bartosh
On Thu, Aug 06, 2015 at 08:04:49PM +0300, Mihaly Varga wrote:
>
> Hi Ed,
>
> Thank you for your comments. There is a slightly modified version of
> the isoimage-isohybrid plugin, the kickstart file and the wic selftest
g directory and running
git format-patch in it with --relative, without specifying
relative path as a parameter.
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/scripts/create-pull-request b/scripts/create-pull-reques
g directory and running
git format-patch in it with --relative, without specifying
relative path as a parameter.
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/scripts/create-pull-request b/scripts/create-pull-reques
Made create-pull-request POSIX compatible:
- Replaced /bin/bash -> /bin/sh in shebang.
- Replaced usage of pushd/popd with generic shell commands.
- Tested on zsh and dash.
Signed-off-by: Ed Bartosh
---
scripts/create-pull-request | 7 ---
1 file changed, 4 insertions(+)
05:56 +0100)
are available in the git repository at:
git://git.yoctoproject.org/poky-contrib ed/wic/wic-image-type
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=ed/wic/wic-image-type
Ed Bartosh (17):
image.py: write bitbake variables to .env file
oe-selftest: test generation o
Set BitbakeVars.default_image when wic is called with -e option.
This makes get_bitbake_var API to use provided image as a default
source of variables.
Signed-off-by: Ed Bartosh
---
scripts/wic | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/scripts/wic b/scripts/wic
Moved code that parses one line of 'bitbake -e' output
to separate method _parse_line.
This method will be also used later to parse lines of .env files.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 27 +--
1 file changed, 17 inserti
e
runs wic to produce wic images. In this case wic can't run bitbake
again as it's locked, so it will get variables from .env files.
Signed-off-by: Ed Bartosh
---
scripts/wic | 6 ++
1 file changed, 6 insertions(+)
diff --git a/scripts/wic b/scripts/wic
index 87ada36..815b84e 1007
New attribute is used when bitbake variable is requested without
specifying image name. The attribute should be set from outside,
for example when wic is called with '-e ' option.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 6 ++
1 file changed, 6 insertion
Moved code of getting bitbake variables into separate class.
Created singleton object of this class in the module namespace.
Preserved existing API get_bitbake_var.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 91 +++-
1 file changed, 53
Renamed variable help -> hlp as 'help' is a name of Python
built-in function.
Signed-off-by: Ed Bartosh
---
scripts/lib/image/help.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index 5fa5836..dc6ff36
tialized
to get variables from .env files.
Signed-off-by: Ed Bartosh
---
scripts/lib/image/help.py | 2 ++
scripts/wic | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index dc6ff36..717d847 100644
--- a/sc
Added functionality of getting variables from .env files to
BitbakeVars class. env files will be parsed if the directory with
env files is known, i.e. when vars_dir attribute is set.
Otherwise 'bitbake -e' output will be parsed.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/
Renamed __exec_cmd -> _exec_cmd as double underscores cause
strange behaviour when function is called in class method.
Python complains that __exec_cmd method(!!!) of the same class
doesn't exist.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 12 ++--
1 file
Added test case to verify building of wic-image-minimal recipe
and produced artifacts: manifest and bzipped partitioned image.
Signed-off-by: Ed Bartosh
---
meta/lib/oeqa/selftest/wic.py | 14 ++
1 file changed, 14 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib
wic image type is used to produce partitioned images.
Image configuration should be stored in either ..wks
or .wks file.
.wks file should be put to the same location as image recipe
and have the same name.
[YOCTO #7672]
Signed-off-by: Ed Bartosh
---
meta/classes/image_types.bbclass | 12
This variable is going to be used by wic to set partition
size. Setting it in image.py makes it possible for wic to
use it without calculating it again.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oe/image.py
Let's add output of image creation script to the bitbake log
as it can contain useful information.
One good example of such an information is wic report about
artifacts and .wks file used for image creation.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 5 -
1 file chang
inimal/1.0-r0/rootfs
BOOTIMG_DIR: tmp/sysroots/qemux86-64/usr/share
KERNEL_DIR: tmp/deploy/images/qemux86-64
NATIVE_SYSROOT: tmp/sysroots/x86_64-linux
Signed-off-by: Ed Bartosh
---
meta/recipes-extended/images/wic-image-minimal.bb | 14 ++
meta/recipes-extended/images/wic-image-minimal.wk
Write set of bitbake variables associated with the image into
build/tmp/sysroots//imagedata/.env
This is needed for wic to be able to get bitbake variables without
running 'bitbake -e'.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 23 +++
1 file c
, IMAGE_ROOTFS_ALIGNMENT, IMAGE_OVERHEAD_FACTOR
and IMAGE_ROOTFS_EXTRA_SPACE.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/imager/direct.py | 14 ++
1 file changed, 14 insertions(+)
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/imager/direct.py
index 57b1335..d68fd2a 100644
--- a
Added test case to check if .env file is generated
and contains bitbake variables used in wic code.
Signed-off-by: Ed Bartosh
---
meta/lib/oeqa/selftest/wic.py | 20
1 file changed, 20 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
(2015-08-20 22:04:43 +0100)
are available in the git repository at:
git://git.yoctoproject.org/poky-contrib ed/devtool/8135
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=ed/devtool/8135
Ed Bartosh (2):
devtool: make add_md5 a public API
devtool: implement build-image plugin
Implemented new plugin to build image from workspace packages.
Plugin creates .bbappend file, adds
all workspace packages to the image using IMAGE_INSTALL_append
variable in bbappend file. After that it runs 'bitbake '.
Signed-off-by: Ed Bartosh
---
scripts/lib/devtool/build-ima
Moved _add_md5 function from standard.py to __init__.py to
be able to call it from other modules.
Signed-off-by: Ed Bartosh
---
scripts/lib/devtool/__init__.py | 6 ++
scripts/lib/devtool/standard.py | 14 --
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a
Moved code of getting bitbake variables into separate class.
Created singleton object of this class in the module namespace.
Preserved existing API get_bitbake_var.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 91 +++-
1 file changed, 53
Added functionality of getting variables from .env files to
BitbakeVars class. env files will be parsed if the directory with
env files is known, i.e. when vars_dir attribute is set.
Otherwise 'bitbake -e' output will be parsed.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/
wic image type is used to produce partitioned images.
Image configuration should be stored in either ..wks
or .wks file.
.wks file should be put to the same location as image recipe
and have the same name.
[YOCTO #7672]
Signed-off-by: Ed Bartosh
---
meta/classes/image_types.bbclass | 12
Renamed variable help -> hlp as 'help' is a name of Python
built-in function.
Signed-off-by: Ed Bartosh
---
scripts/lib/image/help.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index 5fa5836..dc6ff36
Added test case to verify building of wic-image-minimal recipe
and produced artifacts: manifest and bzipped partitioned image.
Signed-off-by: Ed Bartosh
---
meta/lib/oeqa/selftest/wic.py | 14 ++
1 file changed, 14 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib
This variable is going to be used by wic to set partition
size. Setting it in image.py makes it possible for wic to
use it without calculating it again.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oe/image.py
b62e0476ba9e12f9125ed9f785cf23:
bitbake: lib/bb/main: avoid importing all server/UI modules on every
execution (2015-08-24 23:47:07 +0100)
are available in the git repository at:
git://git.yoctoproject.org/poky-contrib ed/wic/wic-image-type
http://git.yoctoproject.org/cgit.cgi/poky-contrib/lo
e
runs wic to produce wic images. In this case wic can't run bitbake
again as it's locked, so it will get variables from .env files.
Signed-off-by: Ed Bartosh
---
scripts/wic | 6 ++
1 file changed, 6 insertions(+)
diff --git a/scripts/wic b/scripts/wic
index 87ada36..815b84e 1007
New attribute is used when bitbake variable is requested without
specifying image name. The attribute should be set from outside,
for example when wic is called with '-e ' option.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 6 ++
1 file changed, 6 insertion
Added test case to check if .env file is generated
and contains bitbake variables used in wic code.
Signed-off-by: Ed Bartosh
---
meta/lib/oeqa/selftest/wic.py | 19 +++
1 file changed, 19 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
Let's add output of image creation script to the bitbake log
as it can contain useful information.
One good example of such an information is wic report about
artifacts and .wks file used for image creation.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 5 -
1 file chang
Write set of bitbake variables associated with the image into
build/tmp/sysroots//imagedata/.env
This is needed for wic to be able to get bitbake variables without
running 'bitbake -e'.
Signed-off-by: Ed Bartosh
---
meta/lib/oe/image.py | 23 +++
1 file c
, IMAGE_ROOTFS_ALIGNMENT, IMAGE_OVERHEAD_FACTOR
and IMAGE_ROOTFS_EXTRA_SPACE.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/imager/direct.py | 14 ++
1 file changed, 14 insertions(+)
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/imager/direct.py
index 57b1335..d68fd2a 100644
--- a
Set BitbakeVars.default_image when wic is called with -e option.
This makes get_bitbake_var API to use provided image as a default
source of variables.
Signed-off-by: Ed Bartosh
---
scripts/wic | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/scripts/wic b/scripts/wic
Renamed __exec_cmd -> _exec_cmd as double underscores cause
strange behaviour when function is called in class method.
Python complains that __exec_cmd method(!!!) of the same class
doesn't exist.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 12 ++--
1 file
tialized
to get variables from .env files.
Signed-off-by: Ed Bartosh
---
scripts/lib/image/help.py | 2 ++
scripts/wic | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/lib/image/help.py b/scripts/lib/image/help.py
index dc6ff36..717d847 100644
--- a/sc
Moved code that parses one line of 'bitbake -e' output
to separate method _parse_line.
This method will be also used later to parse lines of .env files.
Signed-off-by: Ed Bartosh
---
scripts/lib/wic/utils/oe/misc.py | 27 +--
1 file changed, 17 inserti
inimal/1.0-r0/rootfs
BOOTIMG_DIR: tmp/sysroots/qemux86-64/usr/share
KERNEL_DIR: tmp/deploy/images/qemux86-64
NATIVE_SYSROOT: tmp/sysroots/x86_64-linux
Signed-off-by: Ed Bartosh
---
meta/recipes-extended/images/wic-image-minimal.bb | 14 ++
meta/recipes-extended/images/wic-image-minimal.wk
oor
>
> -Original Message-
> From: openembedded-core-boun...@lists.openembedded.org
> [mailto:openembedded-core-boun...@lists.openembedded.org] On Behalf Of Ed
> Bartosh
> Sent: Tuesday, August 25, 2015 2:04 PM
> To: openembedded-core@lists.openembedded.org
> Subjec
On Sun, Aug 30, 2015 at 12:24:48PM +0100, Richard Purdie wrote:
> On Thu, 2015-08-20 at 14:56 +0300, Ed Bartosh wrote:
> > Write set of bitbake variables associated with the image into
> > build/tmp/sysroots//imagedata/.env
> >
> > This is needed for wic to be ab
601 - 700 of 1334 matches
Mail list logo