Ubuntu python version
Vincenzo Di Massa
hawk78_it at yahoo.it
Wed Feb 2 19:19:51 CST 2005
Alle 19:15, mercoledì 02 febbraio 2005, Matt Zimmerman ha scritto:
> On Wed, Feb 02, 2005 at 11:36:53AM +0100, Vincenzo Di Massa wrote:
> > Please tell me if I understand how it works.
> >
> > If I want to develop a package MyPackage wihch depends on AnotherPackage
> > and there are packagesAnotherPackage AnotherPackage1.0 AnotherPackage2.0:
> > - if I want to depend on >=1 I just depend on AnotherPackage
> > - if I want to dependo on <=1 I must depend on AnotherPackage1.0
>
> The "python2.3" package provides /usr/bin/python2.3. If your package uses
> #!/usr/bin/python2.3, you should depend on this package.
>
> The "python2.4" package provides /usr/bin/python2.4. If your package uses
> #!/usr/bin/python2.4, you should depend on this package.
>
> The "python" package provides /usr/bin/python. If your package uses
> #!/usr/bin/python, you should depend on this package.
Are you sure? The current python package (wich is a dependency package) does
not (and should not IMHO) provide /usr/bin/python.
#dpkg -L python | grep bin
/usr/bin
/usr/bin/pydoc
/usr/bin/pygettext
/usr/bin/pdb
>
> In all of these cases, you may use inequalities to declare a dependency on
> particular versions of these packages. If your package contains a
> #!/usr/bin/python program which only works with python 2.4 or later, you
> could use Depends: python (>= 2.4). If your package contains a
> #!/usr/bin/python2.3 program which only works with python 2.3.3 or later,
> you could use Depends: python2.3 (>= 2.3.3).
>
> I hope this clarifies things for you.
Just one more question: what if my program does *not* work with python 2.4
because it requires python2.3 ?
There are two ways:
1) depend on python2.3
2) depend on python (<=2.3) or (=2.3)
IMHO 2) is the wrong way because, to satisfy this dependency, you can't
upgrade python. You can install python2.4, but python (and packages requiring
newer versions of python) can't be installed.
If you go with 1) there should be no problem: I just need to change references
to /usr/bin/python to /usr/bin/python2.3.
>
> > There should be a rule preventing confusion so that packages that just
> > want mysql or python must not depend on version number with <=, if they
> > want to depend on something with <= they should depend on the right
> > vesion.
>
> In the case of Python programs, dependencies with <= or << don't seem to
> make much sense to me. Matthias, can you explain the reasons why many
> packages are made this way?
Python programs can stop working when using a newer python version. Blender
for same time worked only with 2.3.
Ciao, Vincenzo
>
> --
> - mdz
More information about the ubuntu-devel
mailing list