Failed to execute pip install / usr / bin / clang command: no such file or directory

I am migrating my dev environment to 10.8, however I am having problems with pip.

In particular, I use virtualenvs / virtualwrapper, but I can’t pip install psycopg2 , and while creating the psycopg2._psycopg extension psycopg2._psycopg I get:

 unable to execute /usr/bin/clang: No such file or directory error: command '/usr/bin/clang' failed with exit status 1 

Can anyone suggest a solution?

+8
pip postgresql osx-mountain-lion psycopg2
source share
1 answer

This probably happens because you did not reinstall the command line tools after the upgrade.

Normally, Xcode should be updated to the latest version (4.4) (I believe that when I upgraded to 10.8, I also updated a whole bunch of other applications, including Xcode). After the upgrade, you need to reinstall the command line tools. Now this can be done using the settings in Xcode:

Go to "Settings β†’ Downloads" and install "Command Line Tools".

Now you will no longer have problems installing packages that need to be compiled.

+12
source share

All Articles