Fix python and perl extensions.