The problem is that North Korea is backed by China. It has a real military, airports, small navy etc. There's only so far North Korea can go before China yanks it back. Hamas doesn't have that. It's not a real State. Yes, Iran and other anti-Israel interests send money in and what weapons they can, but it's unofficial. Since neither the U.S. nor Israel have diplomatic relations, let alone trade, they can't push Iran to restrain Hamas. All that has been what's made this such an intractable problem. A lot of cards are hidden. Anyway, Israel did built a border. It does keep Hamas contained. Has done that. It's one of the points I've made over and over again.
The kind of wall you want built would mean starving everyone in Gaza to death.