summaryrefslogtreecommitdiffstats
path: root/lib
AgeCommit message (Collapse)Author
2011-01-10runqueue.py: Add debug to help resolve partial log message failureRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10runqueue.py: Add missing result return value in setscene failure pathRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10runqueue.py: Fix up some lost range->xrange conversions misplaced as part of ↵Richard Purdie
the poky sync up Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10fetch/__init__.py: Add missing debug level argumentRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bitbake/siggen.py: Add a signature generator which adds the hash to the ↵Richard Purdie
stamp files (From Poky rev: 97789a160ad21ccc614f976fa5e2b306d816aabf) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bitbake build/siggen/runqueue: Fix stampfile parametersRichard Purdie
The current parameters are not useful to the stampfile generator function as they can't uniquely define a task. This updated things so the parameters can identify unique tasks. (From Poky rev: 66c6200ff34e8eeca5d1a689bbf9d6a83818248f) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bb.utils: check if lock file is writable, to fix Yocto bug 606Yu Ke
Bug 606 report that if $DL_DIR is read-only, do_fetch will simply hang without any error message. The root cause is that: bb.fetch.go()->bb.utils.lockfile() will try to lock file ${DL_DIR}/xxxxx.lock. Since ${DL_DIR} is read-only, it will cause IOError exception. Although lockfile() can catch the exception, currently code simply ignore all the exception and continue the loop. it make sense if the exception is caused by locking contention, but in the read-only $DL_DIR case, it cause endless waiting unfortunately. So this patch add read-only check for lockfile to avoid the silent hang. (From Poky rev: 6ee0c26e21f48dcd47af88ed5c174e76e76a3e42) Signed-off-by: Yu Ke <ke.yu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bitbake/knotty.py: Don't show log messages of NOTE and below for task processesRichard Purdie
This cleans up the knotty console messages to be a lot quieter and cleaning, in keeping with the expectations of most users. (From Poky rev: b22e345e05efcc3f66278af8f09fb083afe32b68) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bitbake/__init__.py: Add taskpid to all LogRecords (subclassed to be ↵Richard Purdie
BBLogRecords) This allows us to identify which task messages are from. (From Poky rev: f8e7215f6c4ece8c0a74ceee8da707cf791038e8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-10bitbake/msg.py: Add named definitions for all logging levelsRichard Purdie
(From Poky rev: a13352cfaf4b5d19196151e362851b1516e6af15) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-07Merge branch 'poky-sync'Chris Larson
* poky-sync: build: kill unneeded environment setup bits parse: save python functions into the metadata Include exported variables in task process env runqueue: start implementing quieterrors Overhaul environment handling runqueue: resurrect use of file objects for pipein/pipeout runqueue: clean up message log levels runqueue: use correct task ID when checking validity of setscene tasks Add support for 'noexec' tasks runqueue: implement cache checking from metadata runqueue: pass task hash information to tasks runqueue: avoid unnecessary delays Implement task signatures data: Add emit_func and generate_dependencies codeparser: Implement persistent cache data_smart: track variable references codeparser: add module for parsing shell/python runqueue: implement scenequeue fetch: add SRC_URI checksum Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-07cache: don't expand variables for skipped recipesChris Larson
Errors can result from these expansions, but for skipped recipes, we shouldn't care about those failures. This fixes the same issue which Richard Purdie fixed in poky, commit 847b717. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-07bitbake/build.py: Fix del_stamp work correctly after recent stamp function ↵Richard Purdie
changes (From Poky rev: 5da9747) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-07bitbake/data.py: corrected the output for shell syntax.Lianhao Lu
[BUGID# 645], modify the emit_var() 1. Added "#" to the beginning of each line if the comment contains multiple lines. 2. Added "\" to the end of each line if the shell variable value contains multiple lines. (From Poky rev: 6f454c10bcdd5) Signed-off-by: Lianhao Lu <lianhao.lu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-06bitbake build.py: Stamp handling improvementsRichard Purdie
* Move stamp file deletion out of the internal stamp helper function * Add a new function to return the path to a stamp for a given task (From Poky rev: ec6e4793dc79c61b780b74571db4cd66c1c04251) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-06bitbake build.py: Use localdata for stamp handling, not dRichard Purdie
(From Poky rev: 4a10a5b438f49577fb29f4e277e2300cdce10ab8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-06bitbake/build.py: Ditch the extract_stamp function as its just going to ↵Richard Purdie
complicate improving the stamp handling functions (From Poky rev: 51a2e8712a9b94de53253e198c64c0fa428e4349) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-01-05parse: pass filename, lineno into the astChris Larson
We will be needing this information to improve the tracebacks of python code from the metadata, as well as to give the user information about where variables were defined, so they know how it ended up the way it is. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-05parse.ast: drop __word__ regular expressionChris Larson
We can use the string split method for this instead. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-05parse.ast: avoid code duplication for inheritChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-05process: simplify the log option for runChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-05event: use BBLogFormatter in print_ui_queueChris Larson
This ensures that when a failure occurs very early on in bitbake startup, the message formatting ematches that used by the UIs. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-05build: use logger.isEnabledFor, not getEffectiveLevelChris Larson
I think this is less confusing, and avoids needing to know about the *range* of logging levels, instead simply asking what we really want to know. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-04build: kill unneeded environment setup bitsChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2011-01-04ConfHandler: commentary typo fixesBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2011-01-04event: fix unicode handler registrationBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2011-01-04cache: defer marking fn as cleanBernhard Reutner-Fischer
Only mark fn as clean if it is clean. This saves us from removing (prematurely added) fn from our clean set and saves me a few percent of runtime (and misleading debugging output from remove()). Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2011-01-04BBHandler: use basename directly in handler()Bernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2011-01-04data: fewer newlines for (un)exportBernhard Reutner-Fischer
Previously we emitted two newlines for export and unexport. One newline for export and unexport is enough (and makes the scripts look better and a tad smaller). Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2011-01-04parse: Use constants from stat instead of magic numbersBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-30parse: save python functions into the metadataRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-30Include exported variables in task process envChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29runqueue: start implementing quieterrorsChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29Overhaul environment handlingRichard Purdie
Currently, anything whitelisted in the environment makes it into the worker processes. This is undesireable and the worker environment should be as clean as possible. This patch adapts bitbake sosme variables are loaded into bitbake's datastore but not exported by default. Any variable can be exported by setting its export flag. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com> Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29runqueue: resurrect use of file objects for pipein/pipeoutChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29runqueue: clean up message log levelsRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29runqueue: use correct task ID when checking validity of setscene tasksKevin Tian
sstate hash validation is done at initialization of RunQueueExecuteScenequeue. However the index of 'valid' list returned from the validation doesn't correspond to setscene task ID. It's just an intermediate namespace between runqueue and sstate hash func. Use it as setscene task ID fully mess the flow. Previously this doesn't cause trouble because all setscene tasks are passed. Commit 58396a5d24c62710fd0a9f3780d84ac8a95d8e7c add 'noexec' concept to setscene tasks which grabs some tasks out of the list and thus trigger this problem Without this fix there're ~50 recipes (gzip-native, glib, ...) rebuilt weirdly with a minimal build, even though existing sstate packages could accelerate them. there's another typo using wrong task ID in a debug message which further hide this issue Signed-off-by: Kevin Tian <kevin.tian@intel.com>
2010-12-29Add support for 'noexec' tasksRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29runqueue: implement cache checking from metadataRichard Purdie
This lets us speed up setscene processing, by letting the function from the metadata inform us about the necessity of running the setscene functions. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29runqueue: pass task hash information to tasksRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com> Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29runqueue: avoid unnecessary delaysRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com> Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29Implement task signaturesRichard Purdie
Includes functionality to find out what changes between two different signature data dumps. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com> Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29data: Add emit_func and generate_dependenciesRichard Purdie
These functions allow generation of dependency data between functions and variables allowing moves to be made towards generating checksums and allowing use of the dependency information in other parts of bitbake. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29codeparser: Implement persistent cacheRichard Purdie
For a given input to this code, the output doesn't change to implement a persistent cache of the data to speed up parsing. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29data_smart: track variable referencesRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29codeparser: add module for parsing shell/pythonRichard Purdie
This commit is derived from Chris Larson's checksum work, turned into a standalone piece of code for parsing python and shell functions. The deindent code has been replaced with code to work around indentation for speed. The original NodeVisitor in the ast was replaced with a faster class walk call. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29runqueue: implement scenequeueRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-12-29fetch: add SRC_URI checksumYu Ke
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>
2010-12-29process: fix handling of the input argumentChris Larson
When using a logfile, we weren't sending input to the child process. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-12-29fetch: handle no sortable_buildindex for gitChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>