Actually building walls seems to be en vogue nowadays. Quite a few countries have erected thousands of miles of walls in the last 75 years (with most of them in the last 30 or so)
Hmm... border walls protecting nations.
Hadrian's wall, ca. 122 Roman empire beginning to decline, needed defenses. Barbarians went around it, in boats.
Great Wall of China, finished out around 200 BC. Chinese government not able to combat mounted barbarians. Barbarians used it as a convenient highway to move along the border, striking rapidly here and there.
Hexamillion wall around 400. Meant to protect the declining Roman Empire from barbarians. Later rebuilt to protect it from Ottomans, who breached it twice.
During its history, the wall never succeeded in fulfilling the function for which it was constructed, unless it acted as a deterrent.
Hexamilion wall - Wikipedia
Maginot Line. French army, fearful of German military, decided on a defensive tactic. Germans went around it.
Seigfried line. As the Third Reich began to lose ground, meant to protect Germany. Allies breached it in numerous places.
Berlin wall. Much shorter and easier to defend. Put up by East Germans, fearful of losing population. Fell a few decades later by mob action.
So always the tactic of nations that have lost their nerve and confidence, seeking some visible sign of strength, rather than seeking to regain strength.
and there seem to be more going up all the time. There are different reasons for erecting these walls but the theme seems to be to keep something in or out.
Always the hope. You see the results.
Israel is building fences. Because the walls didn't work as hoped.
You really have to wonder why so many countries are erecting them if they don't work?
See above.