Common practice for multiple python versions sharing 3rd party modules

  • Thread starter Daniel Fetchinson
  • Start date
D

Daniel Fetchinson

Hi folks,

In order to test my own modules with various python versions I've
installed python 2.4, 2.5, 2.6, 2.7, 3.1, 3.2. The original
installation on my fedora box was 2.6 and all 3rd party modules so far
were installed under /usr/lib/python2.6/site-packages. Since now the
executable 'python' points to python 2.7 and lot of programs have
#!/usr/bin/env python at the top, these programs try to use 2.7. But
there are no 3rd party modules installed for 2.7 so programs that need
these do not run. Of course I can just replace #!/usr/bin/env python
with #!/usr/bin/env python2.6 but doing so for all programs would be a
pain.

Also, once I have a 3rd party module installed in
/usr/lib/python2.6/site-packages I wouldn't want to copy all of these
to /usr/lib/pythonX.Y/site-packages (assuming they are compatible with
pythonX.Y).

What would be the most common practice for having a single location
for 3rd party modules and all python versions could have access to
them?

Cheers,
Daniel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,967
Messages
2,570,148
Members
46,694
Latest member
LetaCadwal

Latest Threads

Top