Re: Packaging, supporting both 2.1 and 2.2

2002-05-25 Thread Tollef Fog Heen
* Moshe Zadka | Unless anyone sees any problem with it, here is what I will use to find out | the default python on the build system: | /usr/bin/python -c 'import sys;v=sys.hexversion;print "%s.%s" % ((v>>24)&0xff, (v>>16)&0xff)' python -c 'import sys; print sys.version[:3]' does the same (but

Re: Packaging, supporting both 2.1 and 2.2

2002-05-24 Thread Bastian Kleineidam
Hi, On Fri, May 24, 2002 at 10:26:41AM +1000, Donovan Baarda wrote: > For those that _really_ want to run foo with python2.2, they can run > 'foo-python2.2' instead. I think using 'alternatives' is overkill for this > reason, and the symlink is a good idea. 'python2.2 /usr/bin/foo' would work too

Re: Packaging, supporting both 2.1 and 2.2

2002-05-23 Thread Donovan Baarda
On Thu, May 23, 2002 at 04:34:18AM -, Moshe Zadka wrote: > On Thu, 23 May 2002, [EMAIL PROTECTED] (Donovan Baarda) wrote: [...] > > This situation is identical to the existing idle package. It's worth looking > > at how it handles it. > > I'll take a look, thanks. Note the naming convention '

Re: Packaging, supporting both 2.1 and 2.2

2002-05-23 Thread Ricardo Javier Cardenes Medina
On Thu, May 23, 2002 at 04:34:18AM -, Moshe Zadka wrote: > > > 1a) as 1), but also provide foo symlink for python (default). > > this makes senseI can just put the symlink in python2.1-foo-bin and > move the symlinks when a python default change. Or you can use the update-alternatives to

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Thu, 23 May 2002, [EMAIL PROTECTED] (Donovan Baarda) wrote: > if I understand it, foo is not really a 'binary' but an 'executable > script'... (which means it can be Python version independant). Yep. > This situation is identical to the existing idle package. It's worth looking > at how it ha

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Donovan Baarda
On Thu, May 23, 2002 at 10:10:51AM +1000, Donovan Baarda wrote: [...] > 1a) as 1), but also provide foo symlink for python (default). > > as 1), but also make foo (Depends: python (>=2.1), python (<<2.2), > foo-python2.1) with symlink /usr/bin/foo to /usr/bin/foo-python2.2 Ack! typo... should be

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Donovan Baarda
On Wed, May 22, 2002 at 04:50:02PM -, Moshe Zadka wrote: > On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > > > Ok, thats a problem. There is no way out for this; you'd have to > > have two binaries. > > Yes, I know I'll have to have two binaries. if I understand it, foo

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > Ok, thats a problem. There is no way out for this; you'd have to > have two binaries. Yes, I know I'll have to have two binaries. > Provide library packages: python2.1-foo, python2.2-foo. > Provide *one* binary package for the

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
On Wed, May 22, 2002 at 01:09:02PM -, Moshe Zadka wrote: > Situation: > python2.1, python2.2, python2.2-foo and python-foo are all installed. > python2.1 is the default. > All dependancies are resolved, right? > > #!/usr/bin/python > import foo > > equivalent to > > #!/usr/bin/python2.1 > i

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Matthias Klose <[EMAIL PROTECTED]> wrote: > > > > > c) python-foo: /usr/bin/foo binary with #!/usr/bin/python > > > > >Depends: python2.1-foo | python2.2-foo ^ that's an or sign, right > > python2.1, python2.2, python2.2-foo and pyt

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Matthias Klose
Moshe Zadka writes: > On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > > > On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > > > a) python2.1-foo: python foo.py module for 2.1 > > Depends: python2.1 > > > > > > b) python2.2-foo: python foo.py module for 2.2 > >

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > > a) python2.1-foo: python foo.py module for 2.1 > Depends: python2.1 > > > > b) python2.2-foo: python foo.py module for 2.2 > Depends: python2.2 Of course You do

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Chris Lawrence
On May 22, Moshe Zadka wrote: > Doesn't work. > What if the user installed python2.2-foo but /usr/bin/python > is /usr/bin/python2.1, or vice versa? > If this is what python-central does, then python-central, I'm afraid, > has a bug... Under Debian's Python policy, /usr/bin/python is guaranteed to

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
Hi Moshe, On Wed, May 22, 2002 at 12:09:11PM -, Moshe Zadka wrote: > > a) python2.1-foo: python foo.py module for 2.1 Depends: python2.1 > > b) python2.2-foo: python foo.py module for 2.2 Depends: python2.2 > > c) python-foo: /usr/bin/foo binary with #!/usr/bin/python > >Depends: python2

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Moshe Zadka
On Wed, 22 May 2002, Bastian Kleineidam <[EMAIL PROTECTED]> wrote: > There is a package called python-central which allows version-independent > packages. > http://people.debian.org/~calvin/python-central/ > Precondition: you have a "pure" pyhthon module, no C-compiled Extension. Sorry, the situa

Re: Packaging, supporting both 2.1 and 2.2

2002-05-22 Thread Bastian Kleineidam
On Wed, May 22, 2002 at 11:01:14AM -, Moshe Zadka wrote: > [please CC me, I'm not on the list] NP. > Hypothetical situation: > Source package: contains foo.py (python module, works with every python > version under the sun) and foo (a script whose first line is > "import foo"). I want to prop