Age | Commit message (Collapse) | Author |
|
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Using "1" with getVar is bad coding style and "True" is preferred.
This patch is a sed over bitbake directory of the form:
sed \
-e 's:\(\.getVar([^,()]*, \)1 *):\1True):g' \
-e 's:\(\.getVarFlag([^,()]*, [^,()]*, \)1 *):\1True):g' \
-i `grep -ril getVar *`
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
(From Poky rev: affd0907253387cee0ba0c7e9f92bcc109895446)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
The common case (if not the only case) is to only use a single domain. The
only reason SQLData exists is to make it easier to delete a domain. Yet,
there's no need for us to delete a domain if SQLTable knows how to clear
itself out. So, add clear() to the table and pass the domain to persist().
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
there is case that we need to distingush bb.fetch and bb.fetch2,
and use different API for bb.fetch and bb.fetch2. so it is necessary
to add version info for distinguish purpose
(From Poky rev: f12e71484593039cd58b6e7fadd038b28b05d849)
Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Current fetcher has annoying "SRCREVINACTION" deadlock,
which occurs when SRCREV=${AUTOREV}=@bb.fetch.get_srcrev():
get_srcrev()->setup_localpath()->srcrev_internal_helper()
->evaluate SRCREV->get_srcrev()
current fetcher resolve the deadlock by introducing a
"SRCREVINACTION" condition check. Althoguh it works, it is
indeed not clean.
This patch use antoehr idea to break the deadlock: break
the dependency among SRCREV and get_srcrev(), i.e. assign
a specific keyword "AUTOINC" to AUTOREV. when Fetcher meet
this keyword, it will check and set the latest revision to
urldata.revision. get_srcrev later can use the urldata.revision
for value evaluation(SRCPV etc). In this case, SRCREV no longer
depends on get_srcrev, and there is not deadlock anymore.
(From Poky rev: 1589a1172f9432aed1cc9ce006f68cddf3073774)
Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
This allows fetching git repositories using Kerberos authentication.
Signed-off-by: Javier Martin <javier.martin@vista-silicon.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Use '==' instead of 'is', otherwise it will always return
true since 'rev' and "SRCREVINACTION" are not the same object.
Signed-off-by: Javier Martin <javier.martin@vista-silicon.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
This patch adds per-recipe SRC_URI checksum verification.
- SRC_URI format
The format of SRC_URI checksum follow OE definition:
1. SRC_URI has single src
SRC_URI = "http://some.domain/file.tar.gz"
SRC_URI[md5sum] = "xxxxxxxxxxxxxxx"
SRC_URI[sha256sum] = "xxxxxxxxxxxxxxxxxxxxxx"
2. SRC_URI has multiple src, every src need specify name
SRC_URI = "http://some.domain/file1.tar.gz;name=name1 \
http://some.domain/file2.tar.gz;name=name2 "
SRC_URI[name1.md5sum] = "xxxxxxxxxxxxxxx"
SRC_URI[name1.sha256sum] = "xxxxxxxxxxxxxxxxxxxxxx"
SRC_URI[name2.md5sum] = "xxxxxxxxxxxxxxx"
SRC_URI[name2.sha256sum] = "xxxxxxxxxxxxxxxxxxxxxx"
- SRC_URI checking invocation:
the checksum checking is invoked in do_fetch phase,
so it can be invoked manually by
if recipes has no SRC_URI checksum item, bitbake will show warning:
"
WARNING: Missing SRC_URI checksum for xxxx.tar.gz, consider to add
SRC_URI[md5sum] = "5c69f16d452b0bb3d44bc3c10556c072"
SRC_URI[sha256sum] = "f4e0ada8d4d516bbb8600a3ee7d9046c9c79e38cd781df9ffc46d8f16acd1768"
"
thus recipe author can add it to recpie file after SRC_URI
- control variable BB_STRICT_CHECKSUM
when SRC_URI checksum is missing, this variable decide pass or not
if BB_STRICT_CHECKSUM = "1", missing checksum is fatal
Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
expanded
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
Retains backward compatibility.
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
- Moved the logic for comparing revisions from cooker into command
- Removed 'Cooker' from the event names
- Renamed the 'ExitCode' event into CommandExit, and changed CommandFailed to
be a subclass of CommandExit
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
- bitbake/fetch: Allow checking of a single url at a time (massive sstate
speed improvement)
- bitbake/fetch: Fix handling of mirrors when checking for url validity
- bitbake/fetch: When fetchers return errors, ensure any partial download is
cleared
- bitbake/fetch: Make URL checking slightly less verbose (distracting with the
sstate code)
- bitbake/fetch/git: Ensure fullclone repositories are fully fetched
- bitbake/fetcher: Deal with a ton of different bugs
- bitbake/fetch/git.py: Fix git fetcher to correctly use mirror tarballs
- bitbake/fetch/__init__.py: Abstract mirror variable handling and enhance to
accept \n delimitation in variables
- bitbake/fetch: fix logic to prevent fetches when the file already exists
- bitbake/fetch: ensure the go() method completes when not using premirrors
- Export ALL_PROXY for bitbake commands
- bitbake: Add proxy variables to standard export list
- bitbake/fetch/git: fix try_premirror() definition .Method takes 4
parameters.
- bitbake/fetch: fix by moving try_premirror() to the right place
- bitbake/fetch: add try_premirror method and special case git fetcher
- fetch: fix setting of localpath in SRC_URI parameters
- bitbake/fetch: ensure the mirrored repository is updated as required
- bitbake/git: define a forcefetch method
- bitbake/fetch: Respect forcefetch even when pulling from a mirror
- bitbake/git.py: Make sure different branches can have different revisions
without triggering build count increases
- bitbake/git.py: Allow tracking of branches in SRC_URI without cloning for
use with fullclone
- bitbake/git.py: Make sure a full clone checkout always updates
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Caching the database connection can cause serious issues if it results in
multiple processes (e.g. multiple tasks) simultaneously using the same
connection.
This reverts commit 8a6876752b90efd81d92f0947bfc9527d8260969.
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
no functional changes
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Several fetcher need a way to strip leading slashes off a local path.
This helper-function consolidates all such occurances.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
osc had it already spelled correctly?!
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
We catch any exception raised by the fetchers go() method and attempt to work
around it by trying any (post) mirrors which are configured. However, should
the mirrors fail the exception is lost and the fetch is assumed to have
completed successfully.
Instead, save the exception and if the local file does not exist after trying
the mirrors re-raise the exception.
Fixes poky [BUGID #362]
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
We use a custom Logger subclass for our loggers
This logger provides:
- 'debug' method which accepts a debug level
- 'plain' method which bypasses log formatting
- 'verbose' method which is more detail than info, but less than debug
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
(From Poky rev: 36cfff8ed5b8a777a09cc8abcd8b01a1f297e404)
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Without this patch decoding a url of this kind file://dir/filename gives
path=/filename host=dir.
With the patch it decodes as path=/dir/filename host=""
Probably nobody stumbled on this issue yet because nobody used
file:// urls with directory names in the path.
(From Poky rev: c3682bf89bdf236a4b4d834069d947b6a1456791)
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
|
|
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
* Fixes proxy support to honor standard proxy environment variables.
* Quote environment variables
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Store database connection to persistent database in fetcher.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
s/initilize/initialize/
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
types.IntType -> int
types.StringType -> basestring
...
Also moves our ImmutableTypes tuple into our own namespace.
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
We should add back in some proper unit testing. Doctest is rather limited,
and we haven't actually made use of it since the original implementation of
the datastore when the project started, as far as I'm aware.
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
When not expanding PREMIRRORS, the functions fails/does not work correctly
when PREMIRRORS is not a plain string (e.g. contains ${...} or a ${@...}
statements).
Signed-off-by: Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
Signed-off-by: Chris Larson <clarson@kergoth.com>
|
|
dict objects provide an __iter__ method for the iteration which gives you the
keys, so calling keys directly is unnecessary, and isn't really a best
practice. The only time you really need to call the keys is if there's a
danger of the dict changing out from underneith you, either due to external
forces or due to modification of the iterable in the loop. Iterations over
os.environ are apparently subject to such changes, so they must continue to
use keys().
As an aside, also switches a couple spots to using sorted() rather than
creating a temporary list with keys() and sorting that.
Signed-off-by: Chris Larson <clarson@mvista.com>
|
|
Signed-off-by: Tom Rini <tom_rini@mentor.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
|
|
Signed-off-by: Chris Larson <clarson@kergoth.com>
|
|
Signed-off-by: Chris Larson <clarson@kergoth.com>
|
|
The previous bitbake change included an invalid method call and inverted logic.
(From Poky rev: 52cbb074235fc7b1bcd94bc1147c4607612fe701)
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
checkstatus() is used to ensure we can fetch a copy of each file, so it makes
sense to also test PREMIRRORS and MIRRORS in the method.
This patch adds calls to try_mirrors() to the Fetch.checkstatus() method and
changes the try_mirrors() method to take a check argument, which is False by
default. When check is True try_mirrors() will call a fetchers checkstatus()
with the replaced uri.
(From Poky rev: ec92133d6fc049b4b666d670d3ac263de5a1d103)
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|
|
The logic in try_mirrors() was buggy such that only the first entry in the
mirrors list was tried.
This patch fixes this. Thanks to Richard for the review.
(From Poky rev: c9fd126f64ec57cc0799ad03f32f509b5266e0ff)
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
|