Bruce Dubbs wrote: > There is a problem that I see from the above description. It may or may > not be an actual problem. > > What about a config file that *is* installed in a package and may be > modified by a user? Examples might be /etc/php.ini or > /etc/apache/httpd.conf. I wouldn't want these files deleted, even if I > deleted the package. >
Slackware packages never ship configuration files that are supposed to be modified by end users. Instead, such configuration files are shipped with the .new extension, and a post-installation script handles this. E.g., for udev: #!/bin/sh config() { NEW="$1" OLD="`dirname $NEW`/`basename $NEW .new`" # If there's no config file by that name, mv it over: if [ ! -r $OLD ]; then mv $NEW $OLD elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy rm $NEW fi # Otherwise, we leave the .new copy for the admin to consider... } config etc/rc.d/rc.udev.new config etc/modprobe.d/blacklist.new config etc/modprobe.d/isapnp.new As you see, the real etc/modprobe.d/blacklist configuration file does not belong to any package and thus will not be removed automatically. -- Alexander E. Patrakov -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page