Commit Graph

4732 Commits

Author SHA1 Message Date
David Reyna b06f7cbb94 bitbake: toaster: fix SDK artifact capture
Use the TaskArtifacts event to scan the SDK and ESDK manifests
to cleanly collect the respective artifact files.

The previous method was broken when the SDK file deployment moved
from the do_populate_sdk[_ext] tasks to their sstate tasks. That
method is disabled (but not yet removed) in preparation for the
rest of refactor work for the parent #10283 work.

[YOCTO #10850]

(Bitbake rev: 1360d7b847cc01031edb2f4b289fac9560d72fa7)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
Markus Lehtonen fc6370626e bitbake: cache: prevent division-by-zero in load_cahefile()
[YOCTO 11315]

(Bitbake rev: 227c5acd4b40154bc61202e7bb67a13818a7d727)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
David Reyna 2a40a0587e bitbake: toaster: fix add layer button for Machines
Fix a missing close quote in the layer add button, and
use the layer index for the xhr_layer call.

[YOCTO #11213]

(Bitbake rev: 54d61e7c64c97799de85b3563119f0f5d051675e)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
David Reyna d8be835e28 bitbake: toaster: Toaster filters are broken
A syntax fix inadvertantly broke the Toaster filter feature.

[YOCTO #11317]

(Bitbake rev: 29c9fa31d0f03553e24391568d2a5cb588595420)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-11 18:05:09 +01:00
Paul Eggleton b372e85d9b bitbake: bitbake-diffsigs: colourise output
If the output is a TTY, add colour to the output in order to make it
easier to read. At the moment this is fairly basic, just add colour to
the "titles" of each change and to the diff output.

I tried to introduce this without changing the code too much - rather
than moving everything over to the new python formatting style, I've
introduced a color_format() function which takes care of the colour
formatting, either accepting additional format arguments or
alternatively leaving the caller to use the old-style formatting (%) to
insert values.

(Bitbake rev: 04a023c8fdea1e1812fcdcaf00345aab59f9abe1)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Paul Eggleton 5f7bf1f66d bitbake: lib/bb/siggen: show word-diff for single-line values containing spaces
If a variable value has changed and either the new or old value contains
spaces, a word diff should be appropriate and may be a bit more readable.
Import the "simplediff" module and use it to show a word diff (in the
style of GNU wdiff and git diff --word-diff).

Also use a similar style diff to show changes in the runtaskhashes list.
I didn't use an actual word-diff here since it's a little different - we
can be sure that the list is a list and not simply a free-format string.

(Bitbake rev: 20db6b6553c80e18afc4f43dc2495435f7477822)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Paul Eggleton 5d8b89fc0b bitbake: lib/bb/siggen: add collapsed mode to compare_sigfiles()
If we just want to drill down to the actual differences then we don't
need to see certain things in the output, e.g. basehash changing or the
signature of dependent tasks. This will be used for comparing signatures
within buildhistory-diff in OE-Core; the default mode as used by
bitbake-diffsigs and bitbake -S printdiff remains unchanged for the
moment.

(Bitbake rev: 6543a59b1ebd3194a7c6421cffc66ebe31a67c62)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Paul Eggleton 8c015e45ff bitbake: lib/bb/siggen: don't show unchanged runtaskdeps list
If the runtaskdeps list hasn't actually changed (but the signatures of
some of the tasks did) then it doesn't make sense to print out the old
and new lists as they are both the same and may be very long, e.g. for
do_rootfs in OE.

(Bitbake rev: cb170543605288b3e8badfac3a54c588f4c95413)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Paul Eggleton 445e622b23 bitbake: lib/bb/siggen: show a diff when dumping changes to multi-line values
When dumping changes to signatures e.g. output of bitbake -s printdiff,
if for example a function has changed, it's much more readable to see a
unified diff of the changes rather than just printing the old function
followed by the new function, so use difflib to do that.

Note: I elected to keep to one item in the returned list per change,
rather than one line per line of output, so that the caller can still
look at changes individually if needed. Thus I've added some handling to
bitbake-diffsigs to split the change into lines so that each line is
displayed indented.

(Bitbake rev: 4d254ae63a35231c98e3f73f669b040ed1144042)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Paul Eggleton f3b010b39a bitbake: lib/bb/siggen: add missing path separator to cleaned paths
Printing "pbzip2pbzip2_1.1.13.bb" is ugly, we need to add a separating
slash so that we get "pbzip2/pbzip2_1.1.13.bb" instead.

(Bitbake rev: 55cd4045a37afc954f4d5091f524756b266064fc)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
David Reyna 123ec6ebc2 bitbake: toaster:test:Create selenium tests for project dashboard page
Added 7 new testcases that verify the UI interface and elements of the project detail page.
This testcases can be found on testopia in the links:

Verifies that the project is created and that you get redirected to the configuration page
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1514

Verifies that the left side bar menu, all links are clickable and they show on the UI
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1515

Verifies that after creating a project the default project configuration is created
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1516

Verifies that the default machine is set, once creating the project
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1517

Verifies the built recipes information of the project detail page
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1518

Verifies the default release information of the project
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1519

Verifies that the default layers are assigned to the project
https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=1520

Verifies that the links to the Configuration, Builds, Import layer and New Custom Image are present and work.

[YOCTO #9808]

(Bitbake rev: eaeddaf96efb8079b307652eac208f4ab5019ad4)

Signed-off-by: Libertad Cruz <libertad.cruz@intel.com>
Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Belal, Awais f45a5a5de8 bitbake: toaster: toastergui: implement machine name validation
Valid machine names cannot include spaces anywhere
in the name and doing so will result in a build failure.
This implements a mechanism to alert the user against
such a misconfiguration and does not allow input of
such machine names.

[YOCTO #8721]

(Bitbake rev: 6fb642935a3787659aa316ca906025d2d87964cf)

Signed-off-by: Awais Belal <awais_belal@mentor.com>
Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Richard Purdie eb7430e5b9 bitbake: Bump version to 1.33.4
(Bitbake rev: fe5d8a0fdaec99721455dead626ecfb72bdeb616)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Richard Purdie ee0ef7d13c bitbake: runqueue: Allow recrdeptask not to exist for all recipes
Currently if you specify a recrdeptask, it must exist for all recipes or
you get a python traceback. This is a bug and it should be possible to have
recipes which don't have the specified task.

As well as preventing such a traceback (which shouldn't happen, it should be
a user readable error), this allows us to fix issues in OE-Core which would
otherwise trigger the traceback.

(Bitbake rev: f93a77f2f188e18de9e3d812e86d77c2f3c71889)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-10 23:00:32 +01:00
Richard Purdie 2334036502 bitbake: fetch/local: Drop FILESDIR
This has long since been deprecated and is no longer used anywhere, FILESPATH
is the commonly used varaible which offers much more flexibility. Remove
the FILESDIR code and references from bitbake.

(Bitbake rev: 751c9dc51fd01fa64a1ff37ba2638110335f71af)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-05 23:20:03 +01:00
Paul Eggleton 2d704e445c bitbake: codeparser: add some comments
Add a few comments at the top of the file explaining what it's for, and
a comment pointing out that you need to increment the cache version when
changing any code that changes the output.

(Bitbake rev: c1780bc1872bb35bc28c76eff9110717f02d9db2)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-05 23:19:17 +01:00
Paul Eggleton 1fe95cfc12 bitbake: bitbake-selftest: add contains tests
Add some tests to verify that we are extracting "contains" information
from python expressions in the code in the bb.data and bb.codeparser
modules.

(Bitbake rev: 88fda492df875dd79b7aecf1f34b38517fc1eb33)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-05 23:19:17 +01:00
Paul Eggleton 7b7c238b2d bitbake: codeparser: improve handling of contains_any() and filter()
Ensure we handle bb.utils.contains_any() as separate items, rather than
how we handle contains() where every item must be in the list.
Additionally, enable handling bb.utils.filter() which for the purposes
of looking at dependencies is the same as contains_any().

Additionally bump the codeparser cache and recipe cache versions to
invalidate the user's existing caches (ensuring that the changes take
effect and avoiding "taskhash mismatch" errors respectively).

(Bitbake rev: 496e3c84820a2a889d99d3604659e47a550941d5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-05 23:19:17 +01:00
Paul Eggleton f217b65f12 bitbake: lib/bb/data: fix dependency handling for contains and multiple values
The code that determines variable dependencies uses the codeparser to
find references to "contains" type operations e.g. bb.utils.contains().
That function can take multiple items to check, and all specified items
have to be present. However this code didn't handle that - it assumed
that only one item would be specified and thus it was treating the
multiple items as a single item with spaces in between. Split the value
and check if all words are present in order to determine whether the
check is "set" or "unset".

(Bitbake rev: 272f1245acdd4fb85cb78612aa03627a9c246d8f)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-05 23:19:17 +01:00
Peter Kjellerstedt 4077dcb565 bitbake: fetch2: Do not fail to create symbolic links if they already exist
When the fetcher retrieves file:// URLs, there is no lock file being
used. This means that in case two separate tasks (typically from two
concurrent invocations of bitbake) want to download the same file://
URL at the same time, there is a very small chance that they also end
up wanting to create a symbolic link to the file at the same time.
This would previously lead to one of the tasks failing as the other
task would have created the link.

(Bitbake rev: 58a03531c8183b165bb7dcad86d8559c92bc150d)

Signed-off-by: Peter Kjellerstedt <pkj@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-04-01 23:28:41 +01:00
Richard Purdie b152870bf4 bitbake: bitbake: Bump version to 1.33.3
(Bitbake rev: 2c424b8cb39cba8f20f807e55efe6270996fa356)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-31 10:08:36 +01:00
Ross Burton 8ce18c5c44 bitbake: bb/utils: extend which() so it can look for just executables
Normally bb.utils.which() is used by the unpack code to find a file in a variety
of places, but it is useful as a slightly more powerful version of os.which().

Support this by allowing it to only return matches which are executable files,
instead of just the first filename that matches.

(Bitbake rev: c0b94f02f0cba7a424aaa16cf98c0f7a3f62b889)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-31 10:08:36 +01:00
Richard Purdie f46846dc11 bitbake: wget: Fix handling of urls with user/password
URL decoding was improved in the core a while ago and this looks like
a leftover from those times which caused urls needing a user/password to
fail. Use the parameters from the core instead of the broken split
implementation.

[YOCTO #11262]

(Bitbake rev: 6a917ec99d659e684b15fa8af94c325172676062)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-31 10:08:36 +01:00
Paul Eggleton 03b4226242 bitbake: tinfoil: improve get_recipe_file() exception text
* Turn reasons from a list into a string (usually there will be only one
  reason, but the interface provides for more than one) and state up
  front that the recipe is unavailable for clarity
* Use quotes around invalid recipe name

(Bitbake rev: 8922f1d23400049d2894a97915a533769a24ca07)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-31 10:08:35 +01:00
Paul Eggleton c2ac78c4d8 bitbake: tinfoil: fix get_recipe_file() to return an error on invalid recipe
This function calls cooker.findBestProvider() but didn't handle the fact
that that function returns a tuple (None, None, None, None) when there
is no matching recipe. (This fixes devtool in OpenEmbedded showing a
traceback when an invalid recipe is specified instead of a proper error
message.)

(Bitbake rev: 54a4757ca706afc6e98c7692f960592e80cab12b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-31 10:08:35 +01:00
Elizabeth 'pidge' Flanagan e5e463fbbb bitbake: s3.py: Remove hardcoded aws
This commit looks to see if FETCHCMD_s3 is set and if not, sets
it.

This is needed because I've use cases where I don't use aws, but
s3cmd (due to license).

(Bitbake rev: fdeaed70a7d1ff8be1a1de937cb864130b0c2c86)

Signed-off-by: Elizabeth 'pidge' Flanagan <pidge@toganlabs.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-30 10:42:18 +01:00
Paul Eggleton 8b1826e78a bitbake: lib/bb/codeparser: ensure BufferedLogger respects target logging level
BufferedLogger was sending log records to the target logger without
checking if the logger is enabled for the level of the record - and
handle() doesn't check this either (it's normally checked earlier when
the relevant log function is called e.g. logger.debug()), leading for
example to debug messages from codeparser getting printed when the log
level for the main BitBake logger was set to logging.WARNING.

(Bitbake rev: 968a77388dd1a24c1dadec6ce49bf53ebb5b643f)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-29 16:36:43 +01:00
Richard Purdie bb826208e5 bitbake: fetch2: Ensure we don't have file downloads overwriting each other
Imagine you have an sstate mirror accessed over http and an SSTATE_MIRRORS
which maps file:// urls to http:// urls.

File urls set donestampneeded = False, http urls don't. This can result in
races in the try_mirror_url() code since it will trigger new downloads after
aquiring the lockfile as verify_donestamp() doesn't look at origud and there
is no donestamp.

verify_donestamp() already has code to look at origud, we're just missing
some code at the start of the function to do this. Fix it to avoid
these races.

(Bitbake rev: b8b14d975a254444461ba857fc6fb8c725de8874)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-29 16:36:43 +01:00
Diana Thayer 71e48a3617 bitbake: main: Improve -v and -D option documentation
Expanded and clarify documentation for the -v, --verbose and -D, --debug
options.

[YOCTO #9962]

(Bitbake rev: 921592026c69287cdb40ffd90944d5944f28e2c3)

Signed-off-by: Diana Thayer <garbados@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-27 20:23:19 +01:00
Paul Eggleton 542eb4731c bitbake: tinfoil: enable client-side logger handling by default
If you had a script that uses tinfoil and it failed to connect to the
BitBake server, you did't see any of the expected messages - this was
because client-side logging wasn't being handled at all. Since you'll
almost always want this when using tinfoil, have it use the new
bb.msg.logger_create() function to enable client-side logging by
default.

Relates to [YOCTO #11185].

(Bitbake rev: 824e73e0f3eaa96b4d84da7e31f9a17ce5c5d7ee)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-27 20:23:19 +01:00
Paul Eggleton 614cbeddc8 bitbake: lib/bb/msg: introduce logger_create() function
We use this code to set up a logger with colour in a number of different
places, so create one function that does this and make some of bitbake's
utility scripts use it.

(Bitbake rev: b1ba7d1cc8ec33e2d081230287abd07f52136097)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-27 20:23:19 +01:00
Paul Eggleton f41740ee8e bitbake: fetch2/git: prevent recursion on getting latest revision
We call git ls-remote to get the latest revision from a git repository,
however by calling runfetchcmd() we can end up recursively running
git ls-remote a number of times with OE e.g. if ${SRCPV} is in PV, ${PV}
is in WORKDIR, and ${WORKDIR} is in PATH (as a result of recipe-specific
sysroots), our call to runfetchcmd() exports PATH so _lsremote() will
get called again - with the end result that we run git ls-remote 30
times in quick succession (!). Prevent that from happening by using a
guard variable and returning a dummy value if it's called recursively.

Fixes [YOCTO #11185].

(Bitbake rev: ff1ccd1db5d70b3fc9ad0d3e8f3d7b804c22bf36)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-27 20:23:19 +01:00
Patrick Ohly 99069699f1 bitbake: cooker.py: use correct multiconfig prefix in dependency graph
The dependency graph in the bb.event.DepTreeGenerated and the
corresponding pn-buildlist and task-depends.dot from "bitbake -g"
contained entries like multiconfig:qemuarm.gcc (dot as last separator)
instead of the correct multiconfig:qemuarm:gcc (colon as separator).

(Bitbake rev: cccd1578d84f041cd0c2dcddb91f317c69af70de)

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-23 13:19:49 +00:00
Richard Purdie 70f18264ce bitbake: data/cooker: Sort output data shown by -e
Displaying the environment data in a sorted manner makes it easier
to compare data between different setups and means you can know
where to find specific entries.

(Bitbake rev: baa417e44b009149eb1dfb07d5a488740b6e68ef)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Christopher Larson f4a9248975 bitbake: fetch/git: fix FetchError reference
FetchError isn't defined, use bb.fetch2.FetchError in this context.

(Bitbake rev: 945fa980e027753df2c21d84eb63dcaddb2caaee)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Christopher Larson 754e98c72e bitbake: fetch/git: drop pointless os.path.join, workdir=
The touch of .done explicitly specifies the path, so there's no need for
workdir=, and "os.path.join('.')" is identical to just '.'.

(Bitbake rev: 955cbfdaa2400d15ec428b65848e6835c9f44860)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Christopher Larson 5ee3bae3bb bitbake: fetch/git: kill pointless quotes around single % args
(Bitbake rev: 4aebf12153369364eae2e6e773e2a921e9c91f72)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Christopher Larson b079a2da36 bitbake: fetch/git: use enumerate for ud.names
list.index() isn't a particularly efficient operation, so keep track of our
position via enumerate() instead, which is more pythonic as well.

(Bitbake rev: dec6e90a4d27ee335e9c78aeebd277098fec94d1)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Juro Bystricky 9a6f636679 bitbake: data.py: sort exported variables
Various run.do_xxx files export dozens of variables.
Presently they are in random order. Among other things,
this makes it difficult to compare two files for relevant changes.
This patch ensures they are enumerated/printed in a sorted
(alphabetical) order.

(Bitbake rev: 27b501d1400d1942b5ba9f35218ca7aacd9bfefe)

Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Joshua Lock ad1d65ca32 bitbake: lib/bb/tests/codeparser: update expand syntax in comment
bb.data.expand(x, d) is deprecated API

(Bitbake rev: 71185c19205a77d0511fc00baf95a5433e7106d6)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:23 +00:00
Patrick Ohly 9b6b47c09d bitbake: taskdata.py: include more information in error message about broken task depends
This is what was reported when variable expansion in the 'depends'
varflag of a task was broken:

   ERROR: Error for .../refkit-image-common.bb, dependency ${@ does not contain exactly one ':' character.
    Task 'depends' should be specified in the form 'packagename:task'

It's not clear which task had this broken 'depends' and while one can
guess that variable expansion failed, the full expression isn't
printed either.

This is more useful:

   ERROR: Error for .../refkit-image-common.bb:do_stage_swupd_inputs[depends], dependency ${@ in '      virtual/fakeroot-native:do_populate_sysroot     ${@ ' '.join(['bundle-refkit-image-common-%s:do_swupd_list_bundle' % x for x in '${SWUPD_BUNDLES}'.split()]) } ' does not contain exactly one ':' character.
    Task 'depends' should be specified in the form 'packagename:task'

The 'depends' part gets repeated intentionally, to ensure that it doesn't get overlooked.

(Bitbake rev: eeeed7693710e4a78fec639b8050d8efe4ea3c33)

Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:22 +00:00
Paul Eggleton 1485a5517a bitbake: bitbake-layers: fix layerindex-fetch for Python 3
The data we read from an HTTPConnection comes in the form of bytes, but
we need it as a string, so in Python 3 we need to decode it (missed in
the Python 3 migration).

(Bitbake rev: 7e6a3cd1472e1a1c8304b46611e1676914a68b59)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:22 +00:00
Paul Eggleton 5b1807021e bitbake: data_smart: implement missing remote datastore operations
Enable the following operations from a remote datastore to affect the
other end:

* setVarFlag()
* delVar()
* delVarFlag()
* renameVar()

In practice I don't expect these to be used much, but they should be
present so that the implementation is at least reasonably filled out
and that the tests pass.

Also add tests for the interface, mostly by subclassing the existing
local test classes so that they are using a remote datastore. (These
don't actually test remote usage via tinfoil, just that the
datastore's interface can be used.)

(Bitbake rev: 282dc0719d22a39df746eea762ebe05c66aa8f8a)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:22 +00:00
Paul Eggleton 99414bdb1c bitbake: tinfoil: fix override handling in remote datastores
There was a huge gap in the remote datastore code introduced in the
tinfoil2 rework - we weren't handling overrides at all, since these are
stored separately from the actual data in the DataSmart object. Thus,
when a datastore actually represents a remote datastore we need to go
back to that remote datastore to get the override data as well, so
introduce code to do that.

To avoid a second round-trip I had to modify the _findVar() function to
return the override data as well. This will increase the overhead a
little when that data is superfluous, but without making the function
even uglier I don't think there's a way to avoid that.

(Bitbake rev: 4f9d6f060ed247fb6fa2f45668a892a1788d3f91)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:22 +00:00
Richard Purdie da577c7d37 bitbake: tests/data: Add inactive remove override test
In 2bc4d35fb32defc59cd6ed1fc87e35924c201a5c we fixed cases where an inactive
remove override was influecing the value of a variable. This adds a test
case for this issue.

(Bitbake rev: 1ff9b3c669fa187f152de7b8b57d14c2468d926c)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-16 22:12:07 +00:00
Andre McCurdy 812fabbd30 bitbake: runqueue: minor typo fix
(Bitbake rev: f2c151cd345788a135452f63f622a2bc0b10c2d4)

Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-15 17:38:33 +00:00
Peter Kjellerstedt b1f09df0f6 bitbake: ConfHandler: Use the same regular expression for all variable names
When the regular expression for matching a variable name was amended
with allowing the ~ character as part of the variable name, this was
never done to the regular expression that matches export
lines. Similarly, the regular expression that was used for matching
unset variables also used the one without support for the ~ character.

This unifies the regular expressions. For good measures it also
corrects the regular expression used to match a variable flag name for
the unset command to match the one used when setting a variable flag.

(Bitbake rev: acd2fd74ed467dc85ec75d5d0815f43e493f29bf)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-13 09:43:40 +00:00
Peter Kjellerstedt 1e275980f2 bitbake: knotty: Remove extra whitespace after task progress bars
For some reason, BBProgress.setextra() always adds a space at the end.
This prevents the task progress bars from filling the entire width of
the terminal, making them stop one character short. This looks odd
when shown together with the main progress bar, which does fill the
entire terminal width.

(Bitbake rev: 6540e98090d6a88607489a23c063be338bcc3b57)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-13 09:43:40 +00:00
Matthew McClintock 404f2aef94 bitbake: runqueue: add option to run all tasks in specific build target
For example:

$ bitbake core-image-minimal --runall unpack
...
NOTE: Tasks Summary: Attempted 326 tasks of which 88 didn't need to be rerun and all succeeded.

$ bitbake core-image-minimal --runall patch
NOTE: Tasks Summary: Attempted 453 tasks of which 332 didn't need to be rerun and all succeeded.

This can replace fetchall as well:
$ bitbake core-image-minimal --runall fetch
NOTE: Tasks Summary: Attempted 135 tasks of which 119 didn't need to be rerun and all succeeded.

(Bitbake rev: 7c0fa6ba66cdb956b37d94055307cde857633df9)

Signed-off-by: Matthew McClintock <msm-oss@mcclintock.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-13 09:43:40 +00:00
David Reyna 35ce834167 bitbake: toaster: resolve missing 'native[sdk]:' prefixes
Some task events are missing the 'virtual:native[sdk]:' prefixes.
The Toaster has code to help match missing prefixes, but needs
additional help resolving between 'native:' and 'nativesdk:', by
way of the '_package' event field.

[YOCTO #10849]

(Bitbake rev: e455e40ba309837903b9e2d5f1dff55cce1135de)

Signed-off-by: David Reyna <David.Reyna@windriver.com>
Signed-off-by: brian avery <brian.avery@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-07 22:21:47 +00:00