Possible meanings are 1) "The Lord will set up the king as a signal flag for the nations" or 2) "The king will set up a signal flag for the nations" (See: [[rc://en/ta/man/jit/figs-metaphor]])
The earth is pictured as if it has four corners, and those corners are its most distant places. This refers to everywhere on earth where those people might be. Alternate translation: "from even the most distant places of the earth" or "from all over the earth" (See: [[rc://en/ta/man/jit/figs-synecdoche]])