'Builds a CompilationDatabase from the database found in buildDir'

@staticmethod
def fromDirectory(buildDir):

    errorCode = c_uint()
    try:
        cdb = conf.lib.clang_CompilationDatabase_fromDirectory(encode(buildDir), byref(errorCode))
    except CompilationDatabaseError as e:
        raise CompilationDatabaseError(int(errorCode.value), 'CompilationDatabase    loading    failed')
    return cdb
