This is (I am reliably informed) intentional behaviour in order to avoid
potentially-confusing semantics. Multiple packages can own a given
directory (and frequently do, e.g. /usr), and this is to prevent
confusion when only one of them decides to turn it into a symlink.
(Consider that one of the other packages that owns the directory might
be installed later.) There are conceivably ways to work around this, but
dpkg has chosen not to attempt it for simplicity and in order to force
maintainers to consider this.

The standard workaround is to include a preinst that, on upgrade to the
version in which you make this change, 'rm -rf's the directory; the link
will then be created on unpack. Alternatively, if there might be non-
dpkg-managed files in that directory, you should move it aside to a safe
place in the preinst, and then move those files into the target of the
symlink in the postinst.

-- 
upgrade/migration from a directory to a link broken
https://bugs.launchpad.net/bugs/164228
You received this bug notification because you are a member of Ubuntu
Bugs, which is the bug contact for Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to