There's nothing inherently unethical (read: necessarily harmful) about building and selling facial recognition technology.
Nor is there anything inherently unethical (read: necessarily harmful) about manufacturing and selling opiates, narcotics, bombs, or guns.
The issue comes down to where along the product lifecycle you decide to end or limit the responsibility for how the product you build and design is used. And the mental calculations you do to weigh the positives/negatives of the technology you create and sell.
Obviously a manufacturer of bombs knows their product is going to be used to kill. If your code of ethics dictates that murder is bad, the calculation becomes - how "involved/complicit" am I in murder if I build the tools to murder, but don't use the tools myself. If we don't kill the bad guys, they might kill us. And hey, everyone in this society that pays taxes to fund these military and defense programs is complicit. I'm just doing what society needs to protect itself.
With facial recognition technology, if your code of ethics dictates that potential invasion of privacy/government tracking is bad, you would do a similar calculation. These people tracked are already in a database of "bad people" (aren't they? am I and my family in a database? do I have anything to hide?) - and society dictates we need this for our own protection, so what's the problem? If I make enough money selling these systems, I can buy my way to privacy, isn't that the way it should be?
Different people will come to different conclusions...there's no cut and dry answer, and infinite justifications for producing and selling any powerful technology/tool.