It's less likely such an alignment happens by chance. If you do observe it, it's reasonable to look for explainations. A ritual use is of course not the only reason, there could be other features in the site (geological or otherwise natural e.g rivers, pre-existing man made artifacts like roads etc) which may have imprinted a direction on the building