The right dog will keep them away.
Has to be a smart dog tho, otherwise they will lure it out and kill it. Growing up we had an Australian shepherd/ Golden retriever cross that did the trick. He would bark and growl at them all night some times but he wouldn't go farther than maybe 10 yards from the house.
They're not too hard to shoot if youre able and patient. Never gonna shoot them all but as smart as they are they will learn to be leary of your property at least.