detect python2 as Python 2 binary

On some distributions like Arch Linux
"python" is Python 3 and "python2" is Python version 2.

This change in `configure` tries "python2" first and uses it if available.