Added python3 compatible print and exceptions.

Signed-off-by: Petr Kubat <pkubat@redhat.com>
make c extension python3 compatible
minor changes to python extension makefiles