def METHOD_NAME():
    versions = {database_version}
    directories = set(glob.glob("/usr/share/lensfun/version_*") +
                      glob.glob("/usr/local/share/lensfun/version_*") +
                      glob.glob(os.path.join(lensfun.system_db_path, "version_*")))
    for directory in directories:
        if os.path.isdir(directory):
            try:
                versions.add(int(directory.partition("version_")[2]))
            except ValueError:
                pass
    return versions