If it's on private land then you need a release even if entry is free. As to inside public buildings then it depends on bylaws governing that building, which can vary from place to place. You could always ask in these situations, which also apply to churches. If you are on public land when you take the shot you can do what you want with the image.