summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/utils.py
Commit message (Collapse)AuthorAgeFilesLines
* Resurrect the old bb.vercmp as bb.utils.vercmp, and its depsChris Larson2010-07-021-0/+143
| | | | | | | | | | This is just for compatibility. We may drop it in the future, or rewrite it, as it's not particularly pythonic. (Bitbake rev: c4e31d7fe1d15a1e3ef2a453e7c7812d403d22cb) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* Add & utilize a simple_exec utility functionChris Larson2010-07-021-0/+3
| | | | | | | (Bitbake rev: 5ead16f14f996bcbb2fb14277b8ce5a9317b8160) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* Consolidate the exec/eval bits, switch anonfunc to better_exec, etcChris Larson2010-07-021-4/+14
| | | | | | | | | | | | The methodpool, ${@} expansions, anonymous python functions, event handlers now all run with the same global context, ensuring a consistent environment for them. Added a bb.utils.better_eval function which does an eval() with the same globals as better_exec. (Bitbake rev: 424d7e267b009cc19b8503eadab782736d9597d0) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: Add bb.utils.join_deps to handle creation of dependency strings ↵Richard Purdie2010-06-301-0/+12
| | | | | | with versions Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: Move the logger initialization from cooker to utilsJeff Dike2010-06-291-0/+16
| | | | | | | | | | | | | | In order to move the environment cleaning, which wants to log a message, before cooker creation, the logging facility initialization needs to happen earlier. So, it is now in init_logger in utils.py and called from bitbake before the creation of the data object. It also seems more correct to initialize a global facility like this from a more global context than the creation of an object, of which there could theoretically be many. Signed-off-by: Jeff Dike <jdike@linux.intel.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* Fix 7 references to undefined variables, as spotted by pyflakesChris Larson2010-03-251-4/+3
| | | | | | | (Bitbake rev: e1e4ccf203e38070eeafd31a622671996cff61a1) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bb.utils: remove old portage remnantsChris Larson2010-03-251-571/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | The following utility functions were removed. Note that in this particular case we're bypassing a proper deprecation process, as these functions are clearly not utilized, are obvious remnants of old ways of doing things, and some of which do not even function properly. - tokenize - evaluate - flatten - relparse - ververify - isjustname - isspecific - catpkgsplit - pkgsplit - pkgcmp - dep_parenreduce - dep_opconvert (Bitbake rev: 62983ad9b151ee8d51e8cf9a31c736c7813edf16) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bb.utils: utilize string.letters and string.digitsChris Larson2010-03-251-5/+3
| | | | | | | (Bitbake rev: 7af05cba87ec9f3ea5e53689b3d9f0a63784d1b5) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bb.which: fix broken direction/reverse argumentChris Larson2010-03-251-1/+1
| | | | | | | (Bitbake rev: 4725d83f532cad96168aa9affdedb33b6fc897b7) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* utils: improve wording of error messageBernhard Reutner-Fischer2010-03-251-1/+1
| | | | | | | | (Bitbake rev: b2486ec57c6a7adf09d0960fdf6727881b324d2f) Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Chris Larson <clarson@kergoth.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* Fix msg usage in the moved utility functions.Chris Larson2010-03-221-15/+15
| | | | | | | (Bitbake rev: 686288444d22091dee66e20ec49b9c53f8c980b7) Signed-off-by: Chris Larson <clarson@kergoth.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* Move most utility functions from bb into bb.utils.Chris Larson2010-03-221-0/+759
| | | | | | | (Bitbake rev: ff720ec59b30671c951dbf3b96df10ef56b8b505) Signed-off-by: Chris Larson <clarson@kergoth.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: utils.py: Don't error if an exported environment variable is unset ↵Richard Purdie2010-02-121-1/+1
| | | | | | (i.e. None) Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: Switch to bitbake-dev version (bitbake master upstream)Richard Purdie2010-01-201-3/+17
| | | | Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: Add build_environment function for building an environment based on ↵Richard Purdie2009-07-021-0/+10
| | | | | | the data dictonary Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* bitbake: Add bb.utils.prune_suffix()Richard Purdie2008-12-311-0/+11
|
* bitbake/bitbake-dev: Sync with upstreamRichard Purdie2008-12-061-1/+0
|
* bitbake utils.py: Merge prunedir symlink fix from bitbake upstreamRichard Purdie2008-10-201-1/+4
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5551 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Add some sanity checks to the lockfile functionsRichard Purdie2008-10-171-0/+6
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5534 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Refactor the environment variable handlingRobert Bradford2008-10-171-0/+22
| | | | | | | Refactor the environment variable handling so that it more closes matches the changes that have been made in bitbake-dev. git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5527 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake utils.py: Fix ocassional locking glitch with a better retrying mechanismRichard Purdie2008-10-061-9/+12
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5415 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Add OEROOT to preserved_envvars_list.Joshua Lock2008-09-301-0/+1
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5351 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Sync with upstreamRichard Purdie2008-09-301-1/+1
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5350 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake/bitbake-dev: Allow much better control of which variable influence ↵Richard Purdie2008-09-301-0/+54
| | | | | | bitbake from the environment git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5347 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake/bitbake-dev: Sync with upstreamRichard Purdie2008-09-301-0/+1
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5346 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake utils.py: Add explode_dep_versions, an improved version of explode_depsRichard Purdie2008-09-031-0/+27
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5128 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake/utils.py: Add prunedir function to utils collectionRichard Purdie2008-08-181-0/+10
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5065 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Add md5_file and sha256_file checksum methods which use the builtin Python ↵Ross Burton2008-05-011-0/+31
| | | | | | checksum code git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4385 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Update to bitbake 1.8 branch headRichard Purdie2008-03-031-4/+4
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3892 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Sync with upstream, fix some typos, add selfstamp flagRichard Purdie2007-11-251-2/+2
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3227 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Add bb.utils.lockfile() and bb.utils.unlockfile()Richard Purdie2007-11-241-1/+36
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3221 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Update to 1.8.1 (inc. various bug fixes, epoch support)Richard Purdie2007-04-011-3/+5
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@1419 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Sync with upstream. Richard Purdie2007-01-081-15/+15
| | | | | | | | | | | | | * File licence headers were sanitised causing most of the diff. * cooker.py was created from bin/bitbake. * cvs fetcher port option was added * The -f force option was fixed to work correctly * Multiple entries in rrecrdeps are now handled correctly (allows adding do_deploy to image depends) git-svn-id: https://svn.o-hand.com/repos/poky/trunk@1129 311d38ba-8fff-0310-9ca6-ca027cbcb966
* bitbake: Upgrade from 1.4 -> 1.7.4ishRichard Purdie2006-11-161-7/+47
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@863 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Update to latest bitbakeRichard Purdie2006-03-201-3/+70
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@309 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Update bitbake to latest bitbake svnRichard Purdie2006-02-101-0/+24
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@262 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Initial populationRichard Purdie2005-08-311-0/+71
git-svn-id: https://svn.o-hand.com/repos/poky@2 311d38ba-8fff-0310-9ca6-ca027cbcb966