+
+def search_file(filename, search_path):
+ """Given a search path, find file"""
+ file_found = 0
+ paths = split(search_path, pathsep)
+ for path in paths:
+ for current_dir, directories, files in os.walk(path):
+ if exists(join(current_dir, filename)):
+ file_found = 1
+ break
+ if file_found:
+ return abspath(join(current_dir, filename))
+ else:
+ return None
+