to get rid of; to free oneself; to escape
Él intentó idear un plan para librarse de las termitas.
He tried to devise a plan to get rid of the termites.
Él intentó librarse de las hormigas.
He tried to get rid of the ants.
No es fácil librarse de los malos hábitos.
It’s not easy to get rid of bad habits.
Hizo promesa tras promesa y luego trató de librarse de ellas.
He made promise after promise and then tried to get rid of them.
Es muy difícil librarse del hábito de fumar.
It is very difficult to break the smoking habit.