From: Karol M. L. <kar...@gm...> - 2011-03-26 15:27:07
|
On Sun, Feb 27, 2011 at 04:57:35PM -0600, Jim Parker wrote: > I agree the sudo su root is unusual, but doing it that way, the > installer then placed all documents in the dist-packages directory > rather than splitting some into site-packages which is not a default > path. Not a big issue as one can just add it as you mention to > .bashrc or other startup script. > > Cheers, > --Jim > > On Sun, Feb 27, 2011 at 3:32 PM, Noel O'Boyle <bao...@gm...> wrote: > > "sudo python setup.py install" was the correct way to install it. > > site-packages is the correct location, not dist-packages. The latter > > is a directly for packages from your distribution; the former for ones > > you install yourself. You should add site-packages to PYTHONPATH in > > your startup script (.bashrc or so), or complain to Ubuntu! :-) Noel is right. I also find this annoying, and what I do on Debian when manually installing Python modules is to always put them in /usr/local, where I additionally link site-packages to dist-packages in order to bypass this irritating behavior. You can do this by adding the --prefix option, like so: python setup.py install --prefix=/usr/local Note that you need to make the symbolic link from /usr/local/lib/python2.x/site-packages to /usr/local/lib/python2.x/dist-packages before this. - Karol -- written by Karol Langner Sat Mar 26 16:22:36 CET 2011 |