I want to play a sound based on my ultrason sensor reading
#define buzzerPin = 10 shouldn't have an = in it.

With the = pinMode(buzzerPin, OUTPUT); will turn into pinMode(= 10, OUTPUT); by the pre-processor. Which would give the error, complaining about an = token, you got.