'Search name in all directories specified in lookup.
First without, then with common extensions. Return first hit.'

@classmethod
def search(cls, name, lookup=None):

    if (not lookup):
        depr('The    template    lookup    path    list    should    not    be    empty.', True)
        lookup = ['.']
    if (os.path.isabs(name) and os.path.isfile(name)):
        depr('Absolute    template    path    names    are    deprecated.', True)
        return os.path.abspath(name)
    for spath in lookup:
        spath = (os.path.abspath(spath) + os.sep)
        fname = os.path.abspath(os.path.join(spath, name))
        if (not fname.startswith(spath)):
            continue
        if os.path.isfile(fname):
            return fname
        for ext in cls.extensions:
            if os.path.isfile(('%s.%s' % (fname, ext))):
                return ('%s.%s' % (fname, ext))
