Yes, the combination "quarterstaff/spear + War Caster + Polearm Master" allows you to cast Booming Blade when someone enters your reach.
A comment by Mike Mearls from 2014 states that you are required to make the opportunity attack with an actual polearm - wielding a polearm in one hand doesn't allow you to make the polearm master opportunity attack with a non-polearm in your other hand.
No - polearm master applies only if you use the weapons it lists to make the attack.
In 2016, he came to the conclusion that combining Polearm Master, War Caster and Spell Sniper allows casting Booming Blade when someone gets within 10 ft. of you.
This fits within the view that an attack with the polearm listed weapon would need to be part of the spell for it to work.
Note that Mearls rulings aren't considered official, only Jeremy Crawford's are, and RAW, you don't have to use a polearm for the attack.
Anyhow, without the feat Spell Sniper or another feature that increases Booming Blade's range to 10ft (such as a Sorcerer's Distant Spell metamagic option), you can only combine Booming Blade with a quarterstaff or a spear if you want the polearm master opportunity attack.
This
This is because the feat says "You can keep your enemies at bay with reach weapons". This implies that letting them get close to 5ft, even though your reach is 10ft, is against the wording of the spell since you're not keeping them at bay with a reach weapon in that case.
Using Spell Sniper allows you to extend the range of Booming Blade to 10 ft, which allows you to satisfy both requirements. You are keeping them at bay, and you are using a reach weapon listed in the feat.