Yes, I think it did. I think Brandon the Builder was the Lone Hero, Azor Ahai, etc. who befriended the giants, learned the earth-magic of the Children, and used it to build a big fortress which could withstand the Long Night, and prevent the Others from over-running all of Westeros by making them besiege Winterfell.
The protected heart tree acted as a tap into the weirwood.net, giving Brandon access to the combined powers of all of the greenseers. That gave Brandon the power/knowledge/whatever he needed to make Lightbringer, which he used to throw back the Long Night with the help of the Night’s Watch.
When the Battle for the Dawn was over, Brandon decided to put a giant Wall between his people and the Others, and enchant that wall so that the Others couldn’t cross it again (at least not without permission; there’s some vampiric thing going on with the Night’s King and Queen). And my guess is that the Free Folk on the other side were either collateral damage and/or people who had survived the omnicidal Others by giving them human sacrifices.