moving files between packages with deb
When moving a file from one package to the other, from ceph to ceph-common for instance, the following must be done in the debian/control file:
Package: ceph Depends: ceph-common (>= 0.94.2-2) Package: ceph-common Replaces: ceph-client-tools, ceph (<< 0.94.2-2), Breaks: ceph (<< 0.94.2-2),
The -2 is greater than -1trusty, -1jessie etc. which are used for releases (see https://github.com/ceph/ceph-build/blob/master/gen_debian_version.sh and https://github.com/ceph/ceph-build/blob/master/build_debs.sh#L35).
This method is difficult to remember and to understand. It could probably be fixed by moving the packaging outside of the sources or by using native package names (without the -1trusty for instance) when releasing deb packages to reflect the fact that they really are native packages.
See also the Breaks & Replaces in debian/control in backports discussion on ceph-devel.
#1 Updated by Ken Dreyer about 3 years ago
When working on the packaging for Calamari downstream in RHCS this week, Alfredo found that reprepro does not allow you to add packages with identical names into the same debian repository.
So we have to keep distro-specific suffixes in the packages' versions somewhere :/