Add Python 3.3 support.

- Adds Python 3.3 support
- Refactor Python 2.7 code to move code shared with 3.3 into a shared directory

[test]