Hope this can be of help to you. Taken from the Mepis (a Debian derivative) forum. Author is the initiator of Mepis, warren himself. Should work for most Debian-based distros.
Quote:"Upgrading from the debian pool can be an adventure, to put it kindly.
There are 2 two major areas causing problems: kde 3.2 and x 4.3.0. These are very large package groups with many interdependencies. They are always problematic when big changes occurs. At this time, KDE 3.2 is new and x 4.3.0 has been seriously restructured.
Here's some instructions that should help. This assumes you are starting from a fresh install but the concepts should also apply if you have already done a partial upgrade.
TO UPGRADE X 4.3.0
1. apt-get update
NOTE: It may be necessary to repeat steps 2 through 6 for 2 or 3 times to resolve all dependencies.
2. apt-get install -y xlibs xlibs-data libice6 libsm6 libx11-6 libxext6 libxi6 libxmu6 libxmuu1 libxp6 libxpm4 libxrandr2 libxtrap6 libxtst6 libxft1 libxi6 libxt6 libxv1 x-dev libice-dev libsm-dev libxext-dev libx11-dev libxext-dev libxi-dev libxmu-dev libxmuu-dev libxp-dev libxpm-dev libxrandr-dev libxt-dev libxtrap-dev libxtst-dev libxv-dev xlibs-dev xlibs-static-dev xlibs-static-pic xlibs-pic --ignore-hold
3. apt-get install xfree86-common xserver-common xserver-xfree86 lbxproxy proxymngr xbase-clients
apt-get install xfree86-common xserver-common xserver-xfree86 lbxproxy proxymngr xbase-clients libstdc++5-3.3-doc x-window-system-core x-window-system twm icewm-lite configlet-frontends mdetect discover read-edid
4. apt-get install xfs xfwp xterm xutils
5. apt-get install libdps1 libxaw7 xlibmesa-gl xlibmesa-glu xlibmesa-gl-dev xlibmesa-glu-dev xlibmesa-dri
6. apt-get install xfonts-100dpi xfonts-75dpi xfonts-base xfonts-base-transcoded xfonts-scalable xfonts-konsole
7. Reboot the system when all dependency issues are resolved.
Examples of what transpired in my case (NOT Warren's or others')
1st try:
Probs with these:
/var/cache/apt/archives/libice6_4.3.0-5_i386.deb
/var/cache/apt/archives/x-dev_4.3.0-5_all.deb
/var/cache/apt/archives/libice-dev_4.3.0-5_i386.deb
/var/cache/apt/archives/libxext6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxext-dev_4.3.0-5_i386.deb
/var/cache/apt/archives/libxv1_4.3.0-5_i386.deb
/var/cache/apt/archives/xlibs_4.3.0-5_all.deb
/var/cache/apt/archives/libx11-6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxi6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxt6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxmu6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxmuu1_4.3.0-5_i386.deb
/var/cache/apt/archives/libxp6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxpm4_4.3.0-5_i386.deb
/var/cache/apt/archives/libxrandr2_4.3.0-5_i386.deb
/var/cache/apt/archives/libxtrap6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxtst6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxft1_4.3.0-5_i386.deb
/var/cache/apt/archives/libsm6_4.3.0-5_i386.deb
2nd try:
Probs reduced to just these 2 on 2nd run
/var/cache/apt/archives/libice6_4.3.0-5_i386.deb
/var/cache/apt/archives/libxpm4_4.3.0-5_i386.deb
3rd attempt:
No more errors
TO UPGRADE MOST PACKAGES
1. apt-get remove openoffice.org-mimelnk
2. apt-get upgrade
3. apt-get upgrade
4. Reboot the system when all dependency issues are resolved.
To UPGRADE THE KDE 3.2 CORE
NOTE: If asked questions about replacing config files, answer no.
1. apt-get install kdelibs kdebase kdeutils kdepim kdegames kdm kdemultimedia kdeartwork kdeadmin kdegraphics
2. apt-get upgrade
3. apt-get install the remaining updated apps.
4. Reboot the system when all dependency issues are resolved.
At this point you should have a working upgraded system but your menus will be messed up becuase kde 3.2 uses a completely different method of generating menus.
Your fonts and other core kde configs *might* be messed up due to other changes in kde 3.2.
Do let us know if this is useful.
WARNING: You may depending on when you choose to redo your x and kde installations still encounter a problem with a missing library - libxft-dev_2.1.2-6 after you are done with apt-get upgrade. It is a very important library. So be prepared that some apps may not have their full range of functions enabled. And that from here on, irrespective of what you try, you won't be able to use apt to install or perform upgrades. The newest available version for libxft-dev in 'Unstable' is 2.1.2-5. So be patient and wait acouple of days (???), the new version should enter 'unstable' very soon I think hmmm...