Replace all print >> sys.stderr with logging in toolkit

This makes the toolkit error messages more useful when used as a library (e.g. by Pootle)