Update distribution scripts to python3