Enable threads

http://blog.notdot.net/2011/10/Migrating-to-Python-2-7-part-1-Threadsafe