At 9:16 AM +0930 10/8/02, Greg 'groggy' Lehey wrote: >On Monday, 7 October 2002, M. Warner Losh wrote: > > I think that we need a mtree.obsolete that goes through and deletes >> these sorts of things as part of installworld/upgrade scripts. > >I think we can greatly simplify things with one firm but relatively >bearable rule: > > The directories /bin, /usr/bin, /sbin, /usr/sbin, <insert others > here> are for the exclusive use of the system installer. Install > other programs here at your peril: they will be overwritten on the > next installation. > >There are then dozens of ways of finding the old files and removing >them. I'd be inclined just to remove all files in those directories >which are older than some file in the build tree--*after* a successful >installation. > >Thoughts?
I hate this idea. "installers" should not run around removing files, especially files that they know nothing about. Overwriting files is one thing, explicitly removing files is something else. The idea of an mtree.obsolete is more reasonable, although I am not sure how workable it is. "Obsolete, from when?". The list of obsolete files will be different for someone coming from 5.0-dp1 than it is for someone coming from 4.7-release. I could see this working ok, but I could also see it being a bit of a headache to maintain. This problem has been discussed in the past, and I think that what I'd like is something that I do in some situations. I have the 'install' script (my own...) keep track of what files were installed, and when. You could then ask the system which files are in a given directory, and did not get installed "today" (or some such question). I keep meaning to look at the base-system 'install' and see if there's some good way to add something to it for this idea. For builds of freebsd-current, every few weeks I do: mv /usr/include /usr/include.bak-mmdd mkdir /usr/include just before make installworld this gives me a pristine /usr/include, and does not remove any files. It's the idea of 'rm' commands which I find extremely unappealing, and rather user-hostile. If anything is added to "clean out" old files from /bin (etc), then I would really like to see it just *move* the files to some alternate directory structure, instead of going wild with rm commands. -- Garance Alistair Drosehn = [EMAIL PROTECTED] Senior Systems Programmer or [EMAIL PROTECTED] Rensselaer Polytechnic Institute or [EMAIL PROTECTED] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message