143 def anaLib(lib, opt, cache, select = [], ignore = [], depth = 0):
144 """Get dependencies of shared library recursively"""
147 """Should this lib be processed?"""
148 for regexp
in select:
149 if regexp.match(path):
return True
150 if len(select)>0:
return False
152 for regexp
in ignore:
153 if regexp.match(path):
return False
156 if opt.maxdepth
and depth>=opt.maxdepth:
return
159 cachedlib = cache.myfiles.get(lib)
162 if depth<cachedlib.distance: cachedlib.distance=depth
165 shlib = SharedLib(depth, lib)
168 for l
in shlib.deplibs:
171 anaLib(l, opt, cache, select, ignore, depth+1)