Those are unarmed but aggressive foreigners. There are way to stop them entering your country in mass in a few hours without committing a massacre.
Western Europe has no problem using crowd control methods against their own people when they are protesting for good reasons (remember the gilets jaunes?).
But states like Spain are totally incompetent and corrupt. They won't hurt a few foreigners literally invading their country for the optics and do not care their own citizen get hurt as consequence.