views:

74

answers:

3

I'm using FreeBSD 7.2. I upgraded to Python 2.6. However when I run any python app, it is still using /usr/local/lib/pytho25 as the library path. How do I change it? I cannot modify the python app. Basically I need to change the default lib path to python26.

+1  A: 

Are you sure you're using the new binary? I'm not familiar with FreeBSD, but with OpenBSD you have to do a ln -s /usr/local/bin/python2.6 /usr/local/bin/python if you want to start it as python. Perhaps it still points the old way? Also there is PYTHONPATH

knitti
A: 

You can creat a softlink to your desiered python executable:

$ cd /usr/bin
$ ln -s python2.6 python

This way python command points to python2.6

ssoler
A: 

You have probably not migrated correctly to python 2.6 as you should no longer have python 2.5

You can follow the UPDATING notes here to completely get rid of python2.5 (this is for python2.7 but you can safely follow those instructions):

http://www.freshports.org/lang/python27/

Antoine Pelisse