How can I change the default search engine in Safari?

The AnySearch extension allows you to set any search engine you want.

It achieves it by listening to the beforeSearch event, canceling the default behaviour and checking your settings for your chosen search engine. Then it puts your query into the specified search engine and displays the results.

You could, too, edit the host file, redirecting form any of the default search engines to the one you want, but that wont be so neat.