2012-03-26 4 views
5

Sto cercando di utilizzare easy_install su windows7x64 e ottenere questo: c: \ Python27 \ Scripts> easy_install.exe django-pistone errore: non è possibile creare o rimuovere i file nella directory di installazione dicome cambiare percorso site-packages dir in easy_install

The following error occurred while trying to add or remove files in the 
installation directory: 

    [Errno 2] No such file or directory: 'C:\\Python27\\Lib\\site-packages\\Lib\ 
\site-packages\\test-easy-install-4132.pth' 

The installation directory you specified (via --install-dir, --prefix, or 
the distutils default setting) was: 

    C:\Python27\Lib\site-packages\Lib\site-packages\ 

This directory does not currently exist. Please create it and try again, or 
choose a different installation directory (using the -d or --install-dir 
option). 

Dove posso cambiare easy_install è percorso per correggere una "C: \ Python27 \ Lib \ site-packages"

Grazie.

risposta

8

easy_install deve installare i pacchetti nella directory dei siti del sito di installazione Python. Potrebbe essere accaduto che tu abbia cambiato accidentalmente la directory di Python. La reinstallazione di easy_install dovrebbe risolvere questo problema.

Altrimenti si potrebbe usare: easy_install --install-dir C:\Python27\Lib\site-packages\Lib\site-packages\ django-piston

Tuttavia, questa ultima opzione ha due problemi:

  1. assicurarsi C:\Python27\Lib\site-packages\Lib\site-packages\ è in PYTHONPATH
  2. Sarà necessario indicare una directory install-dir per ogni nuovo pacchetto installato