[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

changing location of .conf files

I've been studying the "Debian Packaging Manual" section 6.3, and I want
to make sure that I am interpreting it correctly. 

My package contains a few conffiles which will be changing locations.
They are currently:

/usr/lib/router/interfaces/* -> ../../../var/wanpipe/*

(I never understood the need/reason symlink either; I inherited it from
Christoph Lameter.  Perhaps he was foreshadowing, in an Obi-Wan sort of
way, that I needed to do what I'm about to do.) 

I want to move them to:


My question is:

According to the manual (section 6.3), "6.  Any files which were in the
old version of the package but not in the new are removed."  Fortunately,
I have a chance to take care of this in my preinst script (step 3).

But, I'm afraid of freaking out dpkg when it gets around to handling the
conffiles explicitly (as explained in chapter 9).  

The format of the configuration files is not changing.  Does the
following sound sane?

preinst checks to see if it was called with just "install" (new install -
in which case, don't worry about the conffiles, dpkg will handle them

preinst checks to see if it was called with either "install <oldversion>"
or "upgrade <oldversion>", which case it will copy whatever the user had
for these conffiles into the new locations (and then remove the old
conffiles?  Or let dpkg handle this?)

TIA for pointers and well-intended flames.

"Here's a nickel, go buy yourself  |  Debian/GNU Linux
a _real_ operating system."        |  <http://www.debian.org>
   (Dilbert)                       |     (real life)

Reply to: