correctly search for definitions directories

Signed-off-by: Alfredo Deza <alfredo@deza.pe>