All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad is His slave and Messenger.
Selling bricks is permissible and there is nothing wrong with it. It is not a condition on you to ask the buyer about his purpose of building. If someone buys bricks and builds a house with it and then does something forbidden in it, then there is no sin on you for that.
Allah Knows best.