To me, the parallel between the two is summed up in the phrase "something there is that doesn't love a wall." In the poem, Frost's speaker is saying that he does not like the idea of building walls between people. In the Pink Floyd song, the speaker is arguing that the bad actions of other people have built a wall that is separating the young from those in authority over them.
In the Frost poem, the speaker thinks that everyone should be able to get along without having walls between them. In the song, the speaker is wishing that the wall had not been built and that the teacher's did not play their part in building that wall.
The writer in "another brick in the wall" is voluntarily building a wall around himself to keep out memories of WWII and the death of his father, the cruel school headmaster, his failures. And to protect himself while Frost is lamenting his neighbor wanting to maintain the physical and emotional wall that lies between the neighbors.