It seems to me that some files I write to global directories such as /usr are not persistent. Concretely I experience that the installation of some self-compiled software (webkit-qt) to global directories is broken after some time until I reinstall it. The relevant webkit installation is installed by the package management at the same time to fullfill dependencies. So each time I install I certainly overwrite some of these files. Please don't tell me that this is not nice to do. I am aware of it. I am just wondering if there is some mechanism in ubuntu which restores the old version of the files (other than the package management if I reinstall some package of course)!
|
If you want to divert files associated with packages that are installed (or that you intend to install), so that you can replace them with your own files but restore them later, you should use the Since I don't have all the details of your situation, it would be hard for me to recommend specific syntax, beyond the information provided in that manual page. Other than the package manager and the tools that are part of it (including The other exception is parts of |
|||||
|

/usrinstead of/usr/local? (I think your reasoning might shed light on what solution to this problem would be most appropriate for your situation.) – Eliah Kagan May 14 '12 at 17:06dpkg-diverting and installing in/usr, but both are almost certainly better than the ugly and extremely dangerous hack of replacing files associated with installed packages without telling the package manager. But indeed, depending on how unusual your situation is, any of these (including what you've been doing so far) may be your best choice. My intention was not to say that you're doing it wrong. – Eliah Kagan May 14 '12 at 17:21/usr. But the executive summary is: no, the package manager is the only part of Ubuntu that's supposed to modify the contents of/usr. – Eliah Kagan May 17 '12 at 13:33