Re: Derivatives needing to replace config files
Hi Christian,
Debathena developed a CDBS extension module called config-package-dev that
lets you do this in a mostly-sane manner for packaged files (either
regular files or conffiles, but not generated files). The purpose of
config-package-dev is to let us ship a package that via dpkg-divert
replaces a file in another package, so that we don't have to rebuild the
other package, take on responsibility for watching for security updates,
etc., and can just point users at the main Debian repository for it.
For your example, you'd just create your modified zshrc, use the .install
file to place it in /etc/zsh/zshrc.grml, and put
DEB_DIVERT_EXTENSION=.grml
DEB_DIVERT_FILES=/etc/zsh/zshrc.grml
include /usr/share/cdbs/1/rules/config-package.mk
in your CDBS debian/rules. There's also syntax for writing a sed (or
other) script to transform the file at build time, which helps if you're
just adding or removing a few lines instead of supplying a new file, so
you can just do a no-change rebuild to pick up the new file (which we do
for every stable Debian or Ubuntu releae at the least).
For more info, see the home page:
http://debathena.mit.edu/config-package-dev
We use this heavily on MIT's Athena workstations, and this has enabled us
to compartmentalize what "Athena" is and provide a competent distribution
for laptop/private machines running Debian or Ubuntu, instead of
effectively distributing our own OS as we did since the '80s. A couple of
other sites use config-package-dev too. We do this both for configuration
and wrappers around binaries. I'm also working on a Debhelper based
reweite in my spare time since DH 7 got us much of what we originally
wanted from CDBS, but I'm not sure how quickly this will be done.
--
Geoffrey Thomas
geofft@mit.edu
On Thu, 28 Jul 2011, Christian Hofstädtler wrote:
Hi there!
Some derivatives need/want to replace config files shipped by standard
Debian packages.
I'm wondering what is the best way to do this as long as the package is
shipped by the derivative, and, what can be done inside Debian to make
this easier, and/or actually allowing this inside Debian itself (with
limitations, of course).
If anyone wants to discuss this at DC11, myself and other Grml
developers are usually somewhere in the upper floor hacklab.
Thanks,
-chrish
--
To UNSUBSCRIBE, email to debian-derivatives-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: [🔎] A9B751AD-6D53-43D6-B031-E1F0182832B3@grml.org">http://lists.debian.org/[🔎] A9B751AD-6D53-43D6-B031-E1F0182832B3@grml.org
Reply to: