Reads the file and obtains its metadata"""
-import re, oe, string, os, sys
-import oe
+import re, oe, os, sys
import oe.fetch
from oe import debug, data, fetch, fatal
if file[0] != "/" and file[-8:] != ".oeclass":
file = "classes/%s.oeclass" % file
- if not file in string.split(__inherit_cache):
+ if not file in __inherit_cache.split():
debug(2, "OE %s:%d: inheriting %s" % (fn, lineno, file))
__inherit_cache += " %s" % file
include(fn, file, d)
if ext != ".oeclass":
data.setVar('FILE', fn, d)
- import string
- i = string.split(data.getVar("INHERIT", d, 1) or "")
+ i = (data.getVar("INHERIT", d, 1) or "").split()
if not "base" in i and __classname__ != "base":
i[0:0] = ["base"]
inherit(i, d)
if __infunc__:
if s == '}':
__body__.append('')
+ data.setVar(__infunc__, '\n'.join(__body__), d)
data.setVarFlag(__infunc__, "func", 1, d)
data.setVar(__infunc__, string.join(__body__, '\n'), d)
if __infunc__ == "__anonymous":
# set up deps for function
data.setVarFlag(var, "deps", after.split(), d)
if before is not None:
- # set up things that depend on this func
+ # set up things that depend on this func
data.setVarFlag(var, "postdeps", before.split(), d)
return
return (None, None, None)
if mypkg in __pkgsplit_cache__:
return __pkgsplit_cache__[mypkg]
-
+
myfile = os.path.splitext(os.path.basename(mypkg))
- parts = string.split(myfile[0], '_')
+ parts = myfile[0].split('_')
__pkgsplit_cache__[mypkg] = parts
exp = 3 - len(parts)
tmplist = []
a += fetch.localpaths(d)
del fetch
- data.setVar('A', string.join(a), d)
+ data.setVar('A', "".join(a), d)
# Add us to the handlers list