proposal - move bzrlib down a level

Aaron Bentley aaron.bentley at utoronto.ca
Mon Sep 5 01:32:36 BST 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Robert Collins wrote:
> On Thu, 2005-09-01 at 09:49 -0400, Aaron Bentley wrote:

>>So if you actually install bzrlib, you don't have to muck with your
>>PYTHONPATH, and there's no garbage.  (btw, is there *any* satisfactory
>>way to muck with one's PYTHONPATH?  I don't want to stick the whole
>>thing in my profile because I run more than one interpreter, and the
>>system libs vary.)
> 
> 
> install it where ?

I would suggest in the home directory of the user pqm runs as.

python2.4 setup.py install --prefix ~

> Take for instance the pqm install @ pqm.ubuntu.com.
> I'm not the sysadmin, so I can't install bzrlib to the python
> site-packages easily. If I install it to the source tree I'm working on
> I get lovely noise that cant be updated without an rm -rf and a
> re-install. Even if I do get our sysadmin to install it, I'm then stuck
> with continual fiddling if we want to roll forward, or backwards. This
> is a pretty typical scenario for stuff installed
> not-on-ones-own-machine.

Yes, but I believe it's also a solved problem.  Isn't 'install with
prefix' the way it's typically handled?

Or you can just stick a symlink to bzrlib in the directory where pqm lives.

Alternatively, you can just stick a symlink to bzrlib in an otherwise
empty directory, and stick that in your PYTHONPATH.

>>So you only need to muck with the PYTHONPATH if you're following the
>>bleeding edge, and then the garbage argument doesn't really hold-- the
>>only thing that could possibly be misinterpreted is setup.py, and we can
>>just re-commit if that changes.
> 
> 
> I don't know what 're-commit if that changes' means.

If the mainline starts including untenable files, we can simply fix the
mainline.

> As for changes needed to bzr to deal with a lib dir rather than bzrlib
> at the top dir of the source:
> 
> try:
>   import bzrlib
> except ImportError:
>   sys.path.append(os.path.join(sys.argv[0],'..', 'lib'))
>   import bzrlib

That looks icky to me.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDG5Ik0F+nu1YWqI0RAo0QAJwOXWJ2j2P14/NBmOdNxiHfAQ1b6ACeOFF/
UcMuqU4WAZtxO+pL03NmqIs=
=jGoo
-----END PGP SIGNATURE-----




More information about the bazaar mailing list