Migrated SearchEngine (compilation broken in one point).
Minor refactor for common.