Python 3 fixes for dlib on Unix