summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2009-05-12 16:53:22 +0100
committerMarcin Juszkiewicz <marcin@buglabs.net>2009-07-28 13:57:22 +0200
commitd2c268aec84caa3034a4e6e177938afc4fe01f98 (patch)
treee532cebed4df49d0d8e533e3a5b7053b960a4120
parentf73dc1bf2aa9791cfd078f158d6ad3349107899c (diff)
downloadpoky-d2c268aec84caa3034a4e6e177938afc4fe01f98.tar.gz
poky-d2c268aec84caa3034a4e6e177938afc4fe01f98.tar.bz2
poky-d2c268aec84caa3034a4e6e177938afc4fe01f98.zip
bitbake: Update to work without warnings with python 2.6
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
-rw-r--r--bitbake/lib/bb/COW.py4
-rw-r--r--bitbake/lib/bb/cache.py3
-rw-r--r--bitbake/lib/bb/cooker.py3
-rw-r--r--bitbake/lib/bb/data_smart.py5
-rw-r--r--bitbake/lib/bb/runqueue.py7
5 files changed, 9 insertions, 13 deletions
diff --git a/bitbake/lib/bb/COW.py b/bitbake/lib/bb/COW.py
index e5063d60a8..5db41776ec 100644
--- a/bitbake/lib/bb/COW.py
+++ b/bitbake/lib/bb/COW.py
@@ -26,7 +26,7 @@
from inspect import getmro
import copy
-import types, sets
+import types
types.ImmutableTypes = tuple([ \
types.BooleanType, \
types.ComplexType, \
@@ -35,7 +35,7 @@ types.ImmutableTypes = tuple([ \
types.LongType, \
types.NoneType, \
types.TupleType, \
- sets.ImmutableSet] + \
+ frozenset] + \
list(types.StringTypes))
MUTABLE = "__mutable__"
diff --git a/bitbake/lib/bb/cache.py b/bitbake/lib/bb/cache.py
index 7d7e66ebd2..82efada67d 100644
--- a/bitbake/lib/bb/cache.py
+++ b/bitbake/lib/bb/cache.py
@@ -31,7 +31,6 @@
import os, re
import bb.data
import bb.utils
-from sets import Set
try:
import cPickle as pickle
@@ -431,6 +430,6 @@ class CacheData:
(set elsewhere)
"""
self.ignored_dependencies = []
- self.world_target = Set()
+ self.world_target = set()
self.bbfile_priority = {}
self.bbfile_config_priorities = []
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 2c091b6522..f7ce8258b6 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -25,7 +25,6 @@
import sys, os, getopt, glob, copy, os.path, re, time
import bb
from bb import utils, data, parse, event, cache, providers, taskdata, runqueue
-from sets import Set
import itertools, sre_constants
parsespin = itertools.cycle( r'|/-\\' )
@@ -540,7 +539,7 @@ class BBCooker:
self.status = bb.cache.CacheData()
ignore = bb.data.getVar("ASSUME_PROVIDED", self.configuration.data, 1) or ""
- self.status.ignored_dependencies = Set( ignore.split() )
+ self.status.ignored_dependencies = set( ignore.split() )
self.handleCollections( bb.data.getVar("BBFILE_COLLECTIONS", self.configuration.data, 1) )
diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py
index e879343f5d..8d48714720 100644
--- a/bitbake/lib/bb/data_smart.py
+++ b/bitbake/lib/bb/data_smart.py
@@ -32,7 +32,6 @@ import copy, os, re, sys, time, types
import bb
from bb import utils, methodpool
from COW import COWDictBase
-from sets import Set
from new import classobj
@@ -142,7 +141,7 @@ class DataSmart:
try:
self._special_values[keyword].add( base )
except:
- self._special_values[keyword] = Set()
+ self._special_values[keyword] = set()
self._special_values[keyword].add( base )
return
@@ -157,7 +156,7 @@ class DataSmart:
if '_' in var:
override = var[var.rfind('_')+1:]
if not self._seen_overrides.has_key(override):
- self._seen_overrides[override] = Set()
+ self._seen_overrides[override] = set()
self._seen_overrides[override].add( var )
# setting var
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index 9d72d92fac..ffd28e15ab 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -23,7 +23,6 @@ Handles preparation and execution of a queue of tasks
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
from bb import msg, data, event, mkdirhier, utils
-from sets import Set
import bb, os, sys
import signal
@@ -484,8 +483,8 @@ class RunQueue:
self.runq_fnid.append(taskData.tasks_fnid[task])
self.runq_task.append(taskData.tasks_name[task])
- self.runq_depends.append(Set(depends))
- self.runq_revdeps.append(Set())
+ self.runq_depends.append(set(depends))
+ self.runq_revdeps.append(set())
runq_build.append(0)
@@ -579,7 +578,7 @@ class RunQueue:
if maps[origdep] == -1:
bb.msg.fatal(bb.msg.domain.RunQueue, "Invalid mapping - Should never happen!")
newdeps.append(maps[origdep])
- self.runq_depends[listid] = Set(newdeps)
+ self.runq_depends[listid] = set(newdeps)
bb.msg.note(2, bb.msg.domain.RunQueue, "Assign Weightings")