Комбинация
sudo apt-get install python-dev
и
export LC_ALL=C pip install --upgrade setuptools
решила мою проблему.