[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

pygtk 1.2 -> 2 transition, what's the best way ?


I'm looking on the best way to do the soon coming python-gtk 1.2 -> 2
transition (for more details about that:

The transition will be ok for unstable, but what about the next stable ?

A summarize the problem :

* An user is running current stable with some python-gtk
  apps. The gtk1.2 python binding is the default, so woody's apps use
  "import gtk" to have gtk1.2 (without specify the version).

* After the next release he decides to install python-gtk2 (or an app
  that need python-gtk2) by apt-get install python-gtk2 (or app).
  => The default binding will be set to 2.0, and brokes all woody's
  packages that use "import gtk" to have gtk 1.2.

So we need to make the install of python-gtk2 upgrading all the packages 
depending from python-gtk (without that they will be broken).

I'm seeing two solutions for that :

1- Make current python-gtk(2) conflict with all old packages depending
on python-gtk to force the update.

This solution will :
- be ok for the upgrade
- need no changes for the others packages

- need to list all the packages concerned (and be carefull not forgotten
- will not work with non-official packages

2- Make python-gtk2 conflicts with python-gtk, and introduced a
python-gtk-compat1.2 package to replace it. 

Then you just need to build all packages depending on python-gtk (1.2)
against the new package (about 20 packages to rebuild, not a lot of
So a install of python-gtk2 will remove python-gtk, install
python-gtk-compat1.2 and upgrade all needed packages.

I'm thinking the second one is the best solution, but I prefer asking
here for having some advices before starting in that way. 

I've made some test of the second solution in a chroot, all seems to be
ok (install of python-gtk2, of a app depending on python-gtk2, upgrade,
...). If nobody is against that, I think I'll upload the new
python-gtk-compat1.2 during the next week.


Sebastien Bacher

Reply to: